Commit graph

5328 commits

Author SHA1 Message Date
Paul Beckingham
db7b2dd9fe File Import
- Implemented scaffolding for new import command.
2009-03-25 02:05:50 -04:00
Paul Beckingham
c31ec6b6a6 Unit Tests - all file formats
- Added unit tests to verify correct parsing of file formats 1, 2
  and 3.
2009-03-25 01:29:59 -04:00
Paul Beckingham
1a656f0f60 Recurring Tasks - upgrades and bug fixes
- Improved (fixed) logical consistency checks that prevent the
  addition of a recurrence frequency without a due date.
- Improved (fixed) logical consistency checks that prevent the
  addition of an until date with a recurrence frequency.
- When a recurring task is modified, all sibling instances, as well
  as the parent task now get modified.
- When a recurring task is appended, all sibling instances, as well
  as the parent task now get modified.
- Updated documentation.
- It is now possible to upgrade a regular task to a recurring task,
  which is triggered by the "recur" attribute.
2009-03-25 01:08:13 -04:00
Paul Beckingham
5ec0d569a9 Enhancement - annotations
- Added annotated description to the active, overdue and next reports.
2009-03-24 23:15:55 -04:00
Paul Beckingham
3979c3283e Enhancement - annotations
- Added support for "annotate" command to annotate existing tasks.
- Bumped file format to version 3, due to the annotations.
- Added unit tests to verify that annotations work.
- Changed 'description' column everywhere to include annotations.
- Added 'description_only' column to exclude the annotations.
- Fixed bug in Table.cpp that calculated the width of multi-line
  columns by using the cell length, instead of the length of the
  longest individual line.
- Updated documentation with new feature.
- Updated documentation with new column.
- Enhanced t.t unit tests to cover format 43
2009-03-24 01:57:12 -04:00
Paul Beckingham
ca795ea281 Bug Fix - confirmation was broken
- Fixed inverted condition that broke confirmation.
2009-03-23 21:55:02 -04:00
Paul Beckingham
d10e9be500 Bug fix - assumed "yes" value, instead of Bool
- Fixed bug where only a value of "yes" would enable confirmation,
  instead of any Boolean true value.
2009-03-22 23:50:42 -04:00
Paul Beckingham
f790df24c5 Enhancement - added echo of id, description
- Added an echo of the ID and description of the task for the start,
  stop, do, undo, delete and undelete commands.  Thanks to Bruce
  Dillahunty.
- Updated documentation.
- Added "echo.command=no" to delete.t, undo.t because the default
  value is "yes", which breaks tests.
- Fixed syntax errors in utf8.t
- Corrected expected number of tests in recur.t
2009-03-22 23:34:17 -04:00
Paul Beckingham
ca933d7f39 Unit Tests - duration
- Corrected unit tests that were mistakenly using 'week' instead of
  'weekly'.
2009-03-20 20:02:59 -04:00
Paul Beckingham
827bc6204b Unit Tests - autocomplete
- Implemented unit test to verify the functionality of the
  util.cpp:autoComplete function.
2009-03-20 20:01:44 -04:00
Paul Beckingham
4537d5048e Unit Tests - confirmation
- Implemented unit tests to very that "confirmation=yes" works.
- Implemented unit tests to very that \n causes a re-prompt.
- Updated docs with regard to this fix, thanks to Bruce Dillahunty.
2009-03-20 18:12:11 -04:00
Paul Beckingham
74ea5b4ef6 Bug Fix - confirmation not processing newline
- Fixed bug where util.cpp:confirm was eating newlines, and not
  rewriting the prompt.  Consequently, after confirm asked the
  question, and the user hit <Enter>, nothing was displayed but
  the newline.  Now uses std::getline.
2009-03-20 16:56:25 -04:00
Paul Beckingham
cc2220b406 Unit Tests - text
- Added unit tests to verify correct functioning of the text utility
  code.
2009-03-19 20:48:02 -04:00
Paul Beckingham
7389ce617a i18n - utf8 support
- Added more unit tests to verify that utf8 projects and tags are
  supported.
2009-03-19 19:46:41 -04:00
Paul Beckingham
165001acac i18n - unit tests
- Added more utf8.t unit tests.
- Removed text.cpp:extractParagraphs, which is not used.
2009-03-19 19:14:01 -04:00
Paul Beckingham
3d3d788961 Recurring Tasks - new "weekdays" frequency
- Added support for "weekdays" as a recurrence frequency, which skips
  Saturday and Sunday, but is otherwise a daily recurrence.  Thanks
  to Chris Pride.
