App-JobLog
view release on metacpan or search on metacpan
lib/App/JobLog.pm view on Meta::CPAN
Describes the last event in the log. See L<App::JobLog::Command::last>.
=item L<modify|App::JobLog::Command::modify>
Modifies the last event in the log. See L<App::JobLog::Command::modify>.
=item L<note|App::JobLog::Command::note>
Adds a note to the log -- text independent of any task. See L<App::JobLog::Command::note>.
=item L<parse|App::JobLog::Command::parse>
Parse a time expression to discover what the application understands it to mean.
See L<App::JobLog::Command::parse>.
=item L<resume|App::JobLog::Command::resume>
Resumes the last closed event in the log. See L<App::JobLog::Command::resume>.
=item L<summary|App::JobLog::Command::summary>
Presents a portion of the log in more human readable form. See L<App::JobLog::Command::summary>.
=item L<tags|App::JobLog::Command::tags>
List only the tags used to categorize tasks. See L<App::JobLog::Command::tags>.
=item L<today|App::JobLog::Command::today>
Summarizes everything done today. See L<App::JobLog::Command::today>.
=item L<truncate|App::JobLog::Command::truncate>
Pares off and stores the older portion of the log. See L<App::JobLog::Command::truncate>.
=item L<vacation|App::JobLog::Command::vacation>
Allows viewing and modification of a simple database of vacation times kept separately from the log.
See L<App::JobLog::Command::vacation>.
=item L<when|App::JobLog::Command::when>
Reports when you'll have worked the expected number of hours given how many hours you put in in the
specified period (the same day, by default).
See L<App::JobLog::Command::when>.
=back
=head2 WHY NOT A DATABASE?
We basically want database functionality out of our job log -- random access, selecting rows by various
properties, nice reports. Why not use SQLite, say, or Berkeley DB? Well first of all, that adds dependencies,
and we want fewer of those. And except in extraordinary circumstances we are only adding events in sequence and we
will only be interested in the most recent ones. Even when we don't just want the most recent events we
don't need truly random access to the whole log but an interval -- all the lines from one point to another.
We only need a slightly glorified log. A database is overkill. Finally, as soon as we maintain our data in
a database it becomes an opaque blob and our editing interface becomes much more complicated to
write, use, and maintain. We need to write a shell, GUI, or ncurses interface and figure out how to provide
the editor with search facilities, the context in which she is making edits, and perhaps an undo/redo stack.
If it's a text file we just pop up an editor and validate the log on close. So I stuck with a log.
=head1 ACKNOWLEDGEMENTS
Thanks to Ricardo Signes for the redoubtable L<App::Cmd> which wires this all together, Dave Rolsky for L<DateTime>,
which does all the calendar math, and Ingy dE<ouml>t Net for L<IO::All>, which, via L<Tie::File> (thanks, Mark Jason
Dominus), makes random access to a log file trivial.
Thanks also to my wife Paula, who was my only beta tester other than myself.
=head1 SEE ALSO
L<App::Cmd>, L<DateTime>, L<IO::All>
=head1 AUTHOR
David F. Houghton <dfhoughton@gmail.com>
=head1 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.
=cut
( run in 0.793 second using v1.01-cache-2.11-cpan-39bf76dae61 )