The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

App::JobLog::Command::truncate - decapitate the log

VERSION

version 1.035

SYNOPSIS

 houghton@NorthernSpy:~$ job truncate -z 2010
 truncated portion of log saved in /home/houghton/.joblog/log-2009-01-12--2009-12-29.zip
 houghton@NorthernSpy:~$ unzip -l /home/houghton/.joblog/log-2009-01-12--2009-12-29.zip
 Archive:  /home/houghton/.joblog/log-2009-01-12--2009-12-29.zip
   Length      Date    Time    Name
 ---------  ---------- -----   ----
     56342  2011-08-28 16:07   log-2009-01-12--2009-12-29
 ---------                     -------
     56342                     1 file
 houghton@NorthernSpy:~$ head /home/houghton/.joblog/log
 # Log file truncated on 2011-08-28T16:07:35.
 # Head of log to be found in log-2009-01-12--2009-12-29.zip
 # 2010/01/01
 2010  1  1  0  0  0:Complyon:adding features to segmenter
 # 2010/01/02
 2010  1  1 16 40 45:DONE
 2010  1  2 14 12 19:Complyon:creating accuracy measurement rig
 2010  1  2 14 41  9:DONE
 2010  1  2 14 44  5:Complyon:creating accuracy measurement rig
 # 2010/01/03
 houghton@NorthernSpy:~$ 

DESCRIPTION

Over time your log will fill with cruft: work no one is interested in any longer, tags whose meaning you've forgotten. What you want to do at this point is chop off all the old stuff, stash it somewhere you can find it if need be, and retain in your active log only the more recent events. This is what truncate is for. You give it a starting date and it splits your log into two with the active portion containing all moments on that date or after. The older portion is retained in your joblog hidden directory.

SEE ALSO

App::JobLog::Command::edit

AUTHOR

David F. Houghton <dfhoughton@gmail.com>

COPYRIGHT AND LICENSE

This software is copyright (c) 2011 by David F. Houghton.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.