summaryrefslogtreecommitdiff
path: root/inotail.c
AgeCommit message (Collapse)AuthorFilesLines
2006-11-08Spelling fixes and some small code reorderingTobias Klauser1-8/+6
2006-10-26inotail.c: Support inotail -n +<num>Tobias Klauser1-4/+51
Add function lines_to_offset_from_begin() to allow tailing relative to the begin of the file. Also handle the case where the argument for '-c' or 'n' is '+0'. Like GNU tail (and according to its source also tail in UNIX) print the whole file in this case.
2006-10-25Various change to allow tailing bytes relative to the beginTobias Klauser1-7/+10
"Simplyfy" and inline bytes_to_offset, extend it to support tailing relative to begin of file. Boolean relative makes no sense, make it a char containing 0 for relative to end and 1 for relative to begin.
2006-10-24inotail.c: Introduce relative tailingTobias Klauser1-6/+9
The global variable 'relative' states whether we're tailing relative to the end (R_END, default) or the begin of the file. Also do some minor comment reformatting.
2006-10-21Unify wording all over the treeTobias Klauser1-2/+2
According to the Linux source it's: * s/linux/Linux/ * s/Kernel/kernel/ * s/Inotify/inotify/ (except at the beginning of a sentence)
2006-10-20inotail.c: Add basic support for +/-<num> to -c/-nTobias Klauser1-2/+6
2006-10-20inotail.c: More n_units cleanupTobias Klauser1-6/+6
Make n_units unsigned and rename some more variables to the appropriate form.
2006-10-20inotail.c: rename n_lines to n_unitsTobias Klauser1-5/+5
2006-10-17inotail.c: Better error handling in tail_file()Tobias Klauser1-9/+14
Close fd on any error, rename rc variable to cleanly state what it's for.
2006-10-16inotail.c: Make pretty_name() an inlineTobias Klauser1-1/+1
2006-10-05Better file type checking and more meaningful return valuesTobias Klauser1-3/+12
2006-09-27Move inotify event handling into own functionTobias Klauser1-50/+53
2006-09-26Add unlikely macroTobias Klauser1-2/+1
And use it for a really unlikely case
2006-09-26Add check for the case that no file produced the inotify eventTobias Klauser1-2/+5
This could use an unlikely()
2006-09-20Just tail everything in tail_pipe() for nowv0.1Tobias Klauser1-1/+8
2006-09-20Use getopt for command option parsingTobias Klauser1-24/+30
2006-09-20Print pretty name for stdin in verbose modeTobias Klauser1-2/+9
2006-09-13Simplify re-tailing after IN_MODIFYTobias Klauser1-16/+4
2006-09-13Remove one more debugging outputTobias Klauser1-2/+0
2006-09-13Further cleanupTobias Klauser1-4/+4
2006-09-13Reorder definesTobias Klauser1-5/+1
2006-09-03Set mode explicitely when -n command line is specifiedTobias Klauser1-0/+1
This prevents us from doing the wrong thing in such (very unlikely) cases: $ inotail -c 6 -n 6 file.txt
2006-09-03Remove some debugging ouput.Tobias Klauser1-3/+1
Alos adjust the notice about turbotail, there isn't really any code from turbotail anymore.
2006-08-26Better error handling and preparation for tail from stdinTobias Klauser1-13/+46
2006-08-23Unify commandline switch description between binary and manpageTobias Klauser1-4/+4
2006-08-20Close open fd's on failed fstat()Tobias Klauser1-2/+4
2006-08-20CleanupTobias Klauser1-11/+8
2006-08-13Alos check for fd when adding watch to file.Tobias Klauser1-1/+1
2006-08-13Small cleanupsTobias Klauser1-6/+5
* Check for VERSION being set from Makefile * Remove needless code
2006-08-12Introduce handling of ignored filesTobias Klauser1-10/+30
Files which are no longer available (e.g. moved, deleted) are marked as "ignore" and do no longer influence the tailing of other files.
2006-08-12Improved error handling and more meaningful error messagesTobias Klauser1-26/+37
2006-07-17Update usage, remove version definition (set from Makefile now), remove onlyTobias Klauser1-4/+4
user of file_struct's ignore field.
2006-07-11* Update usage()Tobias Klauser1-12/+16
* Use constant for program name
2006-07-09Reorder includes, make verbose char instead of shortTobias Klauser1-5/+5
2006-07-08* Get rid of bytes_to_offset()Tobias Klauser1-15/+8
* Clean up debug/warning/error messages
2006-07-01This seems legitimateTobias Klauser1-1/+1
2006-07-01Make bytes_to_offset() an inlineTobias Klauser1-1/+1
2006-07-01* Implements -c (byte tail)Tobias Klauser1-6/+25
* Small cleanups
2006-05-29Write a many bytes as readTobias Klauser1-4/+6
2006-05-29* Rename lines() to lines_to_offset() which makes its purpose a bit more clearTobias Klauser1-9/+8
* Remove some debugging lines * Correct name in version output * Add some clarifying comments and messages
2006-05-25memset() fbuf before usingTobias Klauser1-1/+1
2006-05-17Allow multiple files to be watched.Tobias Klauser1-14/+29
2006-05-11Adjust comments to new namesTobias Klauser1-1/+1
2006-05-11simpletail is the new inotailTobias Klauser1-267/+161
2006-04-28Changed e-mail adressTobias Klauser1-2/+2
2006-04-04Unify return valuesTobias Klauser1-7/+9
2006-03-16Clean upTobias Klauser1-26/+14
2006-03-13Initial importTobias Klauser1-0/+399