2009-03-18 23:29:25 -04:00
Paul Beckingham
92579e5531 Unit Test - oldest/newest
- Added unit tests to verify oldest and newest reports both work when
  less than 10 tasks are added, and have the correct sort order.
2009-03-17 23:36:00 -04:00
Paul Beckingham
40a538a769 Unit Tests - utf8.t
- Implemented unit tests (more of a demo) that add a bunch of UTF-8
  encoded tasks, as a starting point to updating task to be aware of
  encodings, Unicode etc.
2009-03-17 22:45:53 -04:00
Paul Beckingham
c69c3bb090 New Command - append
- New "append" command concatenates additional text onto an existing
  task description.
- Added unit tests to append command.
2009-03-16 08:29:09 -04:00
Paul Beckingham
87be68e2e8 Bug Fix
- Shebang in tests/run_all was backwards.
2009-03-15 22:12:18 -04:00
Paul Beckingham
7b1dec0d77 Bug Fix - abbreviation.t
- abbreviation.t contains unit tests that fail to specify an alternate
  rc file (rc:abbrev.rc), and so instead rely on ~/.taskrc.  For a new
  installation, there is no .taskrc, so task offers to create one.
  When done in the context of a unit test, task hangs waiting for input.
2009-03-15 19:15:35 -04:00
Paul Beckingham
f8af5d999a Unit Tests - run_all
- Added script to run all unit tests and capture output.
2009-03-15 17:38:54 -04:00
Paul Beckingham
8efd8620c8 Portability - Ubuntu 8.10
- When creating a new .taskrc file, no newlines were included at EOL.
  This needs a 1.5.1 regression test.
2009-03-15 17:21:54 -04:00
Paul Beckingham
e8a795befb Unit Tests - due, export
- due.t was incorrectly reporting the number of tests it intended to
  run.
- export.t was not updated when the export command was updated to include
  recurrence information.
2009-03-15 17:01:22 -04:00
Paul Beckingham
b5690f00e2 Portabiliy - Fedora 9, Ubuntu 8
- The custom report limit "report.x.limit" was being used to limit the
  rendered rows in the table.  Instead, there should be something like
  min (limit, actual_rows) used, in Table.cpp.
  The symptom was duplicate tasks in a "task oldest" report, when there
  were less than 10 tasks.
2009-03-15 16:39:41 -04:00
Paul Beckingham
65f74da7a4 Portability - Fedora 9
- Using size_t as a result for std::string::find causes a silent error,
  reported only on Ubuntu 8.  size_t is not large enough.  The proper
  result type is std::string::size_type.  This fixes a problem with
  the command "task old" responding with "Ambiguous commane 'old' -
  could be one of oldest, oldest.description, oldest.limit, oldest.sort".
2009-03-15 16:26:20 -04:00
Paul Beckingham
429d0f3071 Portability - Fedora 9
- Compiler pointed out an expression (a || b && c) that clearly needs
  parentheses around (a || b).  Gcc on other OSes don't mention this.
2009-03-15 16:14:16 -04:00
Paul Beckingham
4baf30cf9c Portability - Ubuntu 8
- Changed unsigned int to size_t for std::string::npos comparison.
- Removed validBuiltinCommand function that is not used.
2009-03-15 16:13:02 -04:00
Paul Beckingham
cd85a28e98 Unit Tests - due, overdue
- Unit tests to verify that the "overdue" report is properly
  displaying tasks.
- Unit tests to verify that "due" can be defined.
2009-03-15 15:04:52 -04:00
Paul Beckingham
e33a918c24 Bug Fix - summary report
- Fixed bug in summary report where recently completed (and therefore
  not yet in the completed.data file) tasks were not included in the
  report.
2009-03-15 11:37:05 -04:00
Paul Beckingham
df82fade2c Unit Tests - bug.summry, custom.columns, next
- Added unit tests to verify that the next report returns the correct
  tasks.
- Added unit test to verify that unrecognized columns in a custom
  report are flagged.
- Added unit tests to verify that only pending and completed tasks
  are included in the summary report.
2009-03-15 11:31:27 -04:00
Paul Beckingham
2d2bd47075 Bug Fix - summary report included deleted tasks
- Applied patch from Benjamin Tegarden to exclude deleted tasks from
  the summary report.
2009-03-14 13:47:48 -04:00
Paul Beckingham
5383943fa7 Enhanced export command
- Now sanitizes output by replacing ' with " in descriptions.
- Added 'recur' attribute to exported output.
- Removed recurring, deleted and complete tasks from the export.
2009-03-14 13:36:32 -04:00
Paul Beckingham
8ac3978222 Unit Tests - dateformat, shadow
- Improved dateformat.t tests to cover all acceptable date format
  characters.
