it can display text in file, however, after i add new text in gedit, it do not show the updated one.

```
sub start_thread {
my @args = @_;
print('Thread started: ', @args, "\n");
open(my $myhandle,'<',@args) or die "unable to open file";  # typical open call
for (;;) {
    while (<$myhandle>) {
    chomp;
    print $_."\n";
    }
    sleep 1;
    seek FH, 0, 1;      # this clears the eof flag on FH
}
}

```

**update video**
<https://docs.google.com/file/d/0B4hnKBXrOBqRWEdjTDFIbHJselk/edit?usp=sharing>

<https://docs.google.com/file/d/0B4hnKBXrOBqRcEFhU3k4dUN4cXc/edit?usp=sharing>

how to print $curpos for updated data

```
for (;;) {
        for ($curpos = tell($myhandle); $_ = <$myhandle>;
            $curpos = tell($myhandle)) {
             # search for some stuff and put it into files
         print $curpos."\n";
        }
        sleep(1);
        seek(FILE, $curpos, 0);
    }

```