- Unit tests for shadow file update notification.
- Unit tests for shadow file updates under certain circumstances.
- Unit tests for shadow file no updates under other circumstances.
2009-03-14 12:54:11 -04:00
Paul Beckingham
c9a6d2a750 Improved GC and Shadow File Handling
- Every command now returns an output string, or at least has an
  opportunity to do so.
- TDB::gc is only performed a) when allowed, and b) when the command
  will display line numbers.
- updateShadowFile is only performed when a) shadow updates are allowed,
  and either b) when a command is guaranteed to have modified a task or
  c) when TDB:gc has already made changes.
2009-03-14 12:05:32 -04:00
Paul Beckingham
64cfc26ff3 Enhanced Stats Report
- now reports number of unique tags (given filtering)
- now reports number of unique projects (given filtering)
2009-03-14 12:04:25 -04:00
Paul Beckingham
7c87bbc19a Unit Tests - dateformat
- Unit tests determine whether the dateformat configuration variable
  determines how dates are parsed, and how dates are rendered.
2009-03-14 12:02:33 -04:00
Paul Beckingham
4a524a220e Bug Fix - default command, default unit test
- Task runs the default command when no arguments are provided, but
  when an "rc:..." argument is provided, it does not run the default
  command.
- Implemented unit tests to verify the functioning of default commands,
  default project and default priority.
2009-03-14 00:21:42 -04:00
Paul Beckingham
2216eee678 Help Consistency
- Added note about frequent releases to the shortUsage output, so it
  is now consistent with that of "version".
2009-03-13 13:12:34 -04:00
Paul Beckingham
28c97f181a Grammar
- Changed wording of the help output.
2009-03-13 10:35:17 -04:00
Paul Beckingham
0cfc9c720e Compile Bug - missing <stdlib.h>
- Added stdlib.h to Grid.cpp, thanks to Benjamin Tegardin.
2009-03-13 09:06:23 -04:00
Paul Beckingham
05b5273136 Unit Tests - oldest
- Implemented unit tests to verify that the "oldest" report does
  indeed show the oldest 10 tasks.
- Implemented unit tests to verify that the "newest" report does
  indeed show the newest 10 tasks.
2009-03-12 22:56:22 -04:00
Paul Beckingham
c35a764019 Custom Reports - oldest, newest
- Added support for the "report.X.limit" configuration variable, to
  restrict the number of rows a report generates.
- Added support for Table::render (limit) to limit the number of rows
  that are rendered.
- Removed "oldest" and "newest" report code.
- Added "oldest" and "newest" custom report details to Config.cpp
- Updated various documentation.
2009-03-12 22:34:45 -04:00
Paul Beckingham
8c95e82a63 Unit Tests - start/stop/acive
- Added unit tests to test the start and stop commands via the active
  report.
2009-03-10 23:06:02 -04:00
Paul Beckingham
79d644c257 Unit Tests - custom
- Added unit tests to verify correct functioning of custom report
  filters.
2009-03-10 22:30:15 -04:00
Paul Beckingham
2d07b08260 Custom Reports - usage
- Added defined custom reports to the usage text.  This includes the
  new "report.X.description" configuration variable.
2009-03-10 22:21:23 -04:00
Paul Beckingham
1f45e47e36 Bug Fix - history/ghistory triggered only by add
- Fixed bug whereby if a new month rolls around, and no task is added,
  no row of data is shown in the history or ghistory reports, even
  though tasks may have been completed or deleted ni the new month.
2009-03-10 16:37:35 -04:00
Paul Beckingham
dac1942cad Bug Fix - calendar
- Task now displays as many calendars will fit across the window,
  unless a lower value is specified in the "monthsperline" configuration
  variable.
- Task now obeys the "color" configuration variable when determining
  whether to add a legend to the calendar output.
2009-03-10 16:12:59 -04:00
Paul Beckingham
6d8cb5181f Bug Fix - unit test tdb.t
- Fixed two failing unit tests in tdb.t.cpp, which were both due to
  incorrect test logic, rather than a TDB bug.
2009-03-10 15:40:48 -04:00
Paul Beckingham
d174bb1143 Bug Workaround - locking
- Added support for the "locking" configuration variable that disables
  file locking.  This can be helpful to folks who use task on Solaris,
  and store their task data files on an NFS mount.
2009-03-10 15:21:29 -04:00