From 13aeff1389578f163a4c8327bd9b6ed307a1a270 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Thu, 14 May 2009 23:22:31 -0400 Subject: [PATCH 001/417] New Version - 1.8.0 begins... --- ChangeLog | 7 +++-- Makefile.in | 26 +++++++--------- NEWS | 2 +- configure.ac | 2 +- html/task.html | 47 ++++------------------------- html/versions.html | 74 ++++++++++++++++++++++++++++++++++++++++++++++ src/Makefile.in | 20 ++++++------- 7 files changed, 107 insertions(+), 71 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7d524cbe1..8f0d9526e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,11 @@ ------ current release --------------------------- +1.8.0 (?) + + ? + +------ old releases ------------------------------ + 1.7.0 (5/14/2009) + Improved the errors when parsing a corrupt or unrecognized pending.data or completed.data file (thanks to T. Charles Yun). @@ -39,8 +44,6 @@ variable, $VISUAL or $EDITOR environment variable) and allows direct editing of all editable task details. ------- old releases ------------------------------ - 1.6.1 (4/24/2009) 1b6faf57c998617024d0348a87b941a5d2ab2249 + Fixed bug that caused new, first-time .taskrc files to be written without including the custom report labels (thanks to P.C. Shyamshankar). diff --git a/Makefile.in b/Makefile.in index 6b2e84c98..ef5a3619f 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1,8 +1,8 @@ -# Makefile.in generated by automake 1.10.1 from Makefile.am. +# Makefile.in generated by automake 1.10 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +# 2003, 2004, 2005, 2006 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -169,7 +169,6 @@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ SUBDIRS = src @@ -415,8 +414,8 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(AWK) ' { files[$$0] = 1; } \ + END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS @@ -441,8 +440,8 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) auto.h.in $(TAGS_DEPENDENCIES) \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(AWK) ' { files[$$0] = 1; } \ + END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ @@ -452,12 +451,13 @@ ctags: CTAGS CTAGS: ctags-recursive $(HEADERS) $(SOURCES) auto.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ + here=`pwd`; \ list='$(SOURCES) $(HEADERS) auto.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(AWK) ' { files[$$0] = 1; } \ + END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique @@ -528,10 +528,6 @@ dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) -dist-lzma: distdir - tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma - $(am__remove_distdir) - dist-tarZ: distdir tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__remove_distdir) @@ -558,8 +554,6 @@ distcheck: dist GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ - *.tar.lzma*) \ - unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ @@ -715,7 +709,7 @@ uninstall-man: uninstall-man1 uninstall-man5 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ all all-am am--refresh check check-am clean clean-generic \ ctags ctags-recursive dist dist-all dist-bzip2 dist-gzip \ - dist-lzma dist-shar dist-tarZ dist-zip distcheck distclean \ + dist-shar dist-tarZ dist-zip distcheck distclean \ distclean-generic distclean-hdr distclean-tags distcleancheck \ distdir distuninstallcheck dvi dvi-am html html-am info \ info-am install install-am install-data install-data-am \ diff --git a/NEWS b/NEWS index 30d4f8f1e..be7085856 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,4 @@ -Welcome to Task 1.7.0. +Welcome to Task 1.8.0. Task has been built and tested on the following configurations: diff --git a/configure.ac b/configure.ac index 6fc7c0680..8884b5530 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.61) -AC_INIT(task, 1.7.0, bugs@beckingham.net) +AC_INIT(task, 1.8.0, bugs@beckingham.net) CFLAGS="${CFLAGS=}" CXXFLAGS="${CXXFLAGS=}" diff --git a/html/task.html b/html/task.html index 13b56e377..ec9a2c840 100644 --- a/html/task.html +++ b/html/task.html @@ -113,26 +113,26 @@ - + @@ -141,44 +141,9 @@
Source:task-1.7.0.tar.gztask-1.8.0.tar.gz
-

New in version 1.7.0 (5/14/2009)

+

New in version 1.8.0 (?)

diff --git a/html/versions.html b/html/versions.html index 957f38a44..1b1cda5e9 100644 --- a/html/versions.html +++ b/html/versions.html @@ -35,6 +35,80 @@

+ +

New in version 1.7.0 (5/14/2009)

+

+ + + + + + + + + + +
Source:task-1.7.0.tar.gz
Git - get the whole source and history:http://github.com/pbeckingham/task
+ +

+

+

New in version 1.6.1 (4/24/2009)

diff --git a/src/Makefile.in b/src/Makefile.in index 60381fbc4..ea3982dc4 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -1,8 +1,8 @@ -# Makefile.in generated by automake 1.10.1 from Makefile.am. +# Makefile.in generated by automake 1.10 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +# 2003, 2004, 2005, 2006 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -50,7 +50,7 @@ am_task_OBJECTS = Config.$(OBJEXT) Date.$(OBJEXT) T.$(OBJEXT) \ util.$(OBJEXT) text.$(OBJEXT) rules.$(OBJEXT) import.$(OBJEXT) task_OBJECTS = $(am_task_OBJECTS) task_LDADD = $(LDADD) -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) +DEFAULT_INCLUDES = -I. -I$(top_builddir)@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ @@ -153,7 +153,6 @@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ task_SOURCES = Config.cpp Date.cpp T.cpp TDB.cpp Table.cpp Grid.cpp Timer.cpp color.cpp parse.cpp task.cpp command.cpp edit.cpp report.cpp util.cpp text.cpp rules.cpp import.cpp Config.h Date.h T.h TDB.h Table.h Grid.h Timer.h color.h task.h @@ -260,8 +259,8 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(AWK) ' { files[$$0] = 1; } \ + END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS @@ -273,8 +272,8 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(AWK) ' { files[$$0] = 1; } \ + END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ @@ -284,12 +283,13 @@ ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ + here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(AWK) ' { files[$$0] = 1; } \ + END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique From a120b4bd897437baceaa99fd7426594609dc07e5 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Fri, 15 May 2009 18:45:23 -0400 Subject: [PATCH 002/417] Documentation Update - corrected mistakes - Wrong year - Failed to mention taskrc man page --- ChangeLog | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8f0d9526e..e9f75ac3f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -6,7 +6,7 @@ ------ old releases ------------------------------ -1.7.0 (5/14/2009) +1.7.0 (5/14/2009) f6b8b39d8b4a85c30a457e9e78b582b74531bfe4 + Improved the errors when parsing a corrupt or unrecognized pending.data or completed.data file (thanks to T. Charles Yun). + Added details to the "info" report about recurring tasks (thanks to T. @@ -36,8 +36,8 @@ to /usr/local/share/task (thanks to Federico Hernandez). + Applied patch to allow task to build on Arch Linux (thanks to Johan Friis). + Applied patch to fix a UUID bug on Solaris 8 (thanks to Steven de Brouwer). - + The task man page is now installed. Try "man task" (thanks to Federico - Hernandez and P.C. Shyamshankar). + + The task and taskrc man pages are here. Try "man task", "man taskrc" + (thanks to Federico Hernandez and P.C. Shyamshankar). + Fixed bug that causes task to create a default .task directory, even if data.location specified otherwise (thanks to Federico Hernandez). + New "edit" command that fires up a text editor (uses 'editor' configuration @@ -285,7 +285,7 @@ + Made unit tests compile and run again. + Removed tests from distibution. -0.9.6 (5/13/208) +0.9.6 (5/13/2008) + Corrected wrong include file in Table.cpp. + Replaced color management code. + Improved color rules code. From f974e33fa48908e7cb4f937b2a56cbc488b55004 Mon Sep 17 00:00:00 2001 From: "P.C. Shyamshankar" Date: Tue, 12 May 2009 18:58:27 +0800 Subject: [PATCH 003/417] Initial commit of zsh completion, completes only subcommands right now. Signed-off-by: Paul Beckingham --- completion/_task | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 completion/_task diff --git a/completion/_task b/completion/_task new file mode 100644 index 000000000..8344dad16 --- /dev/null +++ b/completion/_task @@ -0,0 +1,32 @@ +#compdef task +# zsh completion for task as of 1.6.0 +# P.C. Shyamshankar + +typeset -g _task_cmds +_task_cmds=(add append annotate completed description description delete undelete info start stop done undo projects tags summary history ghistory next calendar active overdue stats import export color version help list long ls newest oldest) + +_task() { + _arguments -s -S \ + "*::task command:_task_commands" + return 0 +} + + +(( $+functions[_task_commands] )) || +_task_commands() { + local cmd ret=1 + if (( CURRENT == 1 )); then + _describe -t commands 'task command' _task_cmds + else + local curcontext="${curcontext}" + cmd="${_task_cmds[(r)$words[1]:*]%%:*}" + if (( $#cmd )); then + curcontext="${curcontext%:*:*}:task-${cmd}" + _call_function ret _task_${cmd} || _message "No command remaining." + else + _message "Unknown subcommand ${cmd}" + fi + return ret + fi +} + From 9d2b2de49483504dfe94b74524b02f64d42c08c2 Mon Sep 17 00:00:00 2001 From: "P.C. Shyamshankar" Date: Fri, 15 May 2009 14:21:24 +0800 Subject: [PATCH 004/417] Updated completion for 1.7.0, dynamically getting subcommands from task. Signed-off-by: Paul Beckingham --- completion/_task | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/completion/_task b/completion/_task index 8344dad16..e53389ccb 100644 --- a/completion/_task +++ b/completion/_task @@ -1,9 +1,12 @@ #compdef task -# zsh completion for task as of 1.6.0 +# zsh completion for task # P.C. Shyamshankar typeset -g _task_cmds -_task_cmds=(add append annotate completed description description delete undelete info start stop done undo projects tags summary history ghistory next calendar active overdue stats import export color version help list long ls newest oldest) +_task_cmds=($(task rubbish-command | sed -n -e 's/^\s\+task \(\w\+\) .*/\1/p' | grep -v ID)) + +# As of task 1.7.0, +# _task_cmds=(add append annotate completed edit duplicate delete undelete info start stop done undo projects tags summary timesheet history ghistory next calendar active overdue stats import export color version help list long ls newest oldest) _task() { _arguments -s -S \ @@ -29,4 +32,3 @@ _task_commands() { return ret fi } - From 59bd54fd37d2076314844543012ea3e7ac03c9a4 Mon Sep 17 00:00:00 2001 From: "P.C. Shyamshankar" Date: Fri, 15 May 2009 14:34:16 +0800 Subject: [PATCH 005/417] Moved completion file to its own zsh subdirectory. Signed-off-by: Paul Beckingham --- completion/{ => zsh}/_task | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename completion/{ => zsh}/_task (100%) diff --git a/completion/_task b/completion/zsh/_task similarity index 100% rename from completion/_task rename to completion/zsh/_task From dbc98c1230c52db9b3de86e23c3dcadcf5dcf953 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Fri, 15 May 2009 21:02:06 -0400 Subject: [PATCH 006/417] Patch From a08f3f919f2f4b06503004ca764339918ee5d000 Mon Sep 17 00:00:00 2001 From: Johan Friis Date: Fri, 15 May 2009 16:14:26 +0100 Subject: [PATCH] fontunderline boolean config option Added an option to turn on/off the drawing of table headers with underlined font. If off, the default asciidashes will be used. It defaults to on. --- doc/man5/taskrc.5 | 5 +++++ html/config.html | 7 +++++++ src/report.cpp | 33 ++++++++++++++++++++++----------- 3 files changed, 34 insertions(+), 11 deletions(-) diff --git a/doc/man5/taskrc.5 b/doc/man5/taskrc.5 index 18417485c..f1813359f 100644 --- a/doc/man5/taskrc.5 +++ b/doc/man5/taskrc.5 @@ -123,6 +123,11 @@ The width of tables used when ncurses support is not available. Defaults to 80. Determines whether task uses ncurses to establish the size of the window you are using, for text wrapping. +.TP +.B fontunderline=on +Determines if font underlines or ascii dashes should be used to underline +headers. + .TP .B due=7 This is the number of days into the future that define when a task is considered due, diff --git a/html/config.html b/html/config.html index 80a2c8a23..5cc6c010d 100644 --- a/html/config.html +++ b/html/config.html @@ -209,6 +209,13 @@ Defaults to 80. +
fontuderline
+
+ May be "on" or "off". Determines if font underlines or ascii + dashes should be used to underline headers. + Defaults to on. +
+
due
diff --git a/src/report.cpp b/src/report.cpp index 9e419bfac..050f6e85c 100644 --- a/src/report.cpp +++ b/src/report.cpp @@ -219,7 +219,8 @@ std::string handleCompleted (TDB& tdb, T& task, Config& conf) table.addColumn ("Project"); table.addColumn ("Description"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (0); table.setColumnUnderline (1); @@ -329,7 +330,8 @@ std::string handleInfo (TDB& tdb, T& task, Config& conf) table.addColumn ("Name"); table.addColumn ("Value"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (0); table.setColumnUnderline (1); @@ -605,7 +607,8 @@ std::string handleReportSummary (TDB& tdb, T& task, Config& conf) table.addColumn ("Complete"); table.addColumn ("0% 100%"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (0); table.setColumnUnderline (1); @@ -746,7 +749,8 @@ std::string handleReportNext (TDB& tdb, T& task, Config& conf) table.addColumn ("Age"); table.addColumn ("Description"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (0); table.setColumnUnderline (1); @@ -988,7 +992,8 @@ std::string handleReportHistory (TDB& tdb, T& task, Config& conf) table.addColumn ("Deleted"); table.addColumn ("Net"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (0); table.setColumnUnderline (1); @@ -1189,7 +1194,8 @@ std::string handleReportGHistory (TDB& tdb, T& task, Config& conf) table.addColumn ("Month"); table.addColumn ("Number Added/Completed/Deleted"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (0); table.setColumnUnderline (1); @@ -1549,7 +1555,8 @@ std::string renderMonths ( table.addColumn ("Fr"); table.addColumn ("Sa"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (i + 1); table.setColumnUnderline (i + 2); @@ -1791,7 +1798,8 @@ std::string handleReportActive (TDB& tdb, T& task, Config& conf) table.addColumn ("Due"); table.addColumn ("Description"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (0); table.setColumnUnderline (1); @@ -1924,7 +1932,8 @@ std::string handleReportOverdue (TDB& tdb, T& task, Config& conf) table.addColumn ("Due"); table.addColumn ("Description"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (0); table.setColumnUnderline (1); @@ -2095,7 +2104,8 @@ std::string handleReportStats (TDB& tdb, T& task, Config& conf) table.addColumn ("Category"); table.addColumn ("Data"); - if (conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get ("color", true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) { table.setColumnUnderline (0); table.setColumnUnderline (1); @@ -2691,7 +2701,8 @@ std::string handleCustomReport ( // Common to all columns. // Add underline. - if (conf.get (std::string ("color"), true) || conf.get (std::string ("_forcecolor"), false)) + if ((conf.get (std::string ("color"), true) || conf.get (std::string ("_forcecolor"), false)) && + conf.get (std::string ("fontunderline"), "true")) table.setColumnUnderline (columnCount); else table.setTableDashedUnderline (); From 833fac3c133eb8bde4941037794fcc1024d24c2b Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 16 May 2009 15:45:31 -0400 Subject: [PATCH 007/417] FF4 - Skeleton objects Created skeleton objects for all new 1.8.0 code. --- src/rewrite/Att.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/Att.h | 55 +++++++++++++++++++++++++++ src/rewrite/Context.cpp | 80 ++++++++++++++++++++++++++++++++++++++++ src/rewrite/Context.h | 62 +++++++++++++++++++++++++++++++ src/rewrite/Date.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/Date.h | 46 +++++++++++++++++++++++ src/rewrite/Duration.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/Duration.h | 46 +++++++++++++++++++++++ src/rewrite/Filter.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/Filter.h | 48 ++++++++++++++++++++++++ src/rewrite/Keymap.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/Keymap.h | 42 +++++++++++++++++++++ src/rewrite/Makefile | 23 ++++++++++++ src/rewrite/Record.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/Record.h | 42 +++++++++++++++++++++ src/rewrite/Sequence.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/Sequence.h | 42 +++++++++++++++++++++ src/rewrite/T.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/T.h | 49 ++++++++++++++++++++++++ src/rewrite/TDB.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/TDB.h | 55 +++++++++++++++++++++++++++ src/rewrite/X.cpp | 58 +++++++++++++++++++++++++++++ src/rewrite/X.h | 42 +++++++++++++++++++++ src/rewrite/main.cpp | 23 ++++++++++++ 24 files changed, 1235 insertions(+) create mode 100644 src/rewrite/Att.cpp create mode 100644 src/rewrite/Att.h create mode 100644 src/rewrite/Context.cpp create mode 100644 src/rewrite/Context.h create mode 100644 src/rewrite/Date.cpp create mode 100644 src/rewrite/Date.h create mode 100644 src/rewrite/Duration.cpp create mode 100644 src/rewrite/Duration.h create mode 100644 src/rewrite/Filter.cpp create mode 100644 src/rewrite/Filter.h create mode 100644 src/rewrite/Keymap.cpp create mode 100644 src/rewrite/Keymap.h create mode 100644 src/rewrite/Makefile create mode 100644 src/rewrite/Record.cpp create mode 100644 src/rewrite/Record.h create mode 100644 src/rewrite/Sequence.cpp create mode 100644 src/rewrite/Sequence.h create mode 100644 src/rewrite/T.cpp create mode 100644 src/rewrite/T.h create mode 100644 src/rewrite/TDB.cpp create mode 100644 src/rewrite/TDB.h create mode 100644 src/rewrite/X.cpp create mode 100644 src/rewrite/X.h create mode 100644 src/rewrite/main.cpp diff --git a/src/rewrite/Att.cpp b/src/rewrite/Att.cpp new file mode 100644 index 000000000..f0b6274c7 --- /dev/null +++ b/src/rewrite/Att.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "Att.h" + +//////////////////////////////////////////////////////////////////////////////// +Att::Att () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +Att::Att (const Att& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +Att& Att::operator= (const Att& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +Att::~Att () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/Att.h b/src/rewrite/Att.h new file mode 100644 index 000000000..fa33b5a0a --- /dev/null +++ b/src/rewrite/Att.h @@ -0,0 +1,55 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_ATT +#define INCLUDED_ATT + +class Att +{ +public: + Att (); // Default constructor + Att (const Att&); // Copy constructor + Att& operator= (const Att&); // Assignment operator + ~Att (); // Destructor + +/* +Att (name, value) +std::string name () +std::string value () +int value_int () +addMod () +bool isFilter () +bool isRequired () +bool isInternal () +composeF4 () +parse (const std::stirng&) +*/ + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Context.cpp b/src/rewrite/Context.cpp new file mode 100644 index 000000000..ba357bf45 --- /dev/null +++ b/src/rewrite/Context.cpp @@ -0,0 +1,80 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "Context.h" + +//////////////////////////////////////////////////////////////////////////////// +Context::Context () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +Context::Context (const Context& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +Context& Context::operator= (const Context& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +Context::~Context () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +void Context::initialize () +{ + // TODO Load config + // TODO Load pending.data + // TODO Load completed.data + // TODO Load deleted.data +} + +//////////////////////////////////////////////////////////////////////////////// +int Context::commandLine (int argc, char** argv) +{ + // TODO Support rc: override. + return 0; +} + +//////////////////////////////////////////////////////////////////////////////// +int Context::run () +{ + return 0; +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/Context.h b/src/rewrite/Context.h new file mode 100644 index 000000000..1be1b185f --- /dev/null +++ b/src/rewrite/Context.h @@ -0,0 +1,62 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_CONTEXT +#define INCLUDED_CONTEXT + +#include "Filter.h" +#include "Keymap.h" +//#include "Config.h" +#include "Sequence.h" +#include "TDB.h" +#include "T.h" + + +class Context +{ +public: + Context (); // Default constructor + Context (const Context&); // Copy constructor + Context& operator= (const Context&); // Assignment operator + ~Context (); // Destructor + + void initialize (); + int commandLine (int, char**); + int run (); + +public: +// Config config; + Filter filter; + Keymap keymap; + Sequence sequence; + T task; + TDB tdb; + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Date.cpp b/src/rewrite/Date.cpp new file mode 100644 index 000000000..af9a4b56a --- /dev/null +++ b/src/rewrite/Date.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "Date.h" + +//////////////////////////////////////////////////////////////////////////////// +Date::Date () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +Date::Date (const Date& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +Date& Date::operator= (const Date& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +Date::~Date () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/Date.h b/src/rewrite/Date.h new file mode 100644 index 000000000..40b906db1 --- /dev/null +++ b/src/rewrite/Date.h @@ -0,0 +1,46 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_DATE +#define INCLUDED_DATE + +class Date +{ +public: + Date (); // Default constructor + Date (const Date&); // Copy constructor + Date& operator= (const Date&); // Assignment operator + ~Date (); // Destructor + +/* +bool isDate (const std::string&) +*/ + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Duration.cpp b/src/rewrite/Duration.cpp new file mode 100644 index 000000000..f6acb8964 --- /dev/null +++ b/src/rewrite/Duration.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "Duration.h" + +//////////////////////////////////////////////////////////////////////////////// +Duration::Duration () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +Duration::Duration (const Duration& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +Duration& Duration::operator= (const Duration& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +Duration::~Duration () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/Duration.h b/src/rewrite/Duration.h new file mode 100644 index 000000000..891a00c4d --- /dev/null +++ b/src/rewrite/Duration.h @@ -0,0 +1,46 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_DURATION +#define INCLUDED_DURATION + +class Duration +{ +public: + Duration (); // Default constructor + Duration (const Duration&); // Copy constructor + Duration& operator= (const Duration&); // Assignment operator + ~Duration (); // Destructor + +/* +bool isDuration (const std::string&) +*/ + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Filter.cpp b/src/rewrite/Filter.cpp new file mode 100644 index 000000000..10ad23768 --- /dev/null +++ b/src/rewrite/Filter.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "Filter.h" + +//////////////////////////////////////////////////////////////////////////////// +Filter::Filter () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +Filter::Filter (const Filter& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +Filter& Filter::operator= (const Filter& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +Filter::~Filter () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/Filter.h b/src/rewrite/Filter.h new file mode 100644 index 000000000..814a1851f --- /dev/null +++ b/src/rewrite/Filter.h @@ -0,0 +1,48 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_FILTER +#define INCLUDED_FILTER + +class Filter +{ +public: + Filter (); // Default constructor + Filter (const Filter&); // Copy constructor + Filter& operator= (const Filter&); // Assignment operator + ~Filter (); // Destructor + +/* +add (Att&) +bool Filter::pass (T&) +Filter::parse () +*/ + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Keymap.cpp b/src/rewrite/Keymap.cpp new file mode 100644 index 000000000..de7c0a549 --- /dev/null +++ b/src/rewrite/Keymap.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "Keymap.h" + +//////////////////////////////////////////////////////////////////////////////// +Keymap::Keymap () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +Keymap::Keymap (const Keymap& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +Keymap& Keymap::operator= (const Keymap& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +Keymap::~Keymap () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/Keymap.h b/src/rewrite/Keymap.h new file mode 100644 index 000000000..91c27ba8b --- /dev/null +++ b/src/rewrite/Keymap.h @@ -0,0 +1,42 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_KEYMAP +#define INCLUDED_KEYMAP + +class Keymap +{ +public: + Keymap (); // Default constructor + Keymap (const Keymap&); // Copy constructor + Keymap& operator= (const Keymap&); // Assignment operator + ~Keymap (); // Destructor + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Makefile b/src/rewrite/Makefile new file mode 100644 index 000000000..7115320db --- /dev/null +++ b/src/rewrite/Makefile @@ -0,0 +1,23 @@ +PROJECT = 1.8 +CFLAGS = -I. -I../../library/include -Wall -pedantic -ggdb3 -fno-rtti -fstack-check +LFLAGS = +LIBS = +OBJECTS = main.o Context.o TDB.o T.o Sequence.o Filter.o Att.o Date.o Duration.o Keymap.o + +all: $(PROJECT) + +install: $(PROJECT) + @echo unimplemented + +test: $(PROJECT) + @echo unimplemented + +clean: + -rm *.o $(PROJECT) + +.cpp.o: $(INCLUDE) + g++ -c $(CFLAGS) $< + +$(PROJECT): $(OBJECTS) + g++ $(OBJECTS) $(LFLAGS) $(LIBS) -o $(PROJECT) + diff --git a/src/rewrite/Record.cpp b/src/rewrite/Record.cpp new file mode 100644 index 000000000..c6a97feaf --- /dev/null +++ b/src/rewrite/Record.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "Record.h" + +//////////////////////////////////////////////////////////////////////////////// +Record::Record () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +Record::Record (const Record& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +Record& Record::operator= (const Record& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +Record::~Record () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/Record.h b/src/rewrite/Record.h new file mode 100644 index 000000000..d2ea855d7 --- /dev/null +++ b/src/rewrite/Record.h @@ -0,0 +1,42 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_RECORD +#define INCLUDED_RECORD + +class Record +{ +public: + Record (); // Default constructor + Record (const Record&); // Copy constructor + Record& operator= (const Record&); // Assignment operator + ~Record (); // Destructor + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Sequence.cpp b/src/rewrite/Sequence.cpp new file mode 100644 index 000000000..0a626e157 --- /dev/null +++ b/src/rewrite/Sequence.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "Sequence.h" + +//////////////////////////////////////////////////////////////////////////////// +Sequence::Sequence () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +Sequence::Sequence (const Sequence& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +Sequence& Sequence::operator= (const Sequence& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +Sequence::~Sequence () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/Sequence.h b/src/rewrite/Sequence.h new file mode 100644 index 000000000..f70912b39 --- /dev/null +++ b/src/rewrite/Sequence.h @@ -0,0 +1,42 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_SEQUENCE +#define INCLUDED_SEQUENCE + +class Sequence +{ +public: + Sequence (); // Default constructor + Sequence (const Sequence&); // Copy constructor + Sequence& operator= (const Sequence&); // Assignment operator + ~Sequence (); // Destructor + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/T.cpp b/src/rewrite/T.cpp new file mode 100644 index 000000000..9fe6bee95 --- /dev/null +++ b/src/rewrite/T.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "T.h" + +//////////////////////////////////////////////////////////////////////////////// +T::T () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +T::T (const T& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +T& T::operator= (const T& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +T::~T () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/T.h b/src/rewrite/T.h new file mode 100644 index 000000000..1ee4b8055 --- /dev/null +++ b/src/rewrite/T.h @@ -0,0 +1,49 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_T +#define INCLUDED_T + +class T +{ +public: + T (); // Default constructor + T (const T&); // Copy constructor + T& operator= (const T&); // Assignment operator + ~T (); // Destructor + +/* +T (const std::string&); +composeF4 +composeCSV +parse +*/ + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/TDB.cpp b/src/rewrite/TDB.cpp new file mode 100644 index 000000000..ec988693a --- /dev/null +++ b/src/rewrite/TDB.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "TDB.h" + +//////////////////////////////////////////////////////////////////////////////// +TDB::TDB () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +TDB::TDB (const TDB& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +TDB& TDB::operator= (const TDB& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +TDB::~TDB () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/TDB.h b/src/rewrite/TDB.h new file mode 100644 index 000000000..2fa604c2b --- /dev/null +++ b/src/rewrite/TDB.h @@ -0,0 +1,55 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_TDB +#define INCLUDED_TDB + +class TDB +{ +public: + TDB (); // Default constructor + TDB (const TDB&); // Copy constructor + TDB& operator= (const TDB&); // Assignment operator + ~TDB (); // Destructor + +/* +location (path to task dir) +std::vector load (filter) + caches all raw, including comments + +update (T& old, T& new) +commit () + writes all, including comments + +autoupgrade () + -> FF4 +*/ + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/X.cpp b/src/rewrite/X.cpp new file mode 100644 index 000000000..24688b1ef --- /dev/null +++ b/src/rewrite/X.cpp @@ -0,0 +1,58 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// + +#include "X.h" + +//////////////////////////////////////////////////////////////////////////////// +X::X () +{ +} + +//////////////////////////////////////////////////////////////////////////////// +X::X (const X& other) +{ +// mOne = other.mOne; +} + +//////////////////////////////////////////////////////////////////////////////// +X& X::operator= (const X& other) +{ + if (this != &other) + { +// mOne = other.mOne; + } + + return *this; +} + +//////////////////////////////////////////////////////////////////////////////// +X::~X () +{ +} + +//////////////////////////////////////////////////////////////////////////////// + diff --git a/src/rewrite/X.h b/src/rewrite/X.h new file mode 100644 index 000000000..95b9c6d0e --- /dev/null +++ b/src/rewrite/X.h @@ -0,0 +1,42 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_X +#define INCLUDED_X + +class X +{ +public: + X (); // Default constructor + X (const X&); // Copy constructor + X& operator= (const X&); // Assignment operator + ~X (); // Destructor + +private: +}; + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/main.cpp b/src/rewrite/main.cpp new file mode 100644 index 000000000..493d11931 --- /dev/null +++ b/src/rewrite/main.cpp @@ -0,0 +1,23 @@ +//////////////////////////////////////////////////////////////////////////////// +#include "Context.h" + +int main (int argc, char** argv) +{ + try + { + Context c; + c.initialize (); + c.commandLine (argc, argv); + c.run (); + + return 0; + } + + catch (...) + { + } + + return -1; +} + +//////////////////////////////////////////////////////////////////////////////// From 69ed1e0ebbb40aa139e1371e5e5bfaa3317f2d7a Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 16 May 2009 17:38:54 -0400 Subject: [PATCH 008/417] FF4 - Skeleton code for 2.0 - Created new objects for the 2.0.0 code base, needed in 1.8.0. - Sketched out basic interfaces. --- src/rewrite/.gitignore | 1 + src/rewrite/Att.cpp | 100 ++++++++++++++++++++++++++++++++++++++- src/rewrite/Att.h | 44 ++++++++++------- src/rewrite/Context.cpp | 31 +++++++++--- src/rewrite/Date.cpp | 15 +++++- src/rewrite/Date.h | 13 +++-- src/rewrite/Duration.cpp | 12 ++++- src/rewrite/Duration.h | 11 +++-- src/rewrite/Filter.cpp | 19 +++++++- src/rewrite/Filter.h | 16 ++++--- src/rewrite/Keymap.cpp | 8 ++++ src/rewrite/Keymap.h | 13 ++++- src/rewrite/Record.cpp | 6 ++- src/rewrite/Record.h | 8 +++- src/rewrite/Sequence.cpp | 12 ++++- src/rewrite/Sequence.h | 10 +++- src/rewrite/T.cpp | 28 +++++++++++ src/rewrite/T.h | 12 ++--- src/rewrite/TDB.cpp | 42 +++++++++++++++- src/rewrite/TDB.h | 28 +++++------ src/rewrite/main.cpp | 7 +++ 21 files changed, 357 insertions(+), 79 deletions(-) create mode 100644 src/rewrite/.gitignore diff --git a/src/rewrite/.gitignore b/src/rewrite/.gitignore new file mode 100644 index 000000000..625934097 --- /dev/null +++ b/src/rewrite/.gitignore @@ -0,0 +1 @@ +1.8 diff --git a/src/rewrite/Att.cpp b/src/rewrite/Att.cpp index f0b6274c7..d10b68ea4 100644 --- a/src/rewrite/Att.cpp +++ b/src/rewrite/Att.cpp @@ -29,21 +29,39 @@ //////////////////////////////////////////////////////////////////////////////// Att::Att () +: mName ("") +, mValue ("") { + mMods.clear (); } +//////////////////////////////////////////////////////////////////////////////// +Att::Att (const std::string& name, const std::string& value) +{ + throw std::string ("unimplemented"); + mName = name; + mValue = value; + + mMods.clear (); +} //////////////////////////////////////////////////////////////////////////////// Att::Att (const Att& other) { -// mOne = other.mOne; + throw std::string ("unimplemented"); + mName = other.mName; + mValue = other.mValue; + mMods = other.mMods; } //////////////////////////////////////////////////////////////////////////////// Att& Att::operator= (const Att& other) { + throw std::string ("unimplemented"); if (this != &other) { -// mOne = other.mOne; + mName = other.mName; + mValue = other.mValue; + mMods = other.mMods; } return *this; @@ -55,4 +73,82 @@ Att::~Att () } //////////////////////////////////////////////////////////////////////////////// +// Parse the following forms: +// name [[.mod] ...] : [value] +void Att::parse (const std::string& input) +{ + throw std::string ("unimplemented"); +} +//////////////////////////////////////////////////////////////////////////////// +std::string Att::composeF4 () const +{ + throw std::string ("unimplemented"); + return ""; +} + +//////////////////////////////////////////////////////////////////////////////// +void Att::addMod (const std::string&) +{ + throw std::string ("unimplemented"); +} + +//////////////////////////////////////////////////////////////////////////////// +std::string Att::name () const +{ + return mName; +} + +//////////////////////////////////////////////////////////////////////////////// +void Att::name (const std::string& name) +{ + mName = name; +} + +//////////////////////////////////////////////////////////////////////////////// +std::string Att::value () const +{ + return mValue; +} + +//////////////////////////////////////////////////////////////////////////////// +void Att::value (const std::string& value) +{ + mValue = value; +} + +//////////////////////////////////////////////////////////////////////////////// +int Att::value_int () const +{ + throw std::string ("unimplemented"); + return 0; +} + +//////////////////////////////////////////////////////////////////////////////// +void Att::value_int (int) +{ + throw std::string ("unimplemented"); +} + +//////////////////////////////////////////////////////////////////////////////// +bool Att::filter () const +{ + throw std::string ("unimplemented"); + return false; +} + +//////////////////////////////////////////////////////////////////////////////// +bool Att::required () const +{ + throw std::string ("unimplemented"); + return false; +} + +//////////////////////////////////////////////////////////////////////////////// +bool Att::internal () const +{ + throw std::string ("unimplemented"); + return false; +} + +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Att.h b/src/rewrite/Att.h index fa33b5a0a..2dd8ac8c2 100644 --- a/src/rewrite/Att.h +++ b/src/rewrite/Att.h @@ -27,28 +27,40 @@ #ifndef INCLUDED_ATT #define INCLUDED_ATT +#include +#include + class Att { public: - Att (); // Default constructor - Att (const Att&); // Copy constructor - Att& operator= (const Att&); // Assignment operator - ~Att (); // Destructor + Att (); // Default constructor + Att (const std::string&, const std::string&); + Att (const Att&); // Copy constructor + Att& operator= (const Att&); // Assignment operator + ~Att (); // Destructor -/* -Att (name, value) -std::string name () -std::string value () -int value_int () -addMod () -bool isFilter () -bool isRequired () -bool isInternal () -composeF4 () -parse (const std::stirng&) -*/ + void parse (const std::string&); + std::string composeF4 () const; + + void addMod (const std::string&); + + std::string name () const; + void name (const std::string&); + + std::string value () const; + void value (const std::string&); + + int value_int () const; + void value_int (int); + + bool filter () const; + bool required () const; + bool internal () const; private: + std::string mName; + std::string mValue; + std::vector mMods; }; #endif diff --git a/src/rewrite/Context.cpp b/src/rewrite/Context.cpp index ba357bf45..b93afc562 100644 --- a/src/rewrite/Context.cpp +++ b/src/rewrite/Context.cpp @@ -35,15 +35,27 @@ Context::Context () //////////////////////////////////////////////////////////////////////////////// Context::Context (const Context& other) { -// mOne = other.mOne; + throw std::string ("unimplemented"); +// config = other.config; + filter = other.filter; + keymap = other.keymap; + sequence = other.sequence; + task = other.task; + tdb = other.tdb; } //////////////////////////////////////////////////////////////////////////////// Context& Context::operator= (const Context& other) { + throw std::string ("unimplemented"); if (this != &other) { -// mOne = other.mOne; +// config = other.config; + filter = other.filter; + keymap = other.keymap; + sequence = other.sequence; + task = other.task; + tdb = other.tdb; } return *this; @@ -57,15 +69,17 @@ Context::~Context () //////////////////////////////////////////////////////////////////////////////// void Context::initialize () { - // TODO Load config - // TODO Load pending.data - // TODO Load completed.data - // TODO Load deleted.data + throw std::string ("unimplemented"); + // TODO Load config. + // TODO Load pending.data. + // TODO Load completed.data. + // TODO Load deleted.data. } //////////////////////////////////////////////////////////////////////////////// int Context::commandLine (int argc, char** argv) { + throw std::string ("unimplemented"); // TODO Support rc: override. return 0; } @@ -73,6 +87,11 @@ int Context::commandLine (int argc, char** argv) //////////////////////////////////////////////////////////////////////////////// int Context::run () { + throw std::string ("unimplemented"); + // TODO Dispatch to command handlers. + // TODO Auto shadow update. + // TODO Auto gc. + return 0; } diff --git a/src/rewrite/Date.cpp b/src/rewrite/Date.cpp index af9a4b56a..f01d22506 100644 --- a/src/rewrite/Date.cpp +++ b/src/rewrite/Date.cpp @@ -35,15 +35,17 @@ Date::Date () //////////////////////////////////////////////////////////////////////////////// Date::Date (const Date& other) { -// mOne = other.mOne; + throw std::string ("unimplemented"); + mTime = other.mTime; } //////////////////////////////////////////////////////////////////////////////// Date& Date::operator= (const Date& other) { + throw std::string ("unimplemented"); if (this != &other) { -// mOne = other.mOne; + mTime = other.mTime; } return *this; @@ -55,4 +57,13 @@ Date::~Date () } //////////////////////////////////////////////////////////////////////////////// +// TODO Support m/d/y +// TODO Support ISO-??? +// TODO Support time_t +// TODO Relative dates (today, tomorrow, yesterday, +1d, -2w, eow, eom, eoy) +void Date::parse (const std::string& input) +{ + throw std::string ("unimplemented"); +} +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Date.h b/src/rewrite/Date.h index 40b906db1..935367ae0 100644 --- a/src/rewrite/Date.h +++ b/src/rewrite/Date.h @@ -27,19 +27,22 @@ #ifndef INCLUDED_DATE #define INCLUDED_DATE +#include +#include + class Date { public: - Date (); // Default constructor + Date (); // Default constructor Date (const Date&); // Copy constructor + Date (time_t); // Copy constructor Date& operator= (const Date&); // Assignment operator - ~Date (); // Destructor + ~Date (); // Destructor -/* -bool isDate (const std::string&) -*/ + void parse (const std::string&); private: + time_t mTime; }; #endif diff --git a/src/rewrite/Duration.cpp b/src/rewrite/Duration.cpp index f6acb8964..87c797c68 100644 --- a/src/rewrite/Duration.cpp +++ b/src/rewrite/Duration.cpp @@ -29,21 +29,24 @@ //////////////////////////////////////////////////////////////////////////////// Duration::Duration () +: mSeconds (0) { } //////////////////////////////////////////////////////////////////////////////// Duration::Duration (const Duration& other) { -// mOne = other.mOne; + throw std::string ("unimplemented"); + mSeconds = other.mSeconds; } //////////////////////////////////////////////////////////////////////////////// Duration& Duration::operator= (const Duration& other) { + throw std::string ("unimplemented"); if (this != &other) { -// mOne = other.mOne; + mSeconds = other.mSeconds; } return *this; @@ -55,4 +58,9 @@ Duration::~Duration () } //////////////////////////////////////////////////////////////////////////////// +void Duration::parse (const std::string& input) +{ + throw std::string ("unimplemented"); +} +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Duration.h b/src/rewrite/Duration.h index 891a00c4d..dee0ee578 100644 --- a/src/rewrite/Duration.h +++ b/src/rewrite/Duration.h @@ -27,19 +27,20 @@ #ifndef INCLUDED_DURATION #define INCLUDED_DURATION +#include + class Duration { public: - Duration (); // Default constructor + Duration (); // Default constructor Duration (const Duration&); // Copy constructor Duration& operator= (const Duration&); // Assignment operator - ~Duration (); // Destructor + ~Duration (); // Destructor -/* -bool isDuration (const std::string&) -*/ + void parse (const std::string&); private: + int mSeconds; }; #endif diff --git a/src/rewrite/Filter.cpp b/src/rewrite/Filter.cpp index 10ad23768..c6260d880 100644 --- a/src/rewrite/Filter.cpp +++ b/src/rewrite/Filter.cpp @@ -35,15 +35,17 @@ Filter::Filter () //////////////////////////////////////////////////////////////////////////////// Filter::Filter (const Filter& other) { -// mOne = other.mOne; + throw std::string ("unimplemented"); + mAtts = other.mAtts; } //////////////////////////////////////////////////////////////////////////////// Filter& Filter::operator= (const Filter& other) { + throw std::string ("unimplemented"); if (this != &other) { -// mOne = other.mOne; + mAtts = other.mAtts; } return *this; @@ -55,4 +57,17 @@ Filter::~Filter () } //////////////////////////////////////////////////////////////////////////////// +void Filter::add (Att& att) +{ + throw std::string ("unimplemented"); + mAtts.push_back (att); +} +//////////////////////////////////////////////////////////////////////////////// +bool Filter::pass (T&) +{ + throw std::string ("unimplemented"); + return false; +} + +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Filter.h b/src/rewrite/Filter.h index 814a1851f..6f368b157 100644 --- a/src/rewrite/Filter.h +++ b/src/rewrite/Filter.h @@ -27,21 +27,23 @@ #ifndef INCLUDED_FILTER #define INCLUDED_FILTER +#include +#include "Att.h" +#include "T.h" + class Filter { public: - Filter (); // Default constructor + Filter (); // Default constructor Filter (const Filter&); // Copy constructor Filter& operator= (const Filter&); // Assignment operator - ~Filter (); // Destructor + ~Filter (); // Destructor -/* -add (Att&) -bool Filter::pass (T&) -Filter::parse () -*/ + void add (Att&); + bool pass (T&); private: + std::vector mAtts; }; #endif diff --git a/src/rewrite/Keymap.cpp b/src/rewrite/Keymap.cpp index de7c0a549..c4101ffda 100644 --- a/src/rewrite/Keymap.cpp +++ b/src/rewrite/Keymap.cpp @@ -25,6 +25,7 @@ // //////////////////////////////////////////////////////////////////////////////// +#include #include "Keymap.h" //////////////////////////////////////////////////////////////////////////////// @@ -35,12 +36,14 @@ Keymap::Keymap () //////////////////////////////////////////////////////////////////////////////// Keymap::Keymap (const Keymap& other) { + throw std::string ("unimplemented"); // mOne = other.mOne; } //////////////////////////////////////////////////////////////////////////////// Keymap& Keymap::operator= (const Keymap& other) { + throw std::string ("unimplemented"); if (this != &other) { // mOne = other.mOne; @@ -55,4 +58,9 @@ Keymap::~Keymap () } //////////////////////////////////////////////////////////////////////////////// +void Keymap::load (const std::string& file) +{ + throw std::string ("unimplemented"); +} +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Keymap.h b/src/rewrite/Keymap.h index 91c27ba8b..6ba8986f9 100644 --- a/src/rewrite/Keymap.h +++ b/src/rewrite/Keymap.h @@ -27,15 +27,24 @@ #ifndef INCLUDED_KEYMAP #define INCLUDED_KEYMAP +#include + class Keymap { public: - Keymap (); // Default constructor + Keymap (); // Default constructor Keymap (const Keymap&); // Copy constructor Keymap& operator= (const Keymap&); // Assignment operator - ~Keymap (); // Destructor + ~Keymap (); // Destructor + + void load (const std::string&); // Load the map file +/* + real (); // Convert soft to real + soft (); // Convert real to soft +*/ private: + // TODO Structure for mapping strings to keys. }; #endif diff --git a/src/rewrite/Record.cpp b/src/rewrite/Record.cpp index c6a97feaf..f3eaad67c 100644 --- a/src/rewrite/Record.cpp +++ b/src/rewrite/Record.cpp @@ -35,15 +35,17 @@ Record::Record () //////////////////////////////////////////////////////////////////////////////// Record::Record (const Record& other) { -// mOne = other.mOne; + throw std::string ("unimplemented"); + mAtts = other.mAtts; } //////////////////////////////////////////////////////////////////////////////// Record& Record::operator= (const Record& other) { + throw std::string ("unimplemented"); if (this != &other) { -// mOne = other.mOne; + mAtts = other.mAtts; } return *this; diff --git a/src/rewrite/Record.h b/src/rewrite/Record.h index d2ea855d7..20c10977d 100644 --- a/src/rewrite/Record.h +++ b/src/rewrite/Record.h @@ -27,15 +27,19 @@ #ifndef INCLUDED_RECORD #define INCLUDED_RECORD +#include +#include "Att.h" + class Record { public: - Record (); // Default constructor + Record (); // Default constructor Record (const Record&); // Copy constructor Record& operator= (const Record&); // Assignment operator - ~Record (); // Destructor + ~Record (); // Destructor private: + std::vector mAtts; }; #endif diff --git a/src/rewrite/Sequence.cpp b/src/rewrite/Sequence.cpp index 0a626e157..75b68bcd3 100644 --- a/src/rewrite/Sequence.cpp +++ b/src/rewrite/Sequence.cpp @@ -25,6 +25,7 @@ // //////////////////////////////////////////////////////////////////////////////// +#include #include "Sequence.h" //////////////////////////////////////////////////////////////////////////////// @@ -35,15 +36,17 @@ Sequence::Sequence () //////////////////////////////////////////////////////////////////////////////// Sequence::Sequence (const Sequence& other) { -// mOne = other.mOne; + throw std::string ("unimplemented"); + mSequence = other.mSequence; } //////////////////////////////////////////////////////////////////////////////// Sequence& Sequence::operator= (const Sequence& other) { + throw std::string ("unimplemented"); if (this != &other) { -// mOne = other.mOne; + mSequence = other.mSequence; } return *this; @@ -55,4 +58,9 @@ Sequence::~Sequence () } //////////////////////////////////////////////////////////////////////////////// +void Sequence::parse (const std::string& input) +{ + throw std::string ("unimplemented"); +} +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Sequence.h b/src/rewrite/Sequence.h index f70912b39..57857785b 100644 --- a/src/rewrite/Sequence.h +++ b/src/rewrite/Sequence.h @@ -27,15 +27,21 @@ #ifndef INCLUDED_SEQUENCE #define INCLUDED_SEQUENCE +#include +#include + class Sequence { public: - Sequence (); // Default constructor + Sequence (); // Default constructor Sequence (const Sequence&); // Copy constructor Sequence& operator= (const Sequence&); // Assignment operator - ~Sequence (); // Destructor + ~Sequence (); // Destructor + + void parse (const std::string&); private: + std::vector mSequence; }; #endif diff --git a/src/rewrite/T.cpp b/src/rewrite/T.cpp index 9fe6bee95..9a76e9cc2 100644 --- a/src/rewrite/T.cpp +++ b/src/rewrite/T.cpp @@ -25,6 +25,7 @@ // //////////////////////////////////////////////////////////////////////////////// +#include #include "T.h" //////////////////////////////////////////////////////////////////////////////// @@ -35,12 +36,20 @@ T::T () //////////////////////////////////////////////////////////////////////////////// T::T (const T& other) { + throw std::string ("unimplemented"); // mOne = other.mOne; } +//////////////////////////////////////////////////////////////////////////////// +T::T (const std::string& input) +{ + throw std::string ("unimplemented"); +} + //////////////////////////////////////////////////////////////////////////////// T& T::operator= (const T& other) { + throw std::string ("unimplemented"); if (this != &other) { // mOne = other.mOne; @@ -55,4 +64,23 @@ T::~T () } //////////////////////////////////////////////////////////////////////////////// +std::string T::composeF4 () +{ + throw std::string ("unimplemented"); + return ""; +} +//////////////////////////////////////////////////////////////////////////////// +std::string T::composeCSV () +{ + throw std::string ("unimplemented"); + return ""; +} + +//////////////////////////////////////////////////////////////////////////////// +void T::parse (const std::string& input) +{ + throw std::string ("unimplemented"); +} + +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/T.h b/src/rewrite/T.h index 1ee4b8055..1453c7347 100644 --- a/src/rewrite/T.h +++ b/src/rewrite/T.h @@ -27,20 +27,20 @@ #ifndef INCLUDED_T #define INCLUDED_T +#include + class T { public: T (); // Default constructor T (const T&); // Copy constructor + T (const std::string&); // Parse T& operator= (const T&); // Assignment operator ~T (); // Destructor -/* -T (const std::string&); -composeF4 -composeCSV -parse -*/ + std::string composeF4 (); + std::string composeCSV (); + void parse (const std::string&); private: }; diff --git a/src/rewrite/TDB.cpp b/src/rewrite/TDB.cpp index ec988693a..a8283d2bf 100644 --- a/src/rewrite/TDB.cpp +++ b/src/rewrite/TDB.cpp @@ -25,6 +25,7 @@ // //////////////////////////////////////////////////////////////////////////////// +#include #include "TDB.h" //////////////////////////////////////////////////////////////////////////////// @@ -35,15 +36,17 @@ TDB::TDB () //////////////////////////////////////////////////////////////////////////////// TDB::TDB (const TDB& other) { -// mOne = other.mOne; + throw std::string ("unimplemented"); + mLocations = other.mLocations; } //////////////////////////////////////////////////////////////////////////////// TDB& TDB::operator= (const TDB& other) { + throw std::string ("unimplemented"); if (this != &other) { -// mOne = other.mOne; + mLocations = other.mLocations; } return *this; @@ -55,4 +58,39 @@ TDB::~TDB () } //////////////////////////////////////////////////////////////////////////////// +void TDB::location (const std::string& path) +{ + throw std::string ("unimplemented"); + mLocations.push_back (path); +} +//////////////////////////////////////////////////////////////////////////////// +// TODO Returns number of filtered tasks. +int TDB::load (std::vector & tasks, Filter& filter) +{ + throw std::string ("unimplemented"); + return 0; +} + +//////////////////////////////////////////////////////////////////////////////// +// TODO Write to transaction log. +void TDB::update (T& before, T& after) +{ + throw std::string ("unimplemented"); +} + +//////////////////////////////////////////////////////////////////////////////// +// TODO writes all, including comments +int TDB::commit () +{ + throw std::string ("unimplemented"); +} + +//////////////////////////////////////////////////////////////////////////////// +// TODO -> FF4 +void TDB::upgrade () +{ + throw std::string ("unimplemented"); +} + +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/TDB.h b/src/rewrite/TDB.h index 2fa604c2b..468fefb47 100644 --- a/src/rewrite/TDB.h +++ b/src/rewrite/TDB.h @@ -27,28 +27,28 @@ #ifndef INCLUDED_TDB #define INCLUDED_TDB +#include +#include +#include "Filter.h" +#include "T.h" + class TDB { public: - TDB (); // Default constructor + TDB (); // Default constructor TDB (const TDB&); // Copy constructor TDB& operator= (const TDB&); // Assignment operator - ~TDB (); // Destructor + ~TDB (); // Destructor -/* -location (path to task dir) -std::vector load (filter) - caches all raw, including comments - -update (T& old, T& new) -commit () - writes all, including comments - -autoupgrade () - -> FF4 -*/ + void location (const std::string&); + int load (std::vector &, Filter&); + void update (T&, T&); + int commit (); + void upgrade (); private: + std::vector mLocations; + // TODO Need cache of raw file contents. }; #endif diff --git a/src/rewrite/main.cpp b/src/rewrite/main.cpp index 493d11931..b145dae1d 100644 --- a/src/rewrite/main.cpp +++ b/src/rewrite/main.cpp @@ -1,4 +1,6 @@ //////////////////////////////////////////////////////////////////////////////// +#include +#include #include "Context.h" int main (int argc, char** argv) @@ -13,6 +15,11 @@ int main (int argc, char** argv) return 0; } + catch (std::string e) + { + std::cerr << e << std::endl; + } + catch (...) { } From 7a03d819a0cb6592c7fb6100ade570a1cdc6a531 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 16 May 2009 17:50:30 -0400 Subject: [PATCH 009/417] FF4 - Snapshot - Objects ready for implementation. - Removed template X.h X.cpp. --- src/rewrite/Att.cpp | 22 +++++++-------- src/rewrite/Context.cpp | 10 +++---- src/rewrite/Date.cpp | 6 ++--- src/rewrite/Duration.cpp | 6 ++--- src/rewrite/Filter.cpp | 8 +++--- src/rewrite/Keymap.cpp | 6 ++--- src/rewrite/Record.cpp | 4 +-- src/rewrite/Sequence.cpp | 6 ++--- src/rewrite/T.cpp | 12 ++++----- src/rewrite/TDB.cpp | 14 +++++----- src/rewrite/X.cpp | 58 ---------------------------------------- src/rewrite/X.h | 42 ----------------------------- 12 files changed, 47 insertions(+), 147 deletions(-) delete mode 100644 src/rewrite/X.cpp delete mode 100644 src/rewrite/X.h diff --git a/src/rewrite/Att.cpp b/src/rewrite/Att.cpp index d10b68ea4..8bd34fb1f 100644 --- a/src/rewrite/Att.cpp +++ b/src/rewrite/Att.cpp @@ -38,7 +38,7 @@ Att::Att () //////////////////////////////////////////////////////////////////////////////// Att::Att (const std::string& name, const std::string& value) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::Att"); mName = name; mValue = value; @@ -47,7 +47,7 @@ Att::Att (const std::string& name, const std::string& value) //////////////////////////////////////////////////////////////////////////////// Att::Att (const Att& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::Att"); mName = other.mName; mValue = other.mValue; mMods = other.mMods; @@ -56,7 +56,7 @@ Att::Att (const Att& other) //////////////////////////////////////////////////////////////////////////////// Att& Att::operator= (const Att& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::operator="); if (this != &other) { mName = other.mName; @@ -77,20 +77,20 @@ Att::~Att () // name [[.mod] ...] : [value] void Att::parse (const std::string& input) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::parse"); } //////////////////////////////////////////////////////////////////////////////// std::string Att::composeF4 () const { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::composeF4"); return ""; } //////////////////////////////////////////////////////////////////////////////// void Att::addMod (const std::string&) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::addMod"); } //////////////////////////////////////////////////////////////////////////////// @@ -120,34 +120,34 @@ void Att::value (const std::string& value) //////////////////////////////////////////////////////////////////////////////// int Att::value_int () const { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::value_int"); return 0; } //////////////////////////////////////////////////////////////////////////////// void Att::value_int (int) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::value_int"); } //////////////////////////////////////////////////////////////////////////////// bool Att::filter () const { - throw std::string ("unimplemented"); + throw std::string ("unimplemented filter"); return false; } //////////////////////////////////////////////////////////////////////////////// bool Att::required () const { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::required"); return false; } //////////////////////////////////////////////////////////////////////////////// bool Att::internal () const { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Att::internal"); return false; } diff --git a/src/rewrite/Context.cpp b/src/rewrite/Context.cpp index b93afc562..c68344681 100644 --- a/src/rewrite/Context.cpp +++ b/src/rewrite/Context.cpp @@ -35,7 +35,7 @@ Context::Context () //////////////////////////////////////////////////////////////////////////////// Context::Context (const Context& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Context::Context"); // config = other.config; filter = other.filter; keymap = other.keymap; @@ -47,7 +47,7 @@ Context::Context (const Context& other) //////////////////////////////////////////////////////////////////////////////// Context& Context::operator= (const Context& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Context::operator="); if (this != &other) { // config = other.config; @@ -69,7 +69,7 @@ Context::~Context () //////////////////////////////////////////////////////////////////////////////// void Context::initialize () { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Context::initialize"); // TODO Load config. // TODO Load pending.data. // TODO Load completed.data. @@ -79,7 +79,7 @@ void Context::initialize () //////////////////////////////////////////////////////////////////////////////// int Context::commandLine (int argc, char** argv) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Context::commandLine"); // TODO Support rc: override. return 0; } @@ -87,7 +87,7 @@ int Context::commandLine (int argc, char** argv) //////////////////////////////////////////////////////////////////////////////// int Context::run () { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Context::run"); // TODO Dispatch to command handlers. // TODO Auto shadow update. // TODO Auto gc. diff --git a/src/rewrite/Date.cpp b/src/rewrite/Date.cpp index f01d22506..ad761b2a6 100644 --- a/src/rewrite/Date.cpp +++ b/src/rewrite/Date.cpp @@ -35,14 +35,14 @@ Date::Date () //////////////////////////////////////////////////////////////////////////////// Date::Date (const Date& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Date::Date"); mTime = other.mTime; } //////////////////////////////////////////////////////////////////////////////// Date& Date::operator= (const Date& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Date::operator="); if (this != &other) { mTime = other.mTime; @@ -63,7 +63,7 @@ Date::~Date () // TODO Relative dates (today, tomorrow, yesterday, +1d, -2w, eow, eom, eoy) void Date::parse (const std::string& input) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Date::parse"); } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Duration.cpp b/src/rewrite/Duration.cpp index 87c797c68..56d0ee4a5 100644 --- a/src/rewrite/Duration.cpp +++ b/src/rewrite/Duration.cpp @@ -36,14 +36,14 @@ Duration::Duration () //////////////////////////////////////////////////////////////////////////////// Duration::Duration (const Duration& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Duration::Duration"); mSeconds = other.mSeconds; } //////////////////////////////////////////////////////////////////////////////// Duration& Duration::operator= (const Duration& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Duration::operator="); if (this != &other) { mSeconds = other.mSeconds; @@ -60,7 +60,7 @@ Duration::~Duration () //////////////////////////////////////////////////////////////////////////////// void Duration::parse (const std::string& input) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Duration::parse"); } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Filter.cpp b/src/rewrite/Filter.cpp index c6260d880..ba5e2b521 100644 --- a/src/rewrite/Filter.cpp +++ b/src/rewrite/Filter.cpp @@ -35,14 +35,14 @@ Filter::Filter () //////////////////////////////////////////////////////////////////////////////// Filter::Filter (const Filter& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Filter::Filter"); mAtts = other.mAtts; } //////////////////////////////////////////////////////////////////////////////// Filter& Filter::operator= (const Filter& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Filter::operator="); if (this != &other) { mAtts = other.mAtts; @@ -59,14 +59,14 @@ Filter::~Filter () //////////////////////////////////////////////////////////////////////////////// void Filter::add (Att& att) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Filter::add"); mAtts.push_back (att); } //////////////////////////////////////////////////////////////////////////////// bool Filter::pass (T&) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Filter::pass"); return false; } diff --git a/src/rewrite/Keymap.cpp b/src/rewrite/Keymap.cpp index c4101ffda..388300cfd 100644 --- a/src/rewrite/Keymap.cpp +++ b/src/rewrite/Keymap.cpp @@ -36,14 +36,14 @@ Keymap::Keymap () //////////////////////////////////////////////////////////////////////////////// Keymap::Keymap (const Keymap& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Keymap::Keymap"); // mOne = other.mOne; } //////////////////////////////////////////////////////////////////////////////// Keymap& Keymap::operator= (const Keymap& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Keymap::operator="); if (this != &other) { // mOne = other.mOne; @@ -60,7 +60,7 @@ Keymap::~Keymap () //////////////////////////////////////////////////////////////////////////////// void Keymap::load (const std::string& file) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Keymap::load"); } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Record.cpp b/src/rewrite/Record.cpp index f3eaad67c..f74517d9d 100644 --- a/src/rewrite/Record.cpp +++ b/src/rewrite/Record.cpp @@ -35,14 +35,14 @@ Record::Record () //////////////////////////////////////////////////////////////////////////////// Record::Record (const Record& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Record::Record"); mAtts = other.mAtts; } //////////////////////////////////////////////////////////////////////////////// Record& Record::operator= (const Record& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Record:operator="); if (this != &other) { mAtts = other.mAtts; diff --git a/src/rewrite/Sequence.cpp b/src/rewrite/Sequence.cpp index 75b68bcd3..709a23a46 100644 --- a/src/rewrite/Sequence.cpp +++ b/src/rewrite/Sequence.cpp @@ -36,14 +36,14 @@ Sequence::Sequence () //////////////////////////////////////////////////////////////////////////////// Sequence::Sequence (const Sequence& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Sequence::Sequence"); mSequence = other.mSequence; } //////////////////////////////////////////////////////////////////////////////// Sequence& Sequence::operator= (const Sequence& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Sequence::operator="); if (this != &other) { mSequence = other.mSequence; @@ -60,7 +60,7 @@ Sequence::~Sequence () //////////////////////////////////////////////////////////////////////////////// void Sequence::parse (const std::string& input) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented Sequence::parse"); } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/T.cpp b/src/rewrite/T.cpp index 9a76e9cc2..f88d4b179 100644 --- a/src/rewrite/T.cpp +++ b/src/rewrite/T.cpp @@ -36,20 +36,20 @@ T::T () //////////////////////////////////////////////////////////////////////////////// T::T (const T& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented T::T"); // mOne = other.mOne; } //////////////////////////////////////////////////////////////////////////////// T::T (const std::string& input) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented T::T"); } //////////////////////////////////////////////////////////////////////////////// T& T::operator= (const T& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented T::operator="); if (this != &other) { // mOne = other.mOne; @@ -66,21 +66,21 @@ T::~T () //////////////////////////////////////////////////////////////////////////////// std::string T::composeF4 () { - throw std::string ("unimplemented"); + throw std::string ("unimplemented T::composeF4"); return ""; } //////////////////////////////////////////////////////////////////////////////// std::string T::composeCSV () { - throw std::string ("unimplemented"); + throw std::string ("unimplemented T::composeCSV"); return ""; } //////////////////////////////////////////////////////////////////////////////// void T::parse (const std::string& input) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented T::parse"); } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/TDB.cpp b/src/rewrite/TDB.cpp index a8283d2bf..5526a5611 100644 --- a/src/rewrite/TDB.cpp +++ b/src/rewrite/TDB.cpp @@ -36,14 +36,14 @@ TDB::TDB () //////////////////////////////////////////////////////////////////////////////// TDB::TDB (const TDB& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented TDB::TDB"); mLocations = other.mLocations; } //////////////////////////////////////////////////////////////////////////////// TDB& TDB::operator= (const TDB& other) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented TDB::operator="); if (this != &other) { mLocations = other.mLocations; @@ -60,7 +60,7 @@ TDB::~TDB () //////////////////////////////////////////////////////////////////////////////// void TDB::location (const std::string& path) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented TDB::location"); mLocations.push_back (path); } @@ -68,7 +68,7 @@ void TDB::location (const std::string& path) // TODO Returns number of filtered tasks. int TDB::load (std::vector & tasks, Filter& filter) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented TDB::load"); return 0; } @@ -76,21 +76,21 @@ int TDB::load (std::vector & tasks, Filter& filter) // TODO Write to transaction log. void TDB::update (T& before, T& after) { - throw std::string ("unimplemented"); + throw std::string ("unimplemented TDB::update"); } //////////////////////////////////////////////////////////////////////////////// // TODO writes all, including comments int TDB::commit () { - throw std::string ("unimplemented"); + throw std::string ("unimplemented TDB::commit"); } //////////////////////////////////////////////////////////////////////////////// // TODO -> FF4 void TDB::upgrade () { - throw std::string ("unimplemented"); + throw std::string ("unimplemented TDB::upgrade"); } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/X.cpp b/src/rewrite/X.cpp deleted file mode 100644 index 24688b1ef..000000000 --- a/src/rewrite/X.cpp +++ /dev/null @@ -1,58 +0,0 @@ -//////////////////////////////////////////////////////////////////////////////// -// task - a command line task list manager. -// -// Copyright 2006 - 2009, Paul Beckingham. -// All rights reserved. -// -// This program is free software; you can redistribute it and/or modify it under -// the terms of the GNU General Public License as published by the Free Software -// Foundation; either version 2 of the License, or (at your option) any later -// version. -// -// This program is distributed in the hope that it will be useful, but WITHOUT -// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS -// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more -// details. -// -// You should have received a copy of the GNU General Public License along with -// this program; if not, write to the -// -// Free Software Foundation, Inc., -// 51 Franklin Street, Fifth Floor, -// Boston, MA -// 02110-1301 -// USA -// -//////////////////////////////////////////////////////////////////////////////// - -#include "X.h" - -//////////////////////////////////////////////////////////////////////////////// -X::X () -{ -} - -//////////////////////////////////////////////////////////////////////////////// -X::X (const X& other) -{ -// mOne = other.mOne; -} - -//////////////////////////////////////////////////////////////////////////////// -X& X::operator= (const X& other) -{ - if (this != &other) - { -// mOne = other.mOne; - } - - return *this; -} - -//////////////////////////////////////////////////////////////////////////////// -X::~X () -{ -} - -//////////////////////////////////////////////////////////////////////////////// - diff --git a/src/rewrite/X.h b/src/rewrite/X.h deleted file mode 100644 index 95b9c6d0e..000000000 --- a/src/rewrite/X.h +++ /dev/null @@ -1,42 +0,0 @@ -//////////////////////////////////////////////////////////////////////////////// -// task - a command line task list manager. -// -// Copyright 2006 - 2009, Paul Beckingham. -// All rights reserved. -// -// This program is free software; you can redistribute it and/or modify it under -// the terms of the GNU General Public License as published by the Free Software -// Foundation; either version 2 of the License, or (at your option) any later -// version. -// -// This program is distributed in the hope that it will be useful, but WITHOUT -// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS -// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more -// details. -// -// You should have received a copy of the GNU General Public License along with -// this program; if not, write to the -// -// Free Software Foundation, Inc., -// 51 Franklin Street, Fifth Floor, -// Boston, MA -// 02110-1301 -// USA -// -//////////////////////////////////////////////////////////////////////////////// -#ifndef INCLUDED_X -#define INCLUDED_X - -class X -{ -public: - X (); // Default constructor - X (const X&); // Copy constructor - X& operator= (const X&); // Assignment operator - ~X (); // Destructor - -private: -}; - -#endif -//////////////////////////////////////////////////////////////////////////////// From fa76326aba26a914ce0ff3057370d315b46db794 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 16 May 2009 21:50:04 -0400 Subject: [PATCH 010/417] FF4 - Duration object complete - Replaces util.cpp:convertDuration --- src/rewrite/Duration.cpp | 101 +++++++++++++++++++++++++++++++++++++-- src/rewrite/Duration.h | 9 +++- 2 files changed, 105 insertions(+), 5 deletions(-) diff --git a/src/rewrite/Duration.cpp b/src/rewrite/Duration.cpp index 56d0ee4a5..d0cb4a469 100644 --- a/src/rewrite/Duration.cpp +++ b/src/rewrite/Duration.cpp @@ -25,11 +25,13 @@ // //////////////////////////////////////////////////////////////////////////////// +#include +#include "task.h" #include "Duration.h" //////////////////////////////////////////////////////////////////////////////// Duration::Duration () -: mSeconds (0) +: mDays (0) { } @@ -37,7 +39,13 @@ Duration::Duration () Duration::Duration (const Duration& other) { throw std::string ("unimplemented Duration::Duration"); - mSeconds = other.mSeconds; + mDays = other.mDays; +} + +//////////////////////////////////////////////////////////////////////////////// +Duration::Duration (const std::string& input) +{ + parse (input); } //////////////////////////////////////////////////////////////////////////////// @@ -46,12 +54,36 @@ Duration& Duration::operator= (const Duration& other) throw std::string ("unimplemented Duration::operator="); if (this != &other) { - mSeconds = other.mSeconds; + mDays = other.mDays; } return *this; } +//////////////////////////////////////////////////////////////////////////////// +Duration::operator int () +{ + return (int) mDays; +} + +//////////////////////////////////////////////////////////////////////////////// +Duration::operator time_t () +{ + return mDays; +} + +//////////////////////////////////////////////////////////////////////////////// +bool Duration::operator< (const Duration& other) +{ + return mDays < other.mDays; +} + +//////////////////////////////////////////////////////////////////////////////// +bool Duration::operator> (const Duration& other) +{ + return mDays > other.mDays; +} + //////////////////////////////////////////////////////////////////////////////// Duration::~Duration () { @@ -60,7 +92,68 @@ Duration::~Duration () //////////////////////////////////////////////////////////////////////////////// void Duration::parse (const std::string& input) { - throw std::string ("unimplemented Duration::parse"); + std::string lower_input = lowerCase (input); + + std::vector supported; + supported.push_back ("daily"); + supported.push_back ("day"); + supported.push_back ("weekly"); + supported.push_back ("weekdays"); + supported.push_back ("sennight"); + supported.push_back ("biweekly"); + supported.push_back ("fortnight"); + supported.push_back ("monthly"); + supported.push_back ("bimonthly"); + supported.push_back ("quarterly"); + supported.push_back ("biannual"); + supported.push_back ("biyearly"); + supported.push_back ("annual"); + supported.push_back ("semiannual"); + supported.push_back ("yearly"); + + std::vector matches; + if (autoComplete (lower_input, supported, matches) == 1) + { + std::string found = matches[0]; + + if (found == "daily" || found == "day") mDays = 1; + else if (found == "weekdays") mDays = 1; + else if (found == "weekly" || found == "sennight") mDays = 7; + else if (found == "biweekly" || found == "fortnight") mDays = 14; + else if (found == "monthly") mDays = 30; + else if (found == "bimonthly") mDays = 61; + else if (found == "quarterly") mDays = 91; + else if (found == "semiannual") mDays = 183; + else if (found == "yearly" || found == "annual") mDays = 365; + else if (found == "biannual" || found == "biyearly") mDays = 730; + } + + // Support \d+ d|w|m|q|y + else + { + // Verify all digits followed by d, w, m, q, or y. + unsigned int length = lower_input.length (); + for (unsigned int i = 0; i < length; ++i) + { + if (! isdigit (lower_input[i]) && + i == length - 1) + { + int number = ::atoi (lower_input.substr (0, i).c_str ()); + + switch (lower_input[length - 1]) + { + case 'd': mDays = number * 1; break; + case 'w': mDays = number * 7; break; + case 'm': mDays = number * 30; break; + case 'q': mDays = number * 91; break; + case 'y': mDays = number * 365; break; + } + } + } + } + + if (mDays == 0) + throw std::string ("The duration '") + input + "' was not recognized."; } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Duration.h b/src/rewrite/Duration.h index dee0ee578..d5e1361dc 100644 --- a/src/rewrite/Duration.h +++ b/src/rewrite/Duration.h @@ -28,19 +28,26 @@ #define INCLUDED_DURATION #include +#include class Duration { public: Duration (); // Default constructor Duration (const Duration&); // Copy constructor + Duration (const std::string&); // Parse Duration& operator= (const Duration&); // Assignment operator + bool operator< (const Duration&); + bool operator> (const Duration&); ~Duration (); // Destructor + operator int (); + operator time_t (); + void parse (const std::string&); private: - int mSeconds; + time_t mDays; }; #endif From 5ba1fd6aebb1fd965dde518515d320b027d55ccf Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 16 May 2009 21:56:54 -0400 Subject: [PATCH 011/417] FF4 - New Duration object - Replaces convertDuration. --- src/{rewrite => }/Duration.cpp | 0 src/{rewrite => }/Duration.h | 0 src/Makefile.am | 2 +- src/Makefile.in | 10 +++-- src/rewrite/Date.cpp | 69 ---------------------------------- src/rewrite/Date.h | 49 ------------------------ 6 files changed, 7 insertions(+), 123 deletions(-) rename src/{rewrite => }/Duration.cpp (100%) rename src/{rewrite => }/Duration.h (100%) delete mode 100644 src/rewrite/Date.cpp delete mode 100644 src/rewrite/Date.h diff --git a/src/rewrite/Duration.cpp b/src/Duration.cpp similarity index 100% rename from src/rewrite/Duration.cpp rename to src/Duration.cpp diff --git a/src/rewrite/Duration.h b/src/Duration.h similarity index 100% rename from src/rewrite/Duration.h rename to src/Duration.h diff --git a/src/Makefile.am b/src/Makefile.am index 1d898a521..baff7fbb1 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,2 +1,2 @@ bin_PROGRAMS = task -task_SOURCES = Config.cpp Date.cpp T.cpp TDB.cpp Table.cpp Grid.cpp Timer.cpp color.cpp parse.cpp task.cpp command.cpp edit.cpp report.cpp util.cpp text.cpp rules.cpp import.cpp Config.h Date.h T.h TDB.h Table.h Grid.h Timer.h color.h task.h +task_SOURCES = Config.cpp Date.cpp T.cpp TDB.cpp Table.cpp Grid.cpp Timer.cpp Duration.cpp color.cpp parse.cpp task.cpp command.cpp edit.cpp report.cpp util.cpp text.cpp rules.cpp import.cpp Config.h Date.h T.h TDB.h Table.h Grid.h Timer.h Duration.h color.h task.h diff --git a/src/Makefile.in b/src/Makefile.in index ea3982dc4..a883c69a0 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -45,9 +45,10 @@ binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) PROGRAMS = $(bin_PROGRAMS) am_task_OBJECTS = Config.$(OBJEXT) Date.$(OBJEXT) T.$(OBJEXT) \ TDB.$(OBJEXT) Table.$(OBJEXT) Grid.$(OBJEXT) Timer.$(OBJEXT) \ - color.$(OBJEXT) parse.$(OBJEXT) task.$(OBJEXT) \ - command.$(OBJEXT) edit.$(OBJEXT) report.$(OBJEXT) \ - util.$(OBJEXT) text.$(OBJEXT) rules.$(OBJEXT) import.$(OBJEXT) + Duration.$(OBJEXT) color.$(OBJEXT) parse.$(OBJEXT) \ + task.$(OBJEXT) command.$(OBJEXT) edit.$(OBJEXT) \ + report.$(OBJEXT) util.$(OBJEXT) text.$(OBJEXT) rules.$(OBJEXT) \ + import.$(OBJEXT) task_OBJECTS = $(am_task_OBJECTS) task_LDADD = $(LDADD) DEFAULT_INCLUDES = -I. -I$(top_builddir)@am__isrc@ @@ -155,7 +156,7 @@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -task_SOURCES = Config.cpp Date.cpp T.cpp TDB.cpp Table.cpp Grid.cpp Timer.cpp color.cpp parse.cpp task.cpp command.cpp edit.cpp report.cpp util.cpp text.cpp rules.cpp import.cpp Config.h Date.h T.h TDB.h Table.h Grid.h Timer.h color.h task.h +task_SOURCES = Config.cpp Date.cpp T.cpp TDB.cpp Table.cpp Grid.cpp Timer.cpp Duration.cpp color.cpp parse.cpp task.cpp command.cpp edit.cpp report.cpp util.cpp text.cpp rules.cpp import.cpp Config.h Date.h T.h TDB.h Table.h Grid.h Timer.h Duration.h color.h task.h all: all-am .SUFFIXES: @@ -224,6 +225,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Config.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Date.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Duration.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Grid.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/T.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/TDB.Po@am__quote@ diff --git a/src/rewrite/Date.cpp b/src/rewrite/Date.cpp deleted file mode 100644 index ad761b2a6..000000000 --- a/src/rewrite/Date.cpp +++ /dev/null @@ -1,69 +0,0 @@ -//////////////////////////////////////////////////////////////////////////////// -// task - a command line task list manager. -// -// Copyright 2006 - 2009, Paul Beckingham. -// All rights reserved. -// -// This program is free software; you can redistribute it and/or modify it under -// the terms of the GNU General Public License as published by the Free Software -// Foundation; either version 2 of the License, or (at your option) any later -// version. -// -// This program is distributed in the hope that it will be useful, but WITHOUT -// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS -// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more -// details. -// -// You should have received a copy of the GNU General Public License along with -// this program; if not, write to the -// -// Free Software Foundation, Inc., -// 51 Franklin Street, Fifth Floor, -// Boston, MA -// 02110-1301 -// USA -// -//////////////////////////////////////////////////////////////////////////////// - -#include "Date.h" - -//////////////////////////////////////////////////////////////////////////////// -Date::Date () -{ -} - -//////////////////////////////////////////////////////////////////////////////// -Date::Date (const Date& other) -{ - throw std::string ("unimplemented Date::Date"); - mTime = other.mTime; -} - -//////////////////////////////////////////////////////////////////////////////// -Date& Date::operator= (const Date& other) -{ - throw std::string ("unimplemented Date::operator="); - if (this != &other) - { - mTime = other.mTime; - } - - return *this; -} - -//////////////////////////////////////////////////////////////////////////////// -Date::~Date () -{ -} - -//////////////////////////////////////////////////////////////////////////////// -// TODO Support m/d/y -// TODO Support ISO-??? -// TODO Support time_t -// TODO Relative dates (today, tomorrow, yesterday, +1d, -2w, eow, eom, eoy) -void Date::parse (const std::string& input) -{ - throw std::string ("unimplemented Date::parse"); -} - -//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Date.h b/src/rewrite/Date.h deleted file mode 100644 index 935367ae0..000000000 --- a/src/rewrite/Date.h +++ /dev/null @@ -1,49 +0,0 @@ -//////////////////////////////////////////////////////////////////////////////// -// task - a command line task list manager. -// -// Copyright 2006 - 2009, Paul Beckingham. -// All rights reserved. -// -// This program is free software; you can redistribute it and/or modify it under -// the terms of the GNU General Public License as published by the Free Software -// Foundation; either version 2 of the License, or (at your option) any later -// version. -// -// This program is distributed in the hope that it will be useful, but WITHOUT -// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS -// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more -// details. -// -// You should have received a copy of the GNU General Public License along with -// this program; if not, write to the -// -// Free Software Foundation, Inc., -// 51 Franklin Street, Fifth Floor, -// Boston, MA -// 02110-1301 -// USA -// -//////////////////////////////////////////////////////////////////////////////// -#ifndef INCLUDED_DATE -#define INCLUDED_DATE - -#include -#include - -class Date -{ -public: - Date (); // Default constructor - Date (const Date&); // Copy constructor - Date (time_t); // Copy constructor - Date& operator= (const Date&); // Assignment operator - ~Date (); // Destructor - - void parse (const std::string&); - -private: - time_t mTime; -}; - -#endif -//////////////////////////////////////////////////////////////////////////////// From 2e39929d710cf50eaa1c5ce3e7a2eb0fe7bb7b0f Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 16 May 2009 22:14:32 -0400 Subject: [PATCH 012/417] FF4 - util.cpp:convertDuration -> Duration - Replaced util.cpp convertDuration function with Duration object. --- DEVELOPERS | 33 +++++++++---------- src/Table.cpp | 5 +-- src/parse.cpp | 5 ++- src/task.cpp | 6 +++- src/tests/Makefile | 3 +- src/tests/duration.t.cpp | 45 +++++++++++++++----------- src/util.cpp | 68 ---------------------------------------- 7 files changed, 57 insertions(+), 108 deletions(-) diff --git a/DEVELOPERS b/DEVELOPERS index 6351d0819..e1bda67fe 100644 --- a/DEVELOPERS +++ b/DEVELOPERS @@ -1,22 +1,23 @@ Developers may wish to change task, and here is a high-level guide to the files included. - task.{cpp,h} Implements main, high level processing. - command.cpp Implements all non-report task commands. - report.cpp Implements all task reports. - parse.cpp Parses the command line. - TDB.{cpp,h} The task database, performs all file I/O. - T.{cpp,h} Represents a single task - parses a record from TDB, and also - composes record for TDB. Provides accessors for tasks. - Grid.{cpp,h} Implements a sparse 2D array, provides data storage for the - Table object. - Table.{cpp,h} Implements tabular data rendering, wrapping etc. - Config.{cpp,h} Implements a reader for the .taskrc file. - Date.{cpp,h} General date class for the time_t type. - text.cpp Text manipulation functions. - util.cpp General utility functions. - color.cpp Color support functions. - rules.cpp Auto-colorization rules. + task.{cpp,h} Implements main, high level processing. + command.cpp Implements all non-report task commands. + report.cpp Implements all task reports. + parse.cpp Parses the command line. + TDB.{cpp,h} The task database, performs all file I/O. + T.{cpp,h} Represents a single task - parses a record from TDB, and also + composes record for TDB. Provides accessors for tasks. + Grid.{cpp,h} Implements a sparse 2D array, provides data storage for the + Table object. + Table.{cpp,h} Implements tabular data rendering, wrapping etc. + Config.{cpp,h} Implements a reader for the .taskrc file. + Date.{cpp,h} General date class for the time_t type. + Duration.{cpp,h} General duration class for time deltas. + text.cpp Text manipulation functions. + util.cpp General utility functions. + color.cpp Color support functions. + rules.cpp Auto-colorization rules. Please send bugs, patches to task@beckingham.net diff --git a/src/Table.cpp b/src/Table.cpp index 1d78dfde1..37b9a48e5 100644 --- a/src/Table.cpp +++ b/src/Table.cpp @@ -48,6 +48,7 @@ #include #include #include +#include #include //////////////////////////////////////////////////////////////////////////////// @@ -989,7 +990,7 @@ void Table::sort (std::vector & order) break; else if ((std::string)*left != "" && (std::string)*right == "") SWAP - else if (convertDuration ((std::string)*left) > convertDuration ((std::string)*right)) + else if (Duration ((std::string)*left) > Duration ((std::string)*right)) SWAP break; @@ -998,7 +999,7 @@ void Table::sort (std::vector & order) break; else if ((std::string)*left == "" && (std::string)*right != "") SWAP - else if (convertDuration ((std::string)*left) < convertDuration ((std::string)*right)) + else if (Duration ((std::string)*left) < Duration ((std::string)*right)) SWAP break; } diff --git a/src/parse.cpp b/src/parse.cpp index ae10e2be5..7e5a86f9f 100644 --- a/src/parse.cpp +++ b/src/parse.cpp @@ -31,6 +31,7 @@ #include #include "Date.h" +#include "Duration.h" #include "task.h" #include "T.h" @@ -445,7 +446,9 @@ static bool validSubstitution ( //////////////////////////////////////////////////////////////////////////////// bool validDuration (std::string& input) { - return (convertDuration (input) != 0) ? true : false; + try { Duration (input); } + catch (...) { return false; } + return true; } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/task.cpp b/src/task.cpp index 4d2390154..4984b5a11 100644 --- a/src/task.cpp +++ b/src/task.cpp @@ -38,6 +38,7 @@ #include "Config.h" #include "Date.h" +#include "Duration.h" #include "Table.h" #include "TDB.h" #include "T.h" @@ -717,7 +718,10 @@ Date getNextRecurrence (Date& current, std::string& period) } // If the period is an 'easy' one, add it to current, and we're done. - int days = convertDuration (period); + int days = 0; + try { Duration du (period); days = du; } + catch (...) { days = 0; } + return current + (days * 86400); } diff --git a/src/tests/Makefile b/src/tests/Makefile index a71c8633e..6278cf5e7 100644 --- a/src/tests/Makefile +++ b/src/tests/Makefile @@ -2,7 +2,8 @@ PROJECT = t.t tdb.t date.t duration.t t.benchmark.t text.t autocomplete.t \ parse.t CFLAGS = -I. -I.. -Wall -pedantic -ggdb3 -fno-rtti LFLAGS = -L/usr/local/lib -OBJECTS = ../TDB.o ../T.o ../parse.o ../text.o ../Date.o ../util.o ../Config.o +OBJECTS = ../TDB.o ../T.o ../parse.o ../text.o ../Date.o ../Duration.o \ + ../util.o ../Config.o all: $(PROJECT) diff --git a/src/tests/duration.t.cpp b/src/tests/duration.t.cpp index 77e46a95c..c1c5e2108 100644 --- a/src/tests/duration.t.cpp +++ b/src/tests/duration.t.cpp @@ -25,9 +25,8 @@ // //////////////////////////////////////////////////////////////////////////////// #include -#include +#include #include -#include <../task.h> //////////////////////////////////////////////////////////////////////////////// // daily, day, Nd @@ -36,29 +35,37 @@ // 1st 2nd 3rd 4th .. 31st // quarterly, Nq // biannual, biyearly, annual, semiannual, yearly, Ny + +int convertDuration (const std::string& input) +{ + try { Duration d (input); return (int) d; } + catch (...) {} + return 0; +} + int main (int argc, char** argv) { UnitTest t (17); std::string d; - d = "daily"; t.is (convertDuration (d), 1, "duration daily = 1"); - d = "weekdays"; t.is (convertDuration (d), 1, "duration weekdays = 1"); - d = "day"; t.is (convertDuration (d), 1, "duration day = 1"); - d = "0d"; t.is (convertDuration (d), 0, "duration 0d = 0"); - d = "1d"; t.is (convertDuration (d), 1, "duration 1d = 1"); - d = "7d"; t.is (convertDuration (d), 7, "duration 7d = 7"); - d = "10d"; t.is (convertDuration (d), 10, "duration 10d = 10"); - d = "100d"; t.is (convertDuration (d), 100, "duration 100d = 100"); + t.is (convertDuration ("daily"), 1, "duration daily = 1"); + t.is (convertDuration ("weekdays"), 1, "duration weekdays = 1"); + t.is (convertDuration ("day"), 1, "duration day = 1"); + t.is (convertDuration ("0d"), 0, "duration 0d = 0"); + t.is (convertDuration ("1d"), 1, "duration 1d = 1"); + t.is (convertDuration ("7d"), 7, "duration 7d = 7"); + t.is (convertDuration ("10d"), 10, "duration 10d = 10"); + t.is (convertDuration ("100d"), 100, "duration 100d = 100"); - d = "weekly"; t.is (convertDuration (d), 7, "duration weekly = 7"); - d = "sennight"; t.is (convertDuration (d), 7, "duration sennight = 7"); - d = "biweekly"; t.is (convertDuration (d), 14, "duration biweekly = 14"); - d = "fortnight"; t.is (convertDuration (d), 14, "duration fortnight = 14"); - d = "0w"; t.is (convertDuration (d), 0, "duration 0w = 0"); - d = "1w"; t.is (convertDuration (d), 7, "duration 1w = 7"); - d = "7w"; t.is (convertDuration (d), 49, "duration 7w = 49"); - d = "10w"; t.is (convertDuration (d), 70, "duration 10w = 70"); - d = "100w"; t.is (convertDuration (d), 700, "duration 100w = 700"); + t.is (convertDuration ("weekly"), 7, "duration weekly = 7"); + t.is (convertDuration ("sennight"), 7, "duration sennight = 7"); + t.is (convertDuration ("biweekly"), 14, "duration biweekly = 14"); + t.is (convertDuration ("fortnight"), 14, "duration fortnight = 14"); + t.is (convertDuration ("0w"), 0, "duration 0w = 0"); + t.is (convertDuration ("1w"), 7, "duration 1w = 7"); + t.is (convertDuration ("7w"), 49, "duration 7w = 49"); + t.is (convertDuration ("10w"), 70, "duration 10w = 70"); + t.is (convertDuration ("100w"), 700, "duration 100w = 700"); return 0; } diff --git a/src/util.cpp b/src/util.cpp index 261e7d4af..736f24825 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -280,74 +280,6 @@ const std::string uuid () } #endif -//////////////////////////////////////////////////////////////////////////////// -// Recognize the following constructs, and return the number of days represented -int convertDuration (const std::string& input) -{ - std::string lower_input = lowerCase (input); - Date today; - - std::vector supported; - supported.push_back ("daily"); - supported.push_back ("day"); - supported.push_back ("weekly"); - supported.push_back ("weekdays"); - supported.push_back ("sennight"); - supported.push_back ("biweekly"); - supported.push_back ("fortnight"); - supported.push_back ("monthly"); - supported.push_back ("bimonthly"); - supported.push_back ("quarterly"); - supported.push_back ("biannual"); - supported.push_back ("biyearly"); - supported.push_back ("annual"); - supported.push_back ("semiannual"); - supported.push_back ("yearly"); - - std::vector matches; - if (autoComplete (lower_input, supported, matches) == 1) - { - std::string found = matches[0]; - - if (found == "daily" || found == "day") return 1; - else if (found == "weekdays") return 1; - else if (found == "weekly" || found == "sennight") return 7; - else if (found == "biweekly" || found == "fortnight") return 14; - else if (found == "monthly") return 30; - else if (found == "bimonthly") return 61; - else if (found == "quarterly") return 91; - else if (found == "semiannual") return 183; - else if (found == "yearly" || found == "annual") return 365; - else if (found == "biannual" || found == "biyearly") return 730; - } - - // Support \d+ d|w|m|q|y - else - { - // Verify all digits followed by d, w, m, q, or y. - unsigned int length = lower_input.length (); - for (unsigned int i = 0; i < length; ++i) - { - if (! isdigit (lower_input[i]) && - i == length - 1) - { - int number = ::atoi (lower_input.substr (0, i).c_str ()); - - switch (lower_input[length - 1]) - { - case 'd': return number * 1; break; - case 'w': return number * 7; break; - case 'm': return number * 30; break; - case 'q': return number * 91; break; - case 'y': return number * 365; break; - } - } - } - } - - return 0; // Error. -} - //////////////////////////////////////////////////////////////////////////////// std::string expandPath (const std::string& in) { From fdd43a961924835844c4fa886f3dd96b9c07c8d1 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 16 May 2009 22:22:56 -0400 Subject: [PATCH 013/417] FF4 - Snapshot - Added more Context responsibilities. --- src/rewrite/Context.cpp | 5 +++-- src/rewrite/Context.h | 4 ++-- src/rewrite/Makefile | 5 +++-- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/rewrite/Context.cpp b/src/rewrite/Context.cpp index c68344681..0f8b14c95 100644 --- a/src/rewrite/Context.cpp +++ b/src/rewrite/Context.cpp @@ -36,7 +36,7 @@ Context::Context () Context::Context (const Context& other) { throw std::string ("unimplemented Context::Context"); -// config = other.config; + config = other.config; filter = other.filter; keymap = other.keymap; sequence = other.sequence; @@ -50,7 +50,7 @@ Context& Context::operator= (const Context& other) throw std::string ("unimplemented Context::operator="); if (this != &other) { -// config = other.config; + config = other.config; filter = other.filter; keymap = other.keymap; sequence = other.sequence; @@ -81,6 +81,7 @@ int Context::commandLine (int argc, char** argv) { throw std::string ("unimplemented Context::commandLine"); // TODO Support rc: override. + // TODO Handle "--version, -v" right here. return 0; } diff --git a/src/rewrite/Context.h b/src/rewrite/Context.h index 1be1b185f..26753a5eb 100644 --- a/src/rewrite/Context.h +++ b/src/rewrite/Context.h @@ -29,7 +29,7 @@ #include "Filter.h" #include "Keymap.h" -//#include "Config.h" +#include "Config.h" #include "Sequence.h" #include "TDB.h" #include "T.h" @@ -48,7 +48,7 @@ public: int run (); public: -// Config config; + Config config; Filter filter; Keymap keymap; Sequence sequence; diff --git a/src/rewrite/Makefile b/src/rewrite/Makefile index 7115320db..f4021e3ba 100644 --- a/src/rewrite/Makefile +++ b/src/rewrite/Makefile @@ -1,8 +1,9 @@ PROJECT = 1.8 -CFLAGS = -I. -I../../library/include -Wall -pedantic -ggdb3 -fno-rtti -fstack-check +CFLAGS = -I. -I.. -Wall -pedantic -ggdb3 -fno-rtti -fstack-check LFLAGS = LIBS = -OBJECTS = main.o Context.o TDB.o T.o Sequence.o Filter.o Att.o Date.o Duration.o Keymap.o +OBJECTS = main.o Context.o TDB.o T.o Sequence.o Filter.o Att.o Keymap.o \ + ../util.o ../text.o ../Config.o ../Date.o all: $(PROJECT) From 58e1f3691c3b3ae2c5d6bb26766487619fdff978 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sun, 17 May 2009 17:11:35 -0400 Subject: [PATCH 014/417] FF4 - Snapshot - Added encode/decode Att methods. Necessary if description is to be an attribute, which will be quoted. --- src/rewrite/Att.cpp | 14 ++++++++++++++ src/rewrite/Att.h | 4 ++++ 2 files changed, 18 insertions(+) diff --git a/src/rewrite/Att.cpp b/src/rewrite/Att.cpp index 8bd34fb1f..1082d77ad 100644 --- a/src/rewrite/Att.cpp +++ b/src/rewrite/Att.cpp @@ -152,3 +152,17 @@ bool Att::internal () const } //////////////////////////////////////////////////////////////////////////////// +// TODO Encode values prior to serialization. +void Att::encode (std::string&) const +{ + throw std::string ("unimplemented Att::internal"); +} + +//////////////////////////////////////////////////////////////////////////////// +// TODO Decode values after parse. +void Att::decode (std::string&) const +{ + throw std::string ("unimplemented Att::internal"); +} + +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Att.h b/src/rewrite/Att.h index 2dd8ac8c2..e496a9261 100644 --- a/src/rewrite/Att.h +++ b/src/rewrite/Att.h @@ -57,6 +57,10 @@ public: bool required () const; bool internal () const; +private: + void encode (std::string&) const; + void decode (std::string&) const; + private: std::string mName; std::string mValue; From 32d89560d5022dfacf330de05efbdae72db9eeb1 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sun, 17 May 2009 17:15:46 -0400 Subject: [PATCH 015/417] Patch - completion scripts From 950acdf2990269a6d054e9608a1fed1dddf020a0 Mon Sep 17 00:00:00 2001 From: Federico Hernandez Date: Sun, 17 May 2009 22:34:28 +0200 Subject: [PATCH] Re-arranged shell completion scipts into more suitable directory structure. --- task_completion.sh => scripts/bash/task_completion.sh | 0 {completion => scripts}/zsh/_task | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename task_completion.sh => scripts/bash/task_completion.sh (100%) rename {completion => scripts}/zsh/_task (100%) diff --git a/task_completion.sh b/scripts/bash/task_completion.sh similarity index 100% rename from task_completion.sh rename to scripts/bash/task_completion.sh diff --git a/completion/zsh/_task b/scripts/zsh/_task similarity index 100% rename from completion/zsh/_task rename to scripts/zsh/_task From 5d275188e9d6838037adc956ad87bd509874b8c6 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sun, 17 May 2009 19:44:33 -0400 Subject: [PATCH 016/417] Portability - Added Slackware - Added Slackware 12-12.2 as a supported platform (thanks to Mateusz Almannai). --- NEWS | 1 + html/task.html | 1 + 2 files changed, 2 insertions(+) diff --git a/NEWS b/NEWS index be7085856..c54baa354 100644 --- a/NEWS +++ b/NEWS @@ -12,6 +12,7 @@ Task has been built and tested on the following configurations: - Ubuntu 8.10 Intrepid Ibex - Ubuntu 9.04 Jaunty Jackalope - Arch Linux + - Slackware 12-12.2 - Solaris 8 - Solaris 10 - Cygwin 1.5.25-14 diff --git a/html/task.html b/html/task.html index ec9a2c840..02203328f 100644 --- a/html/task.html +++ b/html/task.html @@ -167,6 +167,7 @@
  • Ubuntu 8.10 Intrepid Ibex
  • Ubuntu 9.04 Jaunty Jackalope
  • Arch Linux +
  • Slackware 12-12.2
  • Solaris 8
  • Solaris 10
  • Cygwin 1.5.25-14 From 04f60a4d8cdcba315223419d9862f5ab4b86d980 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sun, 17 May 2009 23:29:53 -0400 Subject: [PATCH 017/417] FF4 - header file reorg - Added new util.h and text.h header files. - Corresponding edits. --- src/Config.cpp | 3 +- src/Date.cpp | 3 +- src/Duration.cpp | 3 +- src/T.cpp | 3 +- src/TDB.cpp | 3 +- src/Table.cpp | 3 +- src/command.cpp | 4 +++ src/edit.cpp | 5 ++++ src/import.cpp | 4 +++ src/parse.cpp | 3 +- src/report.cpp | 2 ++ src/rules.cpp | 3 +- src/task.cpp | 2 ++ src/task.h | 56 ----------------------------------- src/text.cpp | 4 ++- src/text.h | 51 ++++++++++++++++++++++++++++++++ src/util.cpp | 3 ++ src/util.h | 76 ++++++++++++++++++++++++++++++++++++++++++++++++ 18 files changed, 166 insertions(+), 65 deletions(-) create mode 100644 src/text.h create mode 100644 src/util.h diff --git a/src/Config.cpp b/src/Config.cpp index 6a99189ad..ac63f9871 100644 --- a/src/Config.cpp +++ b/src/Config.cpp @@ -32,8 +32,9 @@ #include #include #include -#include "task.h" #include "Config.h" +#include "text.h" +#include "util.h" //////////////////////////////////////////////////////////////////////////////// // These are default (but overridable) reports. These entries are necessary diff --git a/src/Date.cpp b/src/Date.cpp index 995011345..cdc5cc7d3 100644 --- a/src/Date.cpp +++ b/src/Date.cpp @@ -28,8 +28,9 @@ #include #include #include -#include "task.h" #include "Date.h" +#include "text.h" +#include "util.h" //////////////////////////////////////////////////////////////////////////////// // Defaults to "now". diff --git a/src/Duration.cpp b/src/Duration.cpp index d0cb4a469..7c55be345 100644 --- a/src/Duration.cpp +++ b/src/Duration.cpp @@ -26,7 +26,8 @@ //////////////////////////////////////////////////////////////////////////////// #include -#include "task.h" +#include "text.h" +#include "util.h" #include "Duration.h" //////////////////////////////////////////////////////////////////////////////// diff --git a/src/T.cpp b/src/T.cpp index 58a280f62..43bf0e200 100644 --- a/src/T.cpp +++ b/src/T.cpp @@ -27,8 +27,9 @@ #include #include #include -#include "task.h" #include "T.h" +#include "text.h" +#include "util.h" //////////////////////////////////////////////////////////////////////////////// // Default diff --git a/src/TDB.cpp b/src/TDB.cpp index 98c2c8009..299eda3e6 100644 --- a/src/TDB.cpp +++ b/src/TDB.cpp @@ -31,8 +31,9 @@ #include #include -#include "task.h" +#include "T.h" #include "TDB.h" +#include "util.h" //////////////////////////////////////////////////////////////////////////////// TDB::TDB () diff --git a/src/Table.cpp b/src/Table.cpp index 37b9a48e5..f737d52e6 100644 --- a/src/Table.cpp +++ b/src/Table.cpp @@ -49,7 +49,8 @@ #include #include #include -#include +#include "text.h" +#include "util.h" //////////////////////////////////////////////////////////////////////////////// Table::Table () diff --git a/src/command.cpp b/src/command.cpp index 4a89427e1..4f8cc67cc 100644 --- a/src/command.cpp +++ b/src/command.cpp @@ -34,6 +34,10 @@ #include #include +#include "T.h" +#include "TDB.h" +#include "text.h" +#include "util.h" #include "task.h" #ifdef HAVE_LIBNCURSES diff --git a/src/edit.cpp b/src/edit.cpp index 445e8a1c6..30be75ec7 100644 --- a/src/edit.cpp +++ b/src/edit.cpp @@ -33,6 +33,11 @@ #include #include #include +#include "T.h" +#include "TDB.h" +#include "Date.h" +#include "text.h" +#include "util.h" #include "task.h" //////////////////////////////////////////////////////////////////////////////// diff --git a/src/import.cpp b/src/import.cpp index 163dca30d..bcb154147 100644 --- a/src/import.cpp +++ b/src/import.cpp @@ -29,6 +29,10 @@ #include #include #include "Date.h" +#include "T.h" +#include "TDB.h" +#include "text.h" +#include "util.h" #include "task.h" //////////////////////////////////////////////////////////////////////////////// diff --git a/src/parse.cpp b/src/parse.cpp index 7e5a86f9f..b4e40aa34 100644 --- a/src/parse.cpp +++ b/src/parse.cpp @@ -32,8 +32,9 @@ #include "Date.h" #include "Duration.h" -#include "task.h" #include "T.h" +#include "text.h" +#include "util.h" //////////////////////////////////////////////////////////////////////////////// // NOTE: These are static arrays only because there is no initializer list for diff --git a/src/report.cpp b/src/report.cpp index 050f6e85c..17f5bd1fb 100644 --- a/src/report.cpp +++ b/src/report.cpp @@ -40,6 +40,8 @@ #include "Table.h" #include "TDB.h" #include "T.h" +#include "text.h" +#include "util.h" #include "task.h" #ifdef HAVE_LIBNCURSES diff --git a/src/rules.cpp b/src/rules.cpp index 5744dd3ca..2030e1a36 100644 --- a/src/rules.cpp +++ b/src/rules.cpp @@ -30,7 +30,8 @@ #include "Table.h" #include "Date.h" #include "T.h" -#include "task.h" +#include "text.h" +#include "util.h" static std::map gsFg; static std::map gsBg; diff --git a/src/task.cpp b/src/task.cpp index 4984b5a11..57526180a 100644 --- a/src/task.cpp +++ b/src/task.cpp @@ -42,6 +42,8 @@ #include "Table.h" #include "TDB.h" #include "T.h" +#include "text.h" +#include "util.h" #include "task.h" #ifdef HAVE_LIBNCURSES diff --git a/src/task.h b/src/task.h index 7599007ea..3104c5d6d 100644 --- a/src/task.h +++ b/src/task.h @@ -33,26 +33,8 @@ #include "Table.h" #include "Date.h" #include "color.h" -#include "TDB.h" -#include "T.h" #include "../auto.h" -#ifndef min -#define min(a,b) ((a) < (b) ? (a) : (b)) -#endif - -#ifndef max -#define max(a,b) ((a) > (b) ? (a) : (b)) -#endif - -#define foreach(i, c) \ -for (typeof (c) *foreach_p = & (c); \ - foreach_p; \ - foreach_p = 0) \ - for (typeof (foreach_p->begin()) i = foreach_p->begin(); \ - i != foreach_p->end(); \ - ++i) - // parse.cpp void parse (std::vector &, std::string&, T&, Config&); bool validPriority (const std::string&); @@ -120,44 +102,6 @@ std::string handleCustomReport (TDB&, T&, Config&, const std::string&); void validReportColumns (const std::vector &); void validSortColumns (const std::vector &, const std::vector &); -// text.cpp -void wrapText (std::vector &, const std::string&, const int); -std::string trimLeft (const std::string& in, const std::string& t = " "); -std::string trimRight (const std::string& in, const std::string& t = " "); -std::string trim (const std::string& in, const std::string& t = " "); -std::string unquoteText (const std::string&); -void extractLine (std::string&, std::string&, int); -void split (std::vector&, const std::string&, const char); -void split (std::vector&, const std::string&, const std::string&); -void join (std::string&, const std::string&, const std::vector&); -std::string commify (const std::string&); -std::string lowerCase (const std::string&); -std::string upperCase (const std::string&); -const char* optionalBlankLine (Config&); - -// util.cpp -bool confirm (const std::string&); -void delay (float); -void formatTimeDeltaDays (std::string&, time_t); -std::string formatSeconds (time_t); -int autoComplete (const std::string&, const std::vector&, std::vector&); -const std::string uuid (); -int convertDuration (const std::string&); -std::string expandPath (const std::string&); - -#ifdef SOLARIS - #define LOCK_SH 1 - #define LOCK_EX 2 - #define LOCK_NB 4 - #define LOCK_UN 8 - - int flock (int, int); -#endif - -bool slurp (const std::string&, std::vector &, bool trimLines = false); -bool slurp (const std::string&, std::string&, bool trimLines = false); -void spit (const std::string&, const std::string&); - // rules.cpp void initializeColorRules (Config&); void autoColorize (T&, Text::color&, Text::color&, Config&); diff --git a/src/text.cpp b/src/text.cpp index 69689a5ac..ac1015031 100644 --- a/src/text.cpp +++ b/src/text.cpp @@ -27,7 +27,9 @@ #include #include #include -#include "task.h" +#include "Config.h" +#include "util.h" +#include "text.h" static const char* newline = "\n"; static const char* noline = ""; diff --git a/src/text.h b/src/text.h new file mode 100644 index 000000000..458d714d0 --- /dev/null +++ b/src/text.h @@ -0,0 +1,51 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_TEXT +#define INCLUDED_TEXT + +#include +#include +#include "Config.h" +#include "../auto.h" + +// text.cpp +void wrapText (std::vector &, const std::string&, const int); +std::string trimLeft (const std::string& in, const std::string& t = " "); +std::string trimRight (const std::string& in, const std::string& t = " "); +std::string trim (const std::string& in, const std::string& t = " "); +std::string unquoteText (const std::string&); +void extractLine (std::string&, std::string&, int); +void split (std::vector&, const std::string&, const char); +void split (std::vector&, const std::string&, const std::string&); +void join (std::string&, const std::string&, const std::vector&); +std::string commify (const std::string&); +std::string lowerCase (const std::string&); +std::string upperCase (const std::string&); +const char* optionalBlankLine (Config&); + +#endif +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/util.cpp b/src/util.cpp index 736f24825..8cbb9cfe2 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -38,6 +38,9 @@ #include #include "Date.h" #include "Table.h" +#include "T.h" +#include "TDB.h" +#include "text.h" #include "task.h" #include "../auto.h" diff --git a/src/util.h b/src/util.h new file mode 100644 index 000000000..2bfaef59a --- /dev/null +++ b/src/util.h @@ -0,0 +1,76 @@ +//////////////////////////////////////////////////////////////////////////////// +// task - a command line task list manager. +// +// Copyright 2006 - 2009, Paul Beckingham. +// All rights reserved. +// +// This program is free software; you can redistribute it and/or modify it under +// the terms of the GNU General Public License as published by the Free Software +// Foundation; either version 2 of the License, or (at your option) any later +// version. +// +// This program is distributed in the hope that it will be useful, but WITHOUT +// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// this program; if not, write to the +// +// Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, +// Boston, MA +// 02110-1301 +// USA +// +//////////////////////////////////////////////////////////////////////////////// +#ifndef INCLUDED_UTIL +#define INCLUDED_UTIL + +#include +#include +#include +#include +#include "../auto.h" + +#ifndef min +#define min(a,b) ((a) < (b) ? (a) : (b)) +#endif + +#ifndef max +#define max(a,b) ((a) > (b) ? (a) : (b)) +#endif + +#define foreach(i, c) \ +for (typeof (c) *foreach_p = & (c); \ + foreach_p; \ + foreach_p = 0) \ + for (typeof (foreach_p->begin()) i = foreach_p->begin(); \ + i != foreach_p->end(); \ + ++i) + +// util.cpp +bool confirm (const std::string&); +void delay (float); +void formatTimeDeltaDays (std::string&, time_t); +std::string formatSeconds (time_t); +int autoComplete (const std::string&, const std::vector&, std::vector&); +const std::string uuid (); +int convertDuration (const std::string&); +std::string expandPath (const std::string&); + +#ifdef SOLARIS + #define LOCK_SH 1 + #define LOCK_EX 2 + #define LOCK_NB 4 + #define LOCK_UN 8 + + int flock (int, int); +#endif + +bool slurp (const std::string&, std::vector &, bool trimLines = false); +bool slurp (const std::string&, std::string&, bool trimLines = false); +void spit (const std::string&, const std::string&); + +#endif +//////////////////////////////////////////////////////////////////////////////// From 3a9c98d342c08cb846e95d63b790cc86c4bd42c6 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sun, 17 May 2009 23:31:25 -0400 Subject: [PATCH 018/417] FF4 - snapshot --- src/rewrite/Att.h | 2 +- src/rewrite/Context.cpp | 75 ++++++++++++++++++++++++++++++++++------- src/rewrite/Context.h | 8 +++-- src/rewrite/Makefile | 2 +- src/rewrite/Record.cpp | 5 +++ src/rewrite/Record.h | 6 +++- src/rewrite/T.cpp | 8 ++--- src/rewrite/T.h | 6 ++-- src/rewrite/TDB.cpp | 34 ++++++++++++++++++- src/rewrite/TDB.h | 8 +++++ src/rewrite/main.cpp | 3 +- 11 files changed, 127 insertions(+), 30 deletions(-) diff --git a/src/rewrite/Att.h b/src/rewrite/Att.h index e496a9261..708e82952 100644 --- a/src/rewrite/Att.h +++ b/src/rewrite/Att.h @@ -34,7 +34,7 @@ class Att { public: Att (); // Default constructor - Att (const std::string&, const std::string&); + Att (const std::string&, const std::string&); // Simple constructor Att (const Att&); // Copy constructor Att& operator= (const Att&); // Assignment operator ~Att (); // Destructor diff --git a/src/rewrite/Context.cpp b/src/rewrite/Context.cpp index 0f8b14c95..8c16ccfe4 100644 --- a/src/rewrite/Context.cpp +++ b/src/rewrite/Context.cpp @@ -25,11 +25,22 @@ // //////////////////////////////////////////////////////////////////////////////// +#include #include "Context.h" +#include "text.h" +#include "util.h" +#include "task.h" +#include "../auto.h" //////////////////////////////////////////////////////////////////////////////// Context::Context () { + // Set up randomness. +#ifdef HAVE_SRANDOM + srandom (time (NULL)); +#else + srand (time (NULL)); +#endif } //////////////////////////////////////////////////////////////////////////////// @@ -67,24 +78,39 @@ Context::~Context () } //////////////////////////////////////////////////////////////////////////////// -void Context::initialize () +void Context::initialize (int argc, char** argv) { - throw std::string ("unimplemented Context::initialize"); - // TODO Load config. + // Load the config file from the home directory. If the file cannot be + // found, offer to create a sample one. + loadCorrectConfigFile (argc, argv); + + // When redirecting output to a file, do not use color, curses. + if (!isatty (fileno (stdout))) + { + config.set ("curses", "off"); + + if (! config.get (std::string ("_forcecolor"), false)) + config.set ("color", "off"); + } + + // TODO Handle "--version, -v" right here. + + // init TDB. + std::string location = config.get ("data.location"); + std::vector all; + split (all, location, ','); + foreach (path, all) + tdb.location (expandPath (*path)); + + // Allow user override of file locking. Solaris/NFS machines may want this. + if (! config.get ("locking", true)) + tdb.noLock (); + // TODO Load pending.data. // TODO Load completed.data. // TODO Load deleted.data. } -//////////////////////////////////////////////////////////////////////////////// -int Context::commandLine (int argc, char** argv) -{ - throw std::string ("unimplemented Context::commandLine"); - // TODO Support rc: override. - // TODO Handle "--version, -v" right here. - return 0; -} - //////////////////////////////////////////////////////////////////////////////// int Context::run () { @@ -97,4 +123,29 @@ int Context::run () } //////////////////////////////////////////////////////////////////////////////// +void Context::loadCorrectConfigFile (int argc, char** argv) +{ + for (int i = 1; i < argc; ++i) + { + if (! strncmp (argv[i], "rc:", 3)) + { + if (! access (&(argv[i][3]), F_OK)) + { + std::string file = &(argv[i][3]); + config.load (file); + return; + } + else + throw std::string ("Could not read configuration file '") + &(argv[i][3]) + "'"; + } + } + struct passwd* pw = getpwuid (getuid ()); + if (!pw) + throw std::string ("Could not read home directory from passwd file."); + + std::string file = pw->pw_dir; + config.createDefault (file); +} + +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Context.h b/src/rewrite/Context.h index 26753a5eb..c0d50c68a 100644 --- a/src/rewrite/Context.h +++ b/src/rewrite/Context.h @@ -31,8 +31,8 @@ #include "Keymap.h" #include "Config.h" #include "Sequence.h" -#include "TDB.h" #include "T.h" +#include "TDB.h" class Context @@ -43,10 +43,12 @@ public: Context& operator= (const Context&); // Assignment operator ~Context (); // Destructor - void initialize (); - int commandLine (int, char**); + void initialize (int, char**); int run (); +private: + void loadCorrectConfigFile (int, char**); + public: Config config; Filter filter; diff --git a/src/rewrite/Makefile b/src/rewrite/Makefile index f4021e3ba..fd26bdde4 100644 --- a/src/rewrite/Makefile +++ b/src/rewrite/Makefile @@ -3,7 +3,7 @@ CFLAGS = -I. -I.. -Wall -pedantic -ggdb3 -fno-rtti -fstack-check LFLAGS = LIBS = OBJECTS = main.o Context.o TDB.o T.o Sequence.o Filter.o Att.o Keymap.o \ - ../util.o ../text.o ../Config.o ../Date.o + Record.o ../util.o ../text.o ../Config.o ../Date.o all: $(PROJECT) diff --git a/src/rewrite/Record.cpp b/src/rewrite/Record.cpp index f74517d9d..4249ac7e0 100644 --- a/src/rewrite/Record.cpp +++ b/src/rewrite/Record.cpp @@ -57,4 +57,9 @@ Record::~Record () } //////////////////////////////////////////////////////////////////////////////// +void Record::parse (const std::string& input) +{ + throw std::string ("unimplemented Record::parse"); +} +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Record.h b/src/rewrite/Record.h index 20c10977d..d35e8a02e 100644 --- a/src/rewrite/Record.h +++ b/src/rewrite/Record.h @@ -36,7 +36,11 @@ public: Record (); // Default constructor Record (const Record&); // Copy constructor Record& operator= (const Record&); // Assignment operator - ~Record (); // Destructor + virtual ~Record (); // Destructor + + virtual std::string composeF4 () = 0; + virtual std::string composeCSV () = 0; + void parse (const std::string&); private: std::vector mAtts; diff --git a/src/rewrite/T.cpp b/src/rewrite/T.cpp index f88d4b179..af5f9c234 100644 --- a/src/rewrite/T.cpp +++ b/src/rewrite/T.cpp @@ -34,11 +34,13 @@ T::T () } //////////////////////////////////////////////////////////////////////////////// +/* T::T (const T& other) { throw std::string ("unimplemented T::T"); // mOne = other.mOne; } +*/ //////////////////////////////////////////////////////////////////////////////// T::T (const std::string& input) @@ -78,9 +80,3 @@ std::string T::composeCSV () } //////////////////////////////////////////////////////////////////////////////// -void T::parse (const std::string& input) -{ - throw std::string ("unimplemented T::parse"); -} - -//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/T.h b/src/rewrite/T.h index 1453c7347..8275956fb 100644 --- a/src/rewrite/T.h +++ b/src/rewrite/T.h @@ -28,19 +28,19 @@ #define INCLUDED_T #include +#include "Record.h" -class T +class T : public Record { public: T (); // Default constructor - T (const T&); // Copy constructor +// T (const T&); // Copy constructor T (const std::string&); // Parse T& operator= (const T&); // Assignment operator ~T (); // Destructor std::string composeF4 (); std::string composeCSV (); - void parse (const std::string&); private: }; diff --git a/src/rewrite/TDB.cpp b/src/rewrite/TDB.cpp index 5526a5611..3f2d658be 100644 --- a/src/rewrite/TDB.cpp +++ b/src/rewrite/TDB.cpp @@ -26,10 +26,14 @@ //////////////////////////////////////////////////////////////////////////////// #include +#include "text.h" +#include "util.h" #include "TDB.h" +#include "task.h" //////////////////////////////////////////////////////////////////////////////// TDB::TDB () +: mLock (true) { } @@ -60,7 +64,11 @@ TDB::~TDB () //////////////////////////////////////////////////////////////////////////////// void TDB::location (const std::string& path) { - throw std::string ("unimplemented TDB::location"); + if (access (expandPath (path).c_str (), F_OK)) + throw std::string ("Data location '") + + path + + "' does not exist, or is not readable and writable."; + mLocations.push_back (path); } @@ -94,3 +102,27 @@ void TDB::upgrade () } //////////////////////////////////////////////////////////////////////////////// +void TDB::noLock () +{ + mLock = false; +} + +//////////////////////////////////////////////////////////////////////////////// +void TDB::getPendingFiles (std::vector files) +{ + files.clear (); + + foreach (location, mLocations) + files.push_back (*location + "/pending.data"); +} + +//////////////////////////////////////////////////////////////////////////////// +void TDB::getCompletedFiles (std::vector files) +{ + files.clear (); + + foreach (location, mLocations) + files.push_back (*location + "/completed.data"); +} + +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/TDB.h b/src/rewrite/TDB.h index 468fefb47..0e6721fb1 100644 --- a/src/rewrite/TDB.h +++ b/src/rewrite/TDB.h @@ -46,8 +46,16 @@ public: int commit (); void upgrade (); + void noLock (); + +private: + void getPendingFiles (std::vector ); + void getCompletedFiles (std::vector ); + private: std::vector mLocations; + bool mLock; + // TODO Need cache of raw file contents. }; diff --git a/src/rewrite/main.cpp b/src/rewrite/main.cpp index b145dae1d..3b1cc6c5b 100644 --- a/src/rewrite/main.cpp +++ b/src/rewrite/main.cpp @@ -8,8 +8,7 @@ int main (int argc, char** argv) try { Context c; - c.initialize (); - c.commandLine (argc, argv); + c.initialize (argc, argv); c.run (); return 0; From c754e35b5b61bf6884016fff16730eb54e5fd88e Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Mon, 18 May 2009 09:05:21 -0400 Subject: [PATCH 019/417] Patch - Changed directory structure for scripts and their installation. From b6ec4af427c5c5d37f16b80236ccea34e4d8de5a Mon Sep 17 00:00:00 2001 From: Federico Hernandez Date: Mon, 18 May 2009 12:32:55 +0200 Subject: [PATCH] Changed directory structure for scripts and their installation. $(docdir) now depends on ${VERSION} variable defined from configure.ac Made EXTRA_DIST variable modular. --- Makefile.am | 19 +++++-- Makefile.in | 131 ++++++++++++++++++++++++++++++++++-------------- src/Makefile.in | 20 ++++---- 3 files changed, 118 insertions(+), 52 deletions(-) diff --git a/Makefile.am b/Makefile.am index ef5a91973..5d240ad25 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,6 +1,19 @@ SUBDIRS = src -EXTRA_DIST = task_completion.sh doc/man1/task.1 doc/man5/taskrc.5 + +MAN_DIST = doc/man1/task.1 doc/man5/taskrc.5 +SCRIPTS_DIST = scripts/bash/task_completion.sh scripts/zsh/_task +EXTRA_DIST = $(MAN_DIST) $(SCRIPTS_DIST) + man1_MANS = doc/man1/task.1 man5_MANS = doc/man5/taskrc.5 -otherdir = $(datadir)/doc/task-1.7.0 -other_DATA = AUTHORS ChangeLog COPYING INSTALL NEWS README task_completion.sh + +docdir = $(datadir)/doc/${PACKAGE}-${VERSION} +doc_DATA = AUTHORS ChangeLog COPYING INSTALL NEWS README + +scriptsbasedir = $(docdir)/scripts + +bashscriptsdir = $(scriptsbasedir)/bash +bashscripts_DATA = scripts/bash/task_completion.sh + +zshscriptsdir = $(scriptsbasedir)/zsh +zshscripts_DATA = scripts/zsh/_task diff --git a/Makefile.in b/Makefile.in index ef5a3619f..6b2690e1f 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1,8 +1,8 @@ -# Makefile.in generated by automake 1.10 from Makefile.am. +# Makefile.in generated by automake 1.10.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006 Free Software Foundation, Inc. +# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -55,7 +55,8 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ ps-recursive uninstall-recursive man1dir = $(mandir)/man1 am__installdirs = "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" \ - "$(DESTDIR)$(otherdir)" + "$(DESTDIR)$(bashscriptsdir)" "$(DESTDIR)$(docdir)" \ + "$(DESTDIR)$(zshscriptsdir)" man5dir = $(mandir)/man5 NROFF = nroff MANS = $(man1_MANS) $(man5_MANS) @@ -65,8 +66,10 @@ am__vpath_adj = case $$p in \ *) f=$$p;; \ esac; am__strip_dir = `echo $$p | sed -e 's|^.*/||'`; -otherDATA_INSTALL = $(INSTALL_DATA) -DATA = $(other_DATA) +bashscriptsDATA_INSTALL = $(INSTALL_DATA) +docDATA_INSTALL = $(INSTALL_DATA) +zshscriptsDATA_INSTALL = $(INSTALL_DATA) +DATA = $(bashscripts_DATA) $(doc_DATA) $(zshscripts_DATA) RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive ETAGS = etags @@ -145,7 +148,7 @@ build_alias = @build_alias@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ -docdir = @docdir@ +docdir = $(datadir)/doc/${PACKAGE}-${VERSION} dvidir = @dvidir@ exec_prefix = @exec_prefix@ host_alias = @host_alias@ @@ -169,14 +172,21 @@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ SUBDIRS = src -EXTRA_DIST = task_completion.sh doc/man1/task.1 doc/man5/taskrc.5 +MAN_DIST = doc/man1/task.1 doc/man5/taskrc.5 +SCRIPTS_DIST = scripts/bash/task_completion.sh scripts/zsh/_task +EXTRA_DIST = $(MAN_DIST) $(SCRIPTS_DIST) man1_MANS = doc/man1/task.1 man5_MANS = doc/man5/taskrc.5 -otherdir = $(datadir)/doc/task-1.7.0 -other_DATA = AUTHORS ChangeLog COPYING INSTALL NEWS README task_completion.sh +doc_DATA = AUTHORS ChangeLog COPYING INSTALL NEWS README +scriptsbasedir = $(docdir)/scripts +bashscriptsdir = $(scriptsbasedir)/bash +bashscripts_DATA = scripts/bash/task_completion.sh +zshscriptsdir = $(scriptsbasedir)/zsh +zshscripts_DATA = scripts/zsh/_task all: auto.h $(MAKE) $(AM_MAKEFLAGS) all-recursive @@ -321,22 +331,56 @@ uninstall-man5: echo " rm -f '$(DESTDIR)$(man5dir)/$$inst'"; \ rm -f "$(DESTDIR)$(man5dir)/$$inst"; \ done -install-otherDATA: $(other_DATA) +install-bashscriptsDATA: $(bashscripts_DATA) @$(NORMAL_INSTALL) - test -z "$(otherdir)" || $(MKDIR_P) "$(DESTDIR)$(otherdir)" - @list='$(other_DATA)'; for p in $$list; do \ + test -z "$(bashscriptsdir)" || $(MKDIR_P) "$(DESTDIR)$(bashscriptsdir)" + @list='$(bashscripts_DATA)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ f=$(am__strip_dir) \ - echo " $(otherDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(otherdir)/$$f'"; \ - $(otherDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(otherdir)/$$f"; \ + echo " $(bashscriptsDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(bashscriptsdir)/$$f'"; \ + $(bashscriptsDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(bashscriptsdir)/$$f"; \ done -uninstall-otherDATA: +uninstall-bashscriptsDATA: @$(NORMAL_UNINSTALL) - @list='$(other_DATA)'; for p in $$list; do \ + @list='$(bashscripts_DATA)'; for p in $$list; do \ f=$(am__strip_dir) \ - echo " rm -f '$(DESTDIR)$(otherdir)/$$f'"; \ - rm -f "$(DESTDIR)$(otherdir)/$$f"; \ + echo " rm -f '$(DESTDIR)$(bashscriptsdir)/$$f'"; \ + rm -f "$(DESTDIR)$(bashscriptsdir)/$$f"; \ + done +install-docDATA: $(doc_DATA) + @$(NORMAL_INSTALL) + test -z "$(docdir)" || $(MKDIR_P) "$(DESTDIR)$(docdir)" + @list='$(doc_DATA)'; for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + f=$(am__strip_dir) \ + echo " $(docDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(docdir)/$$f'"; \ + $(docDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(docdir)/$$f"; \ + done + +uninstall-docDATA: + @$(NORMAL_UNINSTALL) + @list='$(doc_DATA)'; for p in $$list; do \ + f=$(am__strip_dir) \ + echo " rm -f '$(DESTDIR)$(docdir)/$$f'"; \ + rm -f "$(DESTDIR)$(docdir)/$$f"; \ + done +install-zshscriptsDATA: $(zshscripts_DATA) + @$(NORMAL_INSTALL) + test -z "$(zshscriptsdir)" || $(MKDIR_P) "$(DESTDIR)$(zshscriptsdir)" + @list='$(zshscripts_DATA)'; for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + f=$(am__strip_dir) \ + echo " $(zshscriptsDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(zshscriptsdir)/$$f'"; \ + $(zshscriptsDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(zshscriptsdir)/$$f"; \ + done + +uninstall-zshscriptsDATA: + @$(NORMAL_UNINSTALL) + @list='$(zshscripts_DATA)'; for p in $$list; do \ + f=$(am__strip_dir) \ + echo " rm -f '$(DESTDIR)$(zshscriptsdir)/$$f'"; \ + rm -f "$(DESTDIR)$(zshscriptsdir)/$$f"; \ done # This directory's subdirectories are mostly independent; you can cd @@ -414,8 +458,8 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ mkid -fID $$unique tags: TAGS @@ -440,8 +484,8 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) auto.h.in $(TAGS_DEPENDENCIES) \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ @@ -451,13 +495,12 @@ ctags: CTAGS CTAGS: ctags-recursive $(HEADERS) $(SOURCES) auto.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ - here=`pwd`; \ list='$(SOURCES) $(HEADERS) auto.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique @@ -528,6 +571,10 @@ dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) +dist-lzma: distdir + tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma + $(am__remove_distdir) + dist-tarZ: distdir tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__remove_distdir) @@ -554,6 +601,8 @@ distcheck: dist GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ + *.tar.lzma*) \ + unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ @@ -617,7 +666,7 @@ check: check-recursive all-am: Makefile $(MANS) $(DATA) auto.h installdirs: installdirs-recursive installdirs-am: - for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(otherdir)"; do \ + for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(bashscriptsdir)" "$(DESTDIR)$(docdir)" "$(DESTDIR)$(zshscriptsdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-recursive @@ -663,7 +712,8 @@ info: info-recursive info-am: -install-data-am: install-man install-otherDATA +install-data-am: install-bashscriptsDATA install-docDATA install-man \ + install-zshscriptsDATA install-dvi: install-dvi-recursive @@ -699,7 +749,8 @@ ps: ps-recursive ps-am: -uninstall-am: uninstall-man uninstall-otherDATA +uninstall-am: uninstall-bashscriptsDATA uninstall-docDATA \ + uninstall-man uninstall-zshscriptsDATA uninstall-man: uninstall-man1 uninstall-man5 @@ -709,19 +760,21 @@ uninstall-man: uninstall-man1 uninstall-man5 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ all all-am am--refresh check check-am clean clean-generic \ ctags ctags-recursive dist dist-all dist-bzip2 dist-gzip \ - dist-shar dist-tarZ dist-zip distcheck distclean \ + dist-lzma dist-shar dist-tarZ dist-zip distcheck distclean \ distclean-generic distclean-hdr distclean-tags distcleancheck \ distdir distuninstallcheck dvi dvi-am html html-am info \ - info-am install install-am install-data install-data-am \ - install-dvi install-dvi-am install-exec install-exec-am \ - install-html install-html-am install-info install-info-am \ - install-man install-man1 install-man5 install-otherDATA \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - installdirs-am maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-generic pdf pdf-am ps ps-am tags \ - tags-recursive uninstall uninstall-am uninstall-man \ - uninstall-man1 uninstall-man5 uninstall-otherDATA + info-am install install-am install-bashscriptsDATA \ + install-data install-data-am install-docDATA install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-man1 install-man5 install-pdf install-pdf-am \ + install-ps install-ps-am install-strip install-zshscriptsDATA \ + installcheck installcheck-am installdirs installdirs-am \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic pdf pdf-am ps ps-am tags tags-recursive \ + uninstall uninstall-am uninstall-bashscriptsDATA \ + uninstall-docDATA uninstall-man uninstall-man1 uninstall-man5 \ + uninstall-zshscriptsDATA # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/src/Makefile.in b/src/Makefile.in index ea3982dc4..60381fbc4 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -1,8 +1,8 @@ -# Makefile.in generated by automake 1.10 from Makefile.am. +# Makefile.in generated by automake 1.10.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006 Free Software Foundation, Inc. +# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -50,7 +50,7 @@ am_task_OBJECTS = Config.$(OBJEXT) Date.$(OBJEXT) T.$(OBJEXT) \ util.$(OBJEXT) text.$(OBJEXT) rules.$(OBJEXT) import.$(OBJEXT) task_OBJECTS = $(am_task_OBJECTS) task_LDADD = $(LDADD) -DEFAULT_INCLUDES = -I. -I$(top_builddir)@am__isrc@ +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ @@ -153,6 +153,7 @@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ task_SOURCES = Config.cpp Date.cpp T.cpp TDB.cpp Table.cpp Grid.cpp Timer.cpp color.cpp parse.cpp task.cpp command.cpp edit.cpp report.cpp util.cpp text.cpp rules.cpp import.cpp Config.h Date.h T.h TDB.h Table.h Grid.h Timer.h color.h task.h @@ -259,8 +260,8 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ mkid -fID $$unique tags: TAGS @@ -272,8 +273,8 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ @@ -283,13 +284,12 @@ ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ - here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique From 124dc758611e3a23850d79f9783074b61d31b8d5 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Mon, 18 May 2009 09:10:18 -0400 Subject: [PATCH 020/417] Patch - Simplified structure with dist and nobase usage From 6f8080c6761a35811de5f3870b6ef7887b1a9414 Mon Sep 17 00:00:00 2001 From: Federico Hernandez Date: Mon, 18 May 2009 13:23:09 +0200 Subject: [PATCH] Simplified structure with dist and nobase usage --- Makefile.am | 18 +++----- Makefile.in | 122 +++++++++++++++++++++++++++------------------------- 2 files changed, 70 insertions(+), 70 deletions(-) diff --git a/Makefile.am b/Makefile.am index 5d240ad25..7749058e1 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,19 +1,13 @@ SUBDIRS = src -MAN_DIST = doc/man1/task.1 doc/man5/taskrc.5 -SCRIPTS_DIST = scripts/bash/task_completion.sh scripts/zsh/_task -EXTRA_DIST = $(MAN_DIST) $(SCRIPTS_DIST) - -man1_MANS = doc/man1/task.1 -man5_MANS = doc/man5/taskrc.5 +dist_man1_MANS = doc/man1/task.1 +dist_man5_MANS = doc/man5/taskrc.5 docdir = $(datadir)/doc/${PACKAGE}-${VERSION} doc_DATA = AUTHORS ChangeLog COPYING INSTALL NEWS README -scriptsbasedir = $(docdir)/scripts +bashscriptsdir = $(docdir) +nobase_dist_bashscripts_DATA = scripts/bash/task_completion.sh -bashscriptsdir = $(scriptsbasedir)/bash -bashscripts_DATA = scripts/bash/task_completion.sh - -zshscriptsdir = $(scriptsbasedir)/zsh -zshscripts_DATA = scripts/zsh/_task +zshscriptsdir = $(docdir) +nobase_dist_zshscripts_DATA = scripts/zsh/_task diff --git a/Makefile.in b/Makefile.in index 6b2690e1f..36f5d0118 100644 --- a/Makefile.in +++ b/Makefile.in @@ -31,7 +31,9 @@ NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : subdir = . -DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ +DIST_COMMON = README $(am__configure_deps) $(dist_man1_MANS) \ + $(dist_man5_MANS) $(nobase_dist_bashscripts_DATA) \ + $(nobase_dist_zshscripts_DATA) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/auto.h.in \ $(top_srcdir)/configure AUTHORS COPYING ChangeLog INSTALL NEWS \ depcomp install-sh missing @@ -55,21 +57,22 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ ps-recursive uninstall-recursive man1dir = $(mandir)/man1 am__installdirs = "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" \ - "$(DESTDIR)$(bashscriptsdir)" "$(DESTDIR)$(docdir)" \ + "$(DESTDIR)$(docdir)" "$(DESTDIR)$(bashscriptsdir)" \ "$(DESTDIR)$(zshscriptsdir)" man5dir = $(mandir)/man5 NROFF = nroff -MANS = $(man1_MANS) $(man5_MANS) +MANS = $(dist_man1_MANS) $(dist_man5_MANS) am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = `echo $$p | sed -e 's|^.*/||'`; -bashscriptsDATA_INSTALL = $(INSTALL_DATA) docDATA_INSTALL = $(INSTALL_DATA) -zshscriptsDATA_INSTALL = $(INSTALL_DATA) -DATA = $(bashscripts_DATA) $(doc_DATA) $(zshscripts_DATA) +nobase_dist_bashscriptsDATA_INSTALL = $(install_sh_DATA) +nobase_dist_zshscriptsDATA_INSTALL = $(install_sh_DATA) +DATA = $(doc_DATA) $(nobase_dist_bashscripts_DATA) \ + $(nobase_dist_zshscripts_DATA) RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive ETAGS = etags @@ -176,17 +179,13 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ SUBDIRS = src -MAN_DIST = doc/man1/task.1 doc/man5/taskrc.5 -SCRIPTS_DIST = scripts/bash/task_completion.sh scripts/zsh/_task -EXTRA_DIST = $(MAN_DIST) $(SCRIPTS_DIST) -man1_MANS = doc/man1/task.1 -man5_MANS = doc/man5/taskrc.5 +dist_man1_MANS = doc/man1/task.1 +dist_man5_MANS = doc/man5/taskrc.5 doc_DATA = AUTHORS ChangeLog COPYING INSTALL NEWS README -scriptsbasedir = $(docdir)/scripts -bashscriptsdir = $(scriptsbasedir)/bash -bashscripts_DATA = scripts/bash/task_completion.sh -zshscriptsdir = $(scriptsbasedir)/zsh -zshscripts_DATA = scripts/zsh/_task +bashscriptsdir = $(docdir) +nobase_dist_bashscripts_DATA = scripts/bash/task_completion.sh +zshscriptsdir = $(docdir) +nobase_dist_zshscripts_DATA = scripts/zsh/_task all: auto.h $(MAKE) $(AM_MAKEFLAGS) all-recursive @@ -331,23 +330,6 @@ uninstall-man5: echo " rm -f '$(DESTDIR)$(man5dir)/$$inst'"; \ rm -f "$(DESTDIR)$(man5dir)/$$inst"; \ done -install-bashscriptsDATA: $(bashscripts_DATA) - @$(NORMAL_INSTALL) - test -z "$(bashscriptsdir)" || $(MKDIR_P) "$(DESTDIR)$(bashscriptsdir)" - @list='$(bashscripts_DATA)'; for p in $$list; do \ - if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ - f=$(am__strip_dir) \ - echo " $(bashscriptsDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(bashscriptsdir)/$$f'"; \ - $(bashscriptsDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(bashscriptsdir)/$$f"; \ - done - -uninstall-bashscriptsDATA: - @$(NORMAL_UNINSTALL) - @list='$(bashscripts_DATA)'; for p in $$list; do \ - f=$(am__strip_dir) \ - echo " rm -f '$(DESTDIR)$(bashscriptsdir)/$$f'"; \ - rm -f "$(DESTDIR)$(bashscriptsdir)/$$f"; \ - done install-docDATA: $(doc_DATA) @$(NORMAL_INSTALL) test -z "$(docdir)" || $(MKDIR_P) "$(DESTDIR)$(docdir)" @@ -365,20 +347,41 @@ uninstall-docDATA: echo " rm -f '$(DESTDIR)$(docdir)/$$f'"; \ rm -f "$(DESTDIR)$(docdir)/$$f"; \ done -install-zshscriptsDATA: $(zshscripts_DATA) +install-nobase_dist_bashscriptsDATA: $(nobase_dist_bashscripts_DATA) @$(NORMAL_INSTALL) - test -z "$(zshscriptsdir)" || $(MKDIR_P) "$(DESTDIR)$(zshscriptsdir)" - @list='$(zshscripts_DATA)'; for p in $$list; do \ + test -z "$(bashscriptsdir)" || $(MKDIR_P) "$(DESTDIR)$(bashscriptsdir)" + @$(am__vpath_adj_setup) \ + list='$(nobase_dist_bashscripts_DATA)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ - f=$(am__strip_dir) \ - echo " $(zshscriptsDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(zshscriptsdir)/$$f'"; \ - $(zshscriptsDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(zshscriptsdir)/$$f"; \ + $(am__vpath_adj) \ + echo " $(nobase_dist_bashscriptsDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(bashscriptsdir)/$$f'"; \ + $(nobase_dist_bashscriptsDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(bashscriptsdir)/$$f"; \ done -uninstall-zshscriptsDATA: +uninstall-nobase_dist_bashscriptsDATA: @$(NORMAL_UNINSTALL) - @list='$(zshscripts_DATA)'; for p in $$list; do \ - f=$(am__strip_dir) \ + @$(am__vpath_adj_setup) \ + list='$(nobase_dist_bashscripts_DATA)'; for p in $$list; do \ + $(am__vpath_adj) \ + echo " rm -f '$(DESTDIR)$(bashscriptsdir)/$$f'"; \ + rm -f "$(DESTDIR)$(bashscriptsdir)/$$f"; \ + done +install-nobase_dist_zshscriptsDATA: $(nobase_dist_zshscripts_DATA) + @$(NORMAL_INSTALL) + test -z "$(zshscriptsdir)" || $(MKDIR_P) "$(DESTDIR)$(zshscriptsdir)" + @$(am__vpath_adj_setup) \ + list='$(nobase_dist_zshscripts_DATA)'; for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + $(am__vpath_adj) \ + echo " $(nobase_dist_zshscriptsDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(zshscriptsdir)/$$f'"; \ + $(nobase_dist_zshscriptsDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(zshscriptsdir)/$$f"; \ + done + +uninstall-nobase_dist_zshscriptsDATA: + @$(NORMAL_UNINSTALL) + @$(am__vpath_adj_setup) \ + list='$(nobase_dist_zshscripts_DATA)'; for p in $$list; do \ + $(am__vpath_adj) \ echo " rm -f '$(DESTDIR)$(zshscriptsdir)/$$f'"; \ rm -f "$(DESTDIR)$(zshscriptsdir)/$$f"; \ done @@ -666,7 +669,7 @@ check: check-recursive all-am: Makefile $(MANS) $(DATA) auto.h installdirs: installdirs-recursive installdirs-am: - for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(bashscriptsdir)" "$(DESTDIR)$(docdir)" "$(DESTDIR)$(zshscriptsdir)"; do \ + for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(docdir)" "$(DESTDIR)$(bashscriptsdir)" "$(DESTDIR)$(zshscriptsdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-recursive @@ -712,8 +715,9 @@ info: info-recursive info-am: -install-data-am: install-bashscriptsDATA install-docDATA install-man \ - install-zshscriptsDATA +install-data-am: install-docDATA install-man \ + install-nobase_dist_bashscriptsDATA \ + install-nobase_dist_zshscriptsDATA install-dvi: install-dvi-recursive @@ -749,8 +753,9 @@ ps: ps-recursive ps-am: -uninstall-am: uninstall-bashscriptsDATA uninstall-docDATA \ - uninstall-man uninstall-zshscriptsDATA +uninstall-am: uninstall-docDATA uninstall-man \ + uninstall-nobase_dist_bashscriptsDATA \ + uninstall-nobase_dist_zshscriptsDATA uninstall-man: uninstall-man1 uninstall-man5 @@ -763,18 +768,19 @@ uninstall-man: uninstall-man1 uninstall-man5 dist-lzma dist-shar dist-tarZ dist-zip distcheck distclean \ distclean-generic distclean-hdr distclean-tags distcleancheck \ distdir distuninstallcheck dvi dvi-am html html-am info \ - info-am install install-am install-bashscriptsDATA \ - install-data install-data-am install-docDATA install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-man1 install-man5 install-pdf install-pdf-am \ - install-ps install-ps-am install-strip install-zshscriptsDATA \ - installcheck installcheck-am installdirs installdirs-am \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic pdf pdf-am ps ps-am tags tags-recursive \ - uninstall uninstall-am uninstall-bashscriptsDATA \ + info-am install install-am install-data install-data-am \ + install-docDATA install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-man1 install-man5 \ + install-nobase_dist_bashscriptsDATA \ + install-nobase_dist_zshscriptsDATA install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs installdirs-am maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic pdf \ + pdf-am ps ps-am tags tags-recursive uninstall uninstall-am \ uninstall-docDATA uninstall-man uninstall-man1 uninstall-man5 \ - uninstall-zshscriptsDATA + uninstall-nobase_dist_bashscriptsDATA \ + uninstall-nobase_dist_zshscriptsDATA # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. From 81e96e0ec441e292fccb5e590910ebeab428c883 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Mon, 18 May 2009 21:08:54 -0400 Subject: [PATCH 021/417] Code Cleanup - removed Makefile.in from git - Makefile.in is a generated file, and there is no need to track it in git (thanks to Federico Hernandez). --- .gitignore | 1 + Makefile.in | 787 ------------------------------------------------ src/Makefile.in | 436 --------------------------- 3 files changed, 1 insertion(+), 1223 deletions(-) delete mode 100644 Makefile.in delete mode 100644 src/Makefile.in diff --git a/.gitignore b/.gitignore index 991be8f20..84f5bf192 100644 --- a/.gitignore +++ b/.gitignore @@ -8,6 +8,7 @@ src/Makefile */task stamp-h1 Makefile +Makefile.in configure config.log www.xls diff --git a/Makefile.in b/Makefile.in deleted file mode 100644 index 36f5d0118..000000000 --- a/Makefile.in +++ /dev/null @@ -1,787 +0,0 @@ -# Makefile.in generated by automake 1.10.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -pkgdatadir = $(datadir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -subdir = . -DIST_COMMON = README $(am__configure_deps) $(dist_man1_MANS) \ - $(dist_man5_MANS) $(nobase_dist_bashscripts_DATA) \ - $(nobase_dist_zshscripts_DATA) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in $(srcdir)/auto.h.in \ - $(top_srcdir)/configure AUTHORS COPYING ChangeLog INSTALL NEWS \ - depcomp install-sh missing -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ - configure.lineno config.status.lineno -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = auto.h -CONFIG_CLEAN_FILES = -SOURCES = -DIST_SOURCES = -RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ - html-recursive info-recursive install-data-recursive \ - install-dvi-recursive install-exec-recursive \ - install-html-recursive install-info-recursive \ - install-pdf-recursive install-ps-recursive install-recursive \ - installcheck-recursive installdirs-recursive pdf-recursive \ - ps-recursive uninstall-recursive -man1dir = $(mandir)/man1 -am__installdirs = "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" \ - "$(DESTDIR)$(docdir)" "$(DESTDIR)$(bashscriptsdir)" \ - "$(DESTDIR)$(zshscriptsdir)" -man5dir = $(mandir)/man5 -NROFF = nroff -MANS = $(dist_man1_MANS) $(dist_man5_MANS) -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = `echo $$p | sed -e 's|^.*/||'`; -docDATA_INSTALL = $(INSTALL_DATA) -nobase_dist_bashscriptsDATA_INSTALL = $(install_sh_DATA) -nobase_dist_zshscriptsDATA_INSTALL = $(install_sh_DATA) -DATA = $(doc_DATA) $(nobase_dist_bashscripts_DATA) \ - $(nobase_dist_zshscripts_DATA) -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -ETAGS = etags -CTAGS = ctags -DIST_SUBDIRS = $(SUBDIRS) -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -distdir = $(PACKAGE)-$(VERSION) -top_distdir = $(distdir) -am__remove_distdir = \ - { test ! -d $(distdir) \ - || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \ - && rm -fr $(distdir); }; } -DIST_ARCHIVES = $(distdir).tar.gz -GZIP_ENV = --best -distuninstallcheck_listfiles = find . -type f -print -distcleancheck_listfiles = find . -type f -print -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPPFLAGS = @CPPFLAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LTLIBOBJS = @LTLIBOBJS@ -MAKEINFO = @MAKEINFO@ -MKDIR_P = @MKDIR_P@ -OBJEXT = @OBJEXT@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build_alias = @build_alias@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = $(datadir)/doc/${PACKAGE}-${VERSION} -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host_alias = @host_alias@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -SUBDIRS = src -dist_man1_MANS = doc/man1/task.1 -dist_man5_MANS = doc/man5/taskrc.5 -doc_DATA = AUTHORS ChangeLog COPYING INSTALL NEWS README -bashscriptsdir = $(docdir) -nobase_dist_bashscripts_DATA = scripts/bash/task_completion.sh -zshscriptsdir = $(docdir) -nobase_dist_zshscripts_DATA = scripts/zsh/_task -all: auto.h - $(MAKE) $(AM_MAKEFLAGS) all-recursive - -.SUFFIXES: -am--refresh: - @: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - echo ' cd $(srcdir) && $(AUTOMAKE) --gnu '; \ - cd $(srcdir) && $(AUTOMAKE) --gnu \ - && exit 0; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \ - cd $(top_srcdir) && \ - $(AUTOMAKE) --gnu Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - echo ' $(SHELL) ./config.status'; \ - $(SHELL) ./config.status;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - $(SHELL) ./config.status --recheck - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(srcdir) && $(AUTOCONF) -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) - -auto.h: stamp-h1 - @if test ! -f $@; then \ - rm -f stamp-h1; \ - $(MAKE) $(AM_MAKEFLAGS) stamp-h1; \ - else :; fi - -stamp-h1: $(srcdir)/auto.h.in $(top_builddir)/config.status - @rm -f stamp-h1 - cd $(top_builddir) && $(SHELL) ./config.status auto.h -$(srcdir)/auto.h.in: $(am__configure_deps) - cd $(top_srcdir) && $(AUTOHEADER) - rm -f stamp-h1 - touch $@ - -distclean-hdr: - -rm -f auto.h stamp-h1 -install-man1: $(man1_MANS) $(man_MANS) - @$(NORMAL_INSTALL) - test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)" - @list='$(man1_MANS) $(dist_man1_MANS) $(nodist_man1_MANS)'; \ - l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ - for i in $$l2; do \ - case "$$i" in \ - *.1*) list="$$list $$i" ;; \ - esac; \ - done; \ - for i in $$list; do \ - if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \ - else file=$$i; fi; \ - ext=`echo $$i | sed -e 's/^.*\\.//'`; \ - case "$$ext" in \ - 1*) ;; \ - *) ext='1' ;; \ - esac; \ - inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ - inst=`echo $$inst | sed -e 's/^.*\///'`; \ - inst=`echo $$inst | sed '$(transform)'`.$$ext; \ - echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ - $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst"; \ - done -uninstall-man1: - @$(NORMAL_UNINSTALL) - @list='$(man1_MANS) $(dist_man1_MANS) $(nodist_man1_MANS)'; \ - l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ - for i in $$l2; do \ - case "$$i" in \ - *.1*) list="$$list $$i" ;; \ - esac; \ - done; \ - for i in $$list; do \ - ext=`echo $$i | sed -e 's/^.*\\.//'`; \ - case "$$ext" in \ - 1*) ;; \ - *) ext='1' ;; \ - esac; \ - inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ - inst=`echo $$inst | sed -e 's/^.*\///'`; \ - inst=`echo $$inst | sed '$(transform)'`.$$ext; \ - echo " rm -f '$(DESTDIR)$(man1dir)/$$inst'"; \ - rm -f "$(DESTDIR)$(man1dir)/$$inst"; \ - done -install-man5: $(man5_MANS) $(man_MANS) - @$(NORMAL_INSTALL) - test -z "$(man5dir)" || $(MKDIR_P) "$(DESTDIR)$(man5dir)" - @list='$(man5_MANS) $(dist_man5_MANS) $(nodist_man5_MANS)'; \ - l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ - for i in $$l2; do \ - case "$$i" in \ - *.5*) list="$$list $$i" ;; \ - esac; \ - done; \ - for i in $$list; do \ - if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \ - else file=$$i; fi; \ - ext=`echo $$i | sed -e 's/^.*\\.//'`; \ - case "$$ext" in \ - 5*) ;; \ - *) ext='5' ;; \ - esac; \ - inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ - inst=`echo $$inst | sed -e 's/^.*\///'`; \ - inst=`echo $$inst | sed '$(transform)'`.$$ext; \ - echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man5dir)/$$inst'"; \ - $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man5dir)/$$inst"; \ - done -uninstall-man5: - @$(NORMAL_UNINSTALL) - @list='$(man5_MANS) $(dist_man5_MANS) $(nodist_man5_MANS)'; \ - l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ - for i in $$l2; do \ - case "$$i" in \ - *.5*) list="$$list $$i" ;; \ - esac; \ - done; \ - for i in $$list; do \ - ext=`echo $$i | sed -e 's/^.*\\.//'`; \ - case "$$ext" in \ - 5*) ;; \ - *) ext='5' ;; \ - esac; \ - inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ - inst=`echo $$inst | sed -e 's/^.*\///'`; \ - inst=`echo $$inst | sed '$(transform)'`.$$ext; \ - echo " rm -f '$(DESTDIR)$(man5dir)/$$inst'"; \ - rm -f "$(DESTDIR)$(man5dir)/$$inst"; \ - done -install-docDATA: $(doc_DATA) - @$(NORMAL_INSTALL) - test -z "$(docdir)" || $(MKDIR_P) "$(DESTDIR)$(docdir)" - @list='$(doc_DATA)'; for p in $$list; do \ - if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ - f=$(am__strip_dir) \ - echo " $(docDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(docdir)/$$f'"; \ - $(docDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(docdir)/$$f"; \ - done - -uninstall-docDATA: - @$(NORMAL_UNINSTALL) - @list='$(doc_DATA)'; for p in $$list; do \ - f=$(am__strip_dir) \ - echo " rm -f '$(DESTDIR)$(docdir)/$$f'"; \ - rm -f "$(DESTDIR)$(docdir)/$$f"; \ - done -install-nobase_dist_bashscriptsDATA: $(nobase_dist_bashscripts_DATA) - @$(NORMAL_INSTALL) - test -z "$(bashscriptsdir)" || $(MKDIR_P) "$(DESTDIR)$(bashscriptsdir)" - @$(am__vpath_adj_setup) \ - list='$(nobase_dist_bashscripts_DATA)'; for p in $$list; do \ - if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ - $(am__vpath_adj) \ - echo " $(nobase_dist_bashscriptsDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(bashscriptsdir)/$$f'"; \ - $(nobase_dist_bashscriptsDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(bashscriptsdir)/$$f"; \ - done - -uninstall-nobase_dist_bashscriptsDATA: - @$(NORMAL_UNINSTALL) - @$(am__vpath_adj_setup) \ - list='$(nobase_dist_bashscripts_DATA)'; for p in $$list; do \ - $(am__vpath_adj) \ - echo " rm -f '$(DESTDIR)$(bashscriptsdir)/$$f'"; \ - rm -f "$(DESTDIR)$(bashscriptsdir)/$$f"; \ - done -install-nobase_dist_zshscriptsDATA: $(nobase_dist_zshscripts_DATA) - @$(NORMAL_INSTALL) - test -z "$(zshscriptsdir)" || $(MKDIR_P) "$(DESTDIR)$(zshscriptsdir)" - @$(am__vpath_adj_setup) \ - list='$(nobase_dist_zshscripts_DATA)'; for p in $$list; do \ - if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ - $(am__vpath_adj) \ - echo " $(nobase_dist_zshscriptsDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(zshscriptsdir)/$$f'"; \ - $(nobase_dist_zshscriptsDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(zshscriptsdir)/$$f"; \ - done - -uninstall-nobase_dist_zshscriptsDATA: - @$(NORMAL_UNINSTALL) - @$(am__vpath_adj_setup) \ - list='$(nobase_dist_zshscripts_DATA)'; for p in $$list; do \ - $(am__vpath_adj) \ - echo " rm -f '$(DESTDIR)$(zshscriptsdir)/$$f'"; \ - rm -f "$(DESTDIR)$(zshscriptsdir)/$$f"; \ - done - -# This directory's subdirectories are mostly independent; you can cd -# into them and run `make' without going through this Makefile. -# To change the values of `make' variables: instead of editing Makefiles, -# (1) if the variable is set in `config.status', edit `config.status' -# (which will cause the Makefiles to be regenerated when you run `make'); -# (2) otherwise, pass the desired values on the `make' command line. -$(RECURSIVE_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -$(RECURSIVE_CLEAN_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ - dot_seen=no; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - rev=''; for subdir in $$list; do \ - if test "$$subdir" = "."; then :; else \ - rev="$$subdir $$rev"; \ - fi; \ - done; \ - rev="$$rev ."; \ - target=`echo $@ | sed s/-recursive//`; \ - for subdir in $$rev; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done && test -z "$$fail" -tags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ - done -ctags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ - done - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: tags-recursive $(HEADERS) $(SOURCES) auto.h.in $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - tags=; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - list='$(SOURCES) $(HEADERS) auto.h.in $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$tags $$unique; \ - fi -ctags: CTAGS -CTAGS: ctags-recursive $(HEADERS) $(SOURCES) auto.h.in $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - tags=; \ - list='$(SOURCES) $(HEADERS) auto.h.in $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - test -z "$(CTAGS_ARGS)$$tags$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$tags $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && cd $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) $$here - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - $(am__remove_distdir) - test -d $(distdir) || mkdir $(distdir) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ - fi; \ - cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ - else \ - test -f $(distdir)/$$file \ - || cp -p $$d/$$file $(distdir)/$$file \ - || exit 1; \ - fi; \ - done - list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - distdir=`$(am__cd) $(distdir) && pwd`; \ - top_distdir=`$(am__cd) $(top_distdir) && pwd`; \ - (cd $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$top_distdir" \ - distdir="$$distdir/$$subdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - distdir) \ - || exit 1; \ - fi; \ - done - -find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ - ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ - || chmod -R a+r $(distdir) -dist-gzip: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) - -dist-bzip2: distdir - tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 - $(am__remove_distdir) - -dist-lzma: distdir - tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma - $(am__remove_distdir) - -dist-tarZ: distdir - tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z - $(am__remove_distdir) - -dist-shar: distdir - shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz - $(am__remove_distdir) - -dist-zip: distdir - -rm -f $(distdir).zip - zip -rq $(distdir).zip $(distdir) - $(am__remove_distdir) - -dist dist-all: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) - -# This target untars the dist file and tries a VPATH configuration. Then -# it guarantees that the distribution is self-contained by making another -# tarfile. -distcheck: dist - case '$(DIST_ARCHIVES)' in \ - *.tar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ - *.tar.bz2*) \ - bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ - *.tar.lzma*) \ - unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\ - *.tar.Z*) \ - uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ - *.shar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ - *.zip*) \ - unzip $(distdir).zip ;;\ - esac - chmod -R a-w $(distdir); chmod a+w $(distdir) - mkdir $(distdir)/_build - mkdir $(distdir)/_inst - chmod a-w $(distdir) - dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ - && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ - && cd $(distdir)/_build \ - && ../configure --srcdir=.. --prefix="$$dc_install_base" \ - $(DISTCHECK_CONFIGURE_FLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) dvi \ - && $(MAKE) $(AM_MAKEFLAGS) check \ - && $(MAKE) $(AM_MAKEFLAGS) install \ - && $(MAKE) $(AM_MAKEFLAGS) installcheck \ - && $(MAKE) $(AM_MAKEFLAGS) uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ - distuninstallcheck \ - && chmod -R a-w "$$dc_install_base" \ - && ({ \ - (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ - distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ - } || { rm -rf "$$dc_destdir"; exit 1; }) \ - && rm -rf "$$dc_destdir" \ - && $(MAKE) $(AM_MAKEFLAGS) dist \ - && rm -rf $(DIST_ARCHIVES) \ - && $(MAKE) $(AM_MAKEFLAGS) distcleancheck - $(am__remove_distdir) - @(echo "$(distdir) archives ready for distribution: "; \ - list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ - sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' -distuninstallcheck: - @cd $(distuninstallcheck_dir) \ - && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ - || { echo "ERROR: files left after uninstall:" ; \ - if test -n "$(DESTDIR)"; then \ - echo " (check DESTDIR support)"; \ - fi ; \ - $(distuninstallcheck_listfiles) ; \ - exit 1; } >&2 -distcleancheck: distclean - @if test '$(srcdir)' = . ; then \ - echo "ERROR: distcleancheck can only run from a VPATH build" ; \ - exit 1 ; \ - fi - @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ - || { echo "ERROR: files left in build directory after distclean:" ; \ - $(distcleancheck_listfiles) ; \ - exit 1; } >&2 -check-am: all-am -check: check-recursive -all-am: Makefile $(MANS) $(DATA) auto.h -installdirs: installdirs-recursive -installdirs-am: - for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(docdir)" "$(DESTDIR)$(bashscriptsdir)" "$(DESTDIR)$(zshscriptsdir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-recursive - -clean-am: clean-generic mostlyclean-am - -distclean: distclean-recursive - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -f Makefile -distclean-am: clean-am distclean-generic distclean-hdr distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -info: info-recursive - -info-am: - -install-data-am: install-docDATA install-man \ - install-nobase_dist_bashscriptsDATA \ - install-nobase_dist_zshscriptsDATA - -install-dvi: install-dvi-recursive - -install-exec-am: - -install-html: install-html-recursive - -install-info: install-info-recursive - -install-man: install-man1 install-man5 - -install-pdf: install-pdf-recursive - -install-ps: install-ps-recursive - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf $(top_srcdir)/autom4te.cache - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-generic - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: uninstall-docDATA uninstall-man \ - uninstall-nobase_dist_bashscriptsDATA \ - uninstall-nobase_dist_zshscriptsDATA - -uninstall-man: uninstall-man1 uninstall-man5 - -.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \ - install-strip - -.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ - all all-am am--refresh check check-am clean clean-generic \ - ctags ctags-recursive dist dist-all dist-bzip2 dist-gzip \ - dist-lzma dist-shar dist-tarZ dist-zip distcheck distclean \ - distclean-generic distclean-hdr distclean-tags distcleancheck \ - distdir distuninstallcheck dvi dvi-am html html-am info \ - info-am install install-am install-data install-data-am \ - install-docDATA install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-man1 install-man5 \ - install-nobase_dist_bashscriptsDATA \ - install-nobase_dist_zshscriptsDATA install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs installdirs-am maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-generic pdf \ - pdf-am ps ps-am tags tags-recursive uninstall uninstall-am \ - uninstall-docDATA uninstall-man uninstall-man1 uninstall-man5 \ - uninstall-nobase_dist_bashscriptsDATA \ - uninstall-nobase_dist_zshscriptsDATA - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/src/Makefile.in b/src/Makefile.in deleted file mode 100644 index 60381fbc4..000000000 --- a/src/Makefile.in +++ /dev/null @@ -1,436 +0,0 @@ -# Makefile.in generated by automake 1.10.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -pkgdatadir = $(datadir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -bin_PROGRAMS = task$(EXEEXT) -subdir = src -DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/auto.h -CONFIG_CLEAN_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" -binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) -PROGRAMS = $(bin_PROGRAMS) -am_task_OBJECTS = Config.$(OBJEXT) Date.$(OBJEXT) T.$(OBJEXT) \ - TDB.$(OBJEXT) Table.$(OBJEXT) Grid.$(OBJEXT) Timer.$(OBJEXT) \ - color.$(OBJEXT) parse.$(OBJEXT) task.$(OBJEXT) \ - command.$(OBJEXT) edit.$(OBJEXT) report.$(OBJEXT) \ - util.$(OBJEXT) text.$(OBJEXT) rules.$(OBJEXT) import.$(OBJEXT) -task_OBJECTS = $(am_task_OBJECTS) -task_LDADD = $(LDADD) -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -CXXLD = $(CXX) -CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \ - -o $@ -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -CCLD = $(CC) -LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -SOURCES = $(task_SOURCES) -DIST_SOURCES = $(task_SOURCES) -ETAGS = etags -CTAGS = ctags -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPPFLAGS = @CPPFLAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LTLIBOBJS = @LTLIBOBJS@ -MAKEINFO = @MAKEINFO@ -MKDIR_P = @MKDIR_P@ -OBJEXT = @OBJEXT@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build_alias = @build_alias@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host_alias = @host_alias@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -task_SOURCES = Config.cpp Date.cpp T.cpp TDB.cpp Table.cpp Grid.cpp Timer.cpp color.cpp parse.cpp task.cpp command.cpp edit.cpp report.cpp util.cpp text.cpp rules.cpp import.cpp Config.h Date.h T.h TDB.h Table.h Grid.h Timer.h color.h task.h -all: all-am - -.SUFFIXES: -.SUFFIXES: .cpp .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ - && exit 0; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \ - cd $(top_srcdir) && \ - $(AUTOMAKE) --gnu src/Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -install-binPROGRAMS: $(bin_PROGRAMS) - @$(NORMAL_INSTALL) - test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" - @list='$(bin_PROGRAMS)'; for p in $$list; do \ - p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ - if test -f $$p \ - ; then \ - f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ - echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ - $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ - else :; fi; \ - done - -uninstall-binPROGRAMS: - @$(NORMAL_UNINSTALL) - @list='$(bin_PROGRAMS)'; for p in $$list; do \ - f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ - echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \ - rm -f "$(DESTDIR)$(bindir)/$$f"; \ - done - -clean-binPROGRAMS: - -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) -task$(EXEEXT): $(task_OBJECTS) $(task_DEPENDENCIES) - @rm -f task$(EXEEXT) - $(CXXLINK) $(task_OBJECTS) $(task_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Config.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Date.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Grid.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/T.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/TDB.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Table.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Timer.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/color.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/command.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/edit.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/import.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/report.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rules.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/task.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/text.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/util.Po@am__quote@ - -.cpp.o: -@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCXX_TRUE@ mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ $< - -.cpp.obj: -@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCXX_TRUE@ mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - tags=; \ - here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$tags $$unique; \ - fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - tags=; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - test -z "$(CTAGS_ARGS)$$tags$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$tags $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && cd $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) $$here - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ - fi; \ - cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ - else \ - test -f $(distdir)/$$file \ - || cp -p $$d/$$file $(distdir)/$$file \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(PROGRAMS) -installdirs: - for dir in "$(DESTDIR)$(bindir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-binPROGRAMS clean-generic mostlyclean-am - -distclean: distclean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-exec-am: install-binPROGRAMS - -install-html: install-html-am - -install-info: install-info-am - -install-man: - -install-pdf: install-pdf-am - -install-ps: install-ps-am - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-binPROGRAMS - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic ctags distclean distclean-compile \ - distclean-generic distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-binPROGRAMS \ - install-data install-data-am install-dvi install-dvi-am \ - install-exec install-exec-am install-html install-html-am \ - install-info install-info-am install-man install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic pdf pdf-am ps ps-am tags uninstall \ - uninstall-am uninstall-binPROGRAMS - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: From f97dff0125a18c782bd64e03358659b61a133f5b Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Mon, 18 May 2009 22:26:51 -0400 Subject: [PATCH 022/417] FF4 - Snapshot - Implemented TDB::lock, TDB::unlock. --- src/rewrite/Context.cpp | 6 +- src/rewrite/TDB.cpp | 119 ++++++++++++++++++++++++++++++++++++---- src/rewrite/TDB.h | 24 +++++--- 3 files changed, 126 insertions(+), 23 deletions(-) diff --git a/src/rewrite/Context.cpp b/src/rewrite/Context.cpp index 8c16ccfe4..35c64a68c 100644 --- a/src/rewrite/Context.cpp +++ b/src/rewrite/Context.cpp @@ -103,8 +103,7 @@ void Context::initialize (int argc, char** argv) tdb.location (expandPath (*path)); // Allow user override of file locking. Solaris/NFS machines may want this. - if (! config.get ("locking", true)) - tdb.noLock (); + tdb.lock (config.get ("locking", true)); // TODO Load pending.data. // TODO Load completed.data. @@ -114,11 +113,12 @@ void Context::initialize (int argc, char** argv) //////////////////////////////////////////////////////////////////////////////// int Context::run () { - throw std::string ("unimplemented Context::run"); // TODO Dispatch to command handlers. // TODO Auto shadow update. // TODO Auto gc. + // TODO tdb.load (Filter); + throw std::string ("unimplemented Context::run"); return 0; } diff --git a/src/rewrite/TDB.cpp b/src/rewrite/TDB.cpp index 3f2d658be..6a4ccb018 100644 --- a/src/rewrite/TDB.cpp +++ b/src/rewrite/TDB.cpp @@ -26,14 +26,45 @@ //////////////////////////////////////////////////////////////////////////////// #include +#include #include "text.h" #include "util.h" #include "TDB.h" #include "task.h" //////////////////////////////////////////////////////////////////////////////// +// The ctor/dtor do nothing. +// The lock/unlock methods hold the file open. +// There should be only one commit. +// +// +- TDB::TDB +// | +// | +- TDB::lock +// | | open +// | | [lock] +// | | +// | | +- TDB::load (Filter) +// | | | read all +// | | | apply filter +// | | | return subset +// | | | +// | | +- TDB::add (T) +// | | | +// | | +- TDB::update (T, T') +// | | | +// | | +- TDB::commit +// | | write all +// | | +// | +- TDB::unlock +// | [unlock] +// | close +// | +// +- TDB::~TDB +// [TDB::unlock] +// TDB::TDB () : mLock (true) +, mAllOpenAndLocked (false) { } @@ -41,7 +72,13 @@ TDB::TDB () TDB::TDB (const TDB& other) { throw std::string ("unimplemented TDB::TDB"); - mLocations = other.mLocations; + mLocations = other.mLocations; + mLock = other.mLock; + mAllOpenAndLocked = false; // Deliberately so. + + // Set all to NULL. + foreach (location, mLocations) + mLocations[location->first] = NULL; } //////////////////////////////////////////////////////////////////////////////// @@ -50,7 +87,13 @@ TDB& TDB::operator= (const TDB& other) throw std::string ("unimplemented TDB::operator="); if (this != &other) { - mLocations = other.mLocations; + mLocations = other.mLocations; + mLock = other.mLock; + mAllOpenAndLocked = false; // Deliberately so. + + // Set all to NULL. + foreach (location, mLocations) + mLocations[location->first] = NULL; } return *this; @@ -59,6 +102,8 @@ TDB& TDB::operator= (const TDB& other) //////////////////////////////////////////////////////////////////////////////// TDB::~TDB () { + if (mAllOpenAndLocked) + unlock (); } //////////////////////////////////////////////////////////////////////////////// @@ -69,7 +114,33 @@ void TDB::location (const std::string& path) path + "' does not exist, or is not readable and writable."; - mLocations.push_back (path); + mLocations[path] = NULL; +} + +//////////////////////////////////////////////////////////////////////////////// +void TDB::lock (bool lockFile /* = true */) +{ + mLock = lockFile; + + foreach (location, mLocations) + mLocations[location->first] = openAndLock (location->first); + + mAllOpenAndLocked = true; +} + +//////////////////////////////////////////////////////////////////////////////// +void TDB::unlock () +{ + foreach (location, mLocations) + { + if (mLocations[location->first] != NULL) + { + fclose (mLocations[location->first]); + mLocations[location->first] = NULL; + } + } + + mAllOpenAndLocked = false; } //////////////////////////////////////////////////////////////////////////////// @@ -80,6 +151,13 @@ int TDB::load (std::vector & tasks, Filter& filter) return 0; } +//////////////////////////////////////////////////////////////////////////////// +// TODO Write to transaction log. +void TDB::add (T& after) +{ + throw std::string ("unimplemented TDB::add"); +} + //////////////////////////////////////////////////////////////////////////////// // TODO Write to transaction log. void TDB::update (T& before, T& after) @@ -101,19 +179,13 @@ void TDB::upgrade () throw std::string ("unimplemented TDB::upgrade"); } -//////////////////////////////////////////////////////////////////////////////// -void TDB::noLock () -{ - mLock = false; -} - //////////////////////////////////////////////////////////////////////////////// void TDB::getPendingFiles (std::vector files) { files.clear (); foreach (location, mLocations) - files.push_back (*location + "/pending.data"); + files.push_back (location->first + "/pending.data"); } //////////////////////////////////////////////////////////////////////////////// @@ -122,7 +194,32 @@ void TDB::getCompletedFiles (std::vector files) files.clear (); foreach (location, mLocations) - files.push_back (*location + "/completed.data"); + files.push_back (location->first + "/completed.data"); +} + +//////////////////////////////////////////////////////////////////////////////// +FILE* TDB::openAndLock (const std::string& file) +{ + // Check for access. + if (access (file.c_str (), F_OK | R_OK | W_OK)) + throw std::string ("Task does not have the correct permissions for '") + + file + "'."; + + // Open the file. + FILE* in = fopen (file.c_str (), "rw"); + if (!in) + throw std::string ("Could not open '") + file + "'."; + + // Lock if desired. Try three times before failing. + int retry = 0; + if (mLock) + while (flock (fileno (in), LOCK_EX) && ++retry <= 3) + delay (0.1); + + if (!in) + throw std::string ("Could not lock '") + file + "'."; + + return in; } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/TDB.h b/src/rewrite/TDB.h index 0e6721fb1..c2f94f697 100644 --- a/src/rewrite/TDB.h +++ b/src/rewrite/TDB.h @@ -27,6 +27,7 @@ #ifndef INCLUDED_TDB #define INCLUDED_TDB +#include #include #include #include "Filter.h" @@ -40,21 +41,26 @@ public: TDB& operator= (const TDB&); // Assignment operator ~TDB (); // Destructor - void location (const std::string&); - int load (std::vector &, Filter&); - void update (T&, T&); - int commit (); - void upgrade (); + void location (const std::string&); - void noLock (); + void lock (bool lockFile = true); + void unlock (); + + int load (std::vector &, Filter&); + void add (T&); + void update (T&, T&); + int commit (); + void upgrade (); private: - void getPendingFiles (std::vector ); - void getCompletedFiles (std::vector ); + void getPendingFiles (std::vector ); + void getCompletedFiles (std::vector ); + FILE* openAndLock (const std::string&); private: - std::vector mLocations; + std::map mLocations; bool mLock; + bool mAllOpenAndLocked; // TODO Need cache of raw file contents. }; From e754fa6eacfc85346944607f80d1dca54499ef1a Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Tue, 19 May 2009 01:38:05 -0400 Subject: [PATCH 023/417] FF4 - Snapshot - Sketched out Filter - Implemented part of TDB --- src/rewrite/Att.cpp | 14 ++++++++++++-- src/rewrite/Context.cpp | 4 ++-- src/rewrite/Filter.cpp | 11 ++++++++--- src/rewrite/Filter.h | 4 ++-- src/rewrite/Sequence.cpp | 2 -- src/rewrite/Sequence.h | 5 +---- src/rewrite/T.cpp | 1 + src/rewrite/TDB.cpp | 7 +++++++ src/rewrite/main.cpp | 1 + 9 files changed, 34 insertions(+), 15 deletions(-) diff --git a/src/rewrite/Att.cpp b/src/rewrite/Att.cpp index 1082d77ad..43f51bdd7 100644 --- a/src/rewrite/Att.cpp +++ b/src/rewrite/Att.cpp @@ -152,14 +152,24 @@ bool Att::internal () const } //////////////////////////////////////////////////////////////////////////////// -// TODO Encode values prior to serialization. +// Encode values prior to serialization. +// \t -> &tab; +// " -> " +// , -> , +// [ -> &open; +// ] -> &close; void Att::encode (std::string&) const { throw std::string ("unimplemented Att::internal"); } //////////////////////////////////////////////////////////////////////////////// -// TODO Decode values after parse. +// Decode values after parse. +// \t <- &tab; +// " <- " +// , <- , +// [ <- &open; +// ] <- &close; void Att::decode (std::string&) const { throw std::string ("unimplemented Att::internal"); diff --git a/src/rewrite/Context.cpp b/src/rewrite/Context.cpp index 35c64a68c..20233e4eb 100644 --- a/src/rewrite/Context.cpp +++ b/src/rewrite/Context.cpp @@ -80,8 +80,8 @@ Context::~Context () //////////////////////////////////////////////////////////////////////////////// void Context::initialize (int argc, char** argv) { - // Load the config file from the home directory. If the file cannot be - // found, offer to create a sample one. + // Load the configuration file from the home directory. If the file cannot + // be found, offer to create a sample one. loadCorrectConfigFile (argc, argv); // When redirecting output to a file, do not use color, curses. diff --git a/src/rewrite/Filter.cpp b/src/rewrite/Filter.cpp index ba5e2b521..69751fb32 100644 --- a/src/rewrite/Filter.cpp +++ b/src/rewrite/Filter.cpp @@ -59,15 +59,20 @@ Filter::~Filter () //////////////////////////////////////////////////////////////////////////////// void Filter::add (Att& att) { - throw std::string ("unimplemented Filter::add"); mAtts.push_back (att); } //////////////////////////////////////////////////////////////////////////////// -bool Filter::pass (T&) +bool Filter::pass (Record& record) { throw std::string ("unimplemented Filter::pass"); - return false; +/* + foreach (att, mAtts) + if (! att->match (record)) + return false; +*/ + + return true; } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/Filter.h b/src/rewrite/Filter.h index 6f368b157..879956fe3 100644 --- a/src/rewrite/Filter.h +++ b/src/rewrite/Filter.h @@ -29,7 +29,7 @@ #include #include "Att.h" -#include "T.h" +#include "Record.h" class Filter { @@ -40,7 +40,7 @@ public: ~Filter (); // Destructor void add (Att&); - bool pass (T&); + bool pass (Record&); private: std::vector mAtts; diff --git a/src/rewrite/Sequence.cpp b/src/rewrite/Sequence.cpp index 709a23a46..4c6bcf7f7 100644 --- a/src/rewrite/Sequence.cpp +++ b/src/rewrite/Sequence.cpp @@ -37,7 +37,6 @@ Sequence::Sequence () Sequence::Sequence (const Sequence& other) { throw std::string ("unimplemented Sequence::Sequence"); - mSequence = other.mSequence; } //////////////////////////////////////////////////////////////////////////////// @@ -46,7 +45,6 @@ Sequence& Sequence::operator= (const Sequence& other) throw std::string ("unimplemented Sequence::operator="); if (this != &other) { - mSequence = other.mSequence; } return *this; diff --git a/src/rewrite/Sequence.h b/src/rewrite/Sequence.h index 57857785b..eb2abbee6 100644 --- a/src/rewrite/Sequence.h +++ b/src/rewrite/Sequence.h @@ -30,7 +30,7 @@ #include #include -class Sequence +class Sequence : public std::vector { public: Sequence (); // Default constructor @@ -39,9 +39,6 @@ public: ~Sequence (); // Destructor void parse (const std::string&); - -private: - std::vector mSequence; }; #endif diff --git a/src/rewrite/T.cpp b/src/rewrite/T.cpp index af5f9c234..933bf218f 100644 --- a/src/rewrite/T.cpp +++ b/src/rewrite/T.cpp @@ -66,6 +66,7 @@ T::~T () } //////////////////////////////////////////////////////////////////////////////// +// [name:value, name:"value",name:[name:value,name:value]] std::string T::composeF4 () { throw std::string ("unimplemented T::composeF4"); diff --git a/src/rewrite/TDB.cpp b/src/rewrite/TDB.cpp index 6a4ccb018..c53e9e9af 100644 --- a/src/rewrite/TDB.cpp +++ b/src/rewrite/TDB.cpp @@ -148,6 +148,10 @@ void TDB::unlock () int TDB::load (std::vector & tasks, Filter& filter) { throw std::string ("unimplemented TDB::load"); + + // TODO Read each row. + // TODO Let T::parse disassemble it. + // TODO If task passes filter, add to tasks. return 0; } @@ -156,6 +160,9 @@ int TDB::load (std::vector & tasks, Filter& filter) void TDB::add (T& after) { throw std::string ("unimplemented TDB::add"); + + // TODO Seek to end of pending. + // TODO write after.composeFF4 (). } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/rewrite/main.cpp b/src/rewrite/main.cpp index 3b1cc6c5b..a4571e89e 100644 --- a/src/rewrite/main.cpp +++ b/src/rewrite/main.cpp @@ -21,6 +21,7 @@ int main (int argc, char** argv) catch (...) { + std::cerr << "task internal error." << std::endl; } return -1; From 179f60ed8d17c66d8eb0a24fba457ec28f81e01e Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Tue, 19 May 2009 19:31:26 -0400 Subject: [PATCH 024/417] Bug Fix - _forcecolor considered obsolete - Fixed bug that considered the _forcecolor configuration variable to be obsolete. Thanks to Bruce Dillahunty. --- src/command.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/command.cpp b/src/command.cpp index 4a89427e1..41e8c6530 100644 --- a/src/command.cpp +++ b/src/command.cpp @@ -362,7 +362,7 @@ std::string handleVersion (Config& conf) // This configuration variable is supported, but not documented. It exists // so that unit tests can force color to be on even when the output from task // is redirected to a file, or stdout is not a tty. - recognized += " _forcecolor"; + recognized += "_forcecolor "; std::vector unrecognized; foreach (i, all) From b9448c3a2cd0e16626bcddac8680db781ddddb2e Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Tue, 19 May 2009 20:32:52 -0400 Subject: [PATCH 025/417] Documentation Update - snapshot --- ChangeLog | 3 ++- html/task.html | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index e9f75ac3f..90318d9f5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,7 +2,8 @@ ------ current release --------------------------- 1.8.0 (?) - + ? + + Fixed bug that cause the _forcecolor configuration variable to be + considered obsolete (thank to Bruce Dillahunty). ------ old releases ------------------------------ diff --git a/html/task.html b/html/task.html index 02203328f..2d307f23f 100644 --- a/html/task.html +++ b/html/task.html @@ -143,7 +143,8 @@

    New in version 1.8.0 (?)

      -
    • ? +
    • Fixed bug that cause the _forcecolor configuration variable to be + considered obsolete (thank to Bruce Dillahunty).

    From 8b17bdc037d1fd36f6faf6f2e8e4e062c53c41cd Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Tue, 19 May 2009 22:04:58 -0400 Subject: [PATCH 026/417] Bug Fix - documentation - Typo in documentation fixed (thanks to Thomas@BIC). - Added zsh tab completion script to ChangeLog (thanks to P.C. Shyamshankar). --- ChangeLog | 2 ++ html/sequence.html | 2 +- html/task.html | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 90318d9f5..41355afa7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,8 +2,10 @@ ------ current release --------------------------- 1.8.0 (?) + + Added zsh tab completion script (thanks to P.C. Shyamshankar). + Fixed bug that cause the _forcecolor configuration variable to be considered obsolete (thank to Bruce Dillahunty). + + Fixed documentation errors (thanks to Thomas@BIC). ------ old releases ------------------------------ diff --git a/html/sequence.html b/html/sequence.html index aa556ac3e..e2885e4fc 100644 --- a/html/sequence.html +++ b/html/sequence.html @@ -90,7 +90,7 @@

    The intent here is that task 3 have its description modified to be - "40123 is back-ordered, try again next week", but will be + "4-123 is back-ordered, try again next week", but will be misinterpreted as tasks 3, 4, 5, 6 ... 123 will all be modified to have the description "is back-ordered, try again next week". The solution is to quote the whole description: diff --git a/html/task.html b/html/task.html index 2d307f23f..a4b62710b 100644 --- a/html/task.html +++ b/html/task.html @@ -143,8 +143,10 @@

    New in version 1.8.0 (?)

      +
    • Added zsh tab completion script (thanks to P.C. Shyamshankar).
    • Fixed bug that cause the _forcecolor configuration variable to be considered obsolete (thank to Bruce Dillahunty). +
    • Fixed documentation errors (thanks to Thomas@BIC).

    From 3156e1c085cc544d3c7ec0119101f4f153ebfbfa Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Tue, 19 May 2009 23:28:16 -0400 Subject: [PATCH 027/417] Documentation Update - AUTHORS file - Added Thomas@BIC to the AUTHORS file, for his contribution and bug report. --- AUTHORS | 1 + 1 file changed, 1 insertion(+) diff --git a/AUTHORS b/AUTHORS index 5dc52124c..06795c1c6 100644 --- a/AUTHORS +++ b/AUTHORS @@ -33,4 +33,5 @@ With thanks to: Eric Farris Bruce Dillahunty Askme Too + Thomas@BIC From b194f37f1100b1a64af13024acf3597ae2823bb6 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Wed, 20 May 2009 20:30:08 -0400 Subject: [PATCH 028/417] Documentation Update - online docs - Added new download.html page to list current and prior binary packages only. - Removed old binary packages. - Reduced versions.html to a concatenation of ChangeLog entries. --- html/30second.html | 1 + html/advanced.html | 1 + html/color.html | 1 + html/config.html | 1 + html/custom.html | 1 + html/date.html | 1 + html/download.html | 148 ++++++++++++ html/faq.html | 1 + html/filter.html | 1 + html/git.html | 1 + html/import.html | 1 + html/links.html | 10 +- html/recur.html | 1 + html/sequence.html | 1 + html/setup.html | 1 + html/shadow.html | 1 + html/shell.html | 1 + html/simple.html | 1 + html/tab_completion.html | 1 + html/task.html | 9 +- html/versions.html | 506 ++++++++++++--------------------------- 21 files changed, 332 insertions(+), 358 deletions(-) create mode 100644 html/download.html diff --git a/html/30second.html b/html/30second.html index 38cef96ff..554fb0490 100644 --- a/html/30second.html +++ b/html/30second.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download

    diff --git a/html/advanced.html b/html/advanced.html index d7b412020..9f2a538ce 100644 --- a/html/advanced.html +++ b/html/advanced.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/color.html b/html/color.html index 37e985f0d..f10fd145c 100644 --- a/html/color.html +++ b/html/color.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/config.html b/html/config.html index 5cc6c010d..e19e24958 100644 --- a/html/config.html +++ b/html/config.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/custom.html b/html/custom.html index fa03a5249..8f85c6dec 100644 --- a/html/custom.html +++ b/html/custom.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/date.html b/html/date.html index d113993f7..e667432a8 100644 --- a/html/date.html +++ b/html/date.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/download.html b/html/download.html new file mode 100644 index 000000000..42bcc8db5 --- /dev/null +++ b/html/download.html @@ -0,0 +1,148 @@ + + + + Task Downloads + + + + + +
    +
  • + + + + + +
    + + +
    +
    +
    +
    +

    Task Downloads

    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    + You should use the latest stable release if possible, but + the prior release is provided in the event of + incompatibility or defect. +
    +
    +
    1.8.0 (Latest)
    ?/?/2009
    Sourcetask-1.8.0.tar.gz
    Fedora RPMtask-1.8.0-1.fc10.i386.rpm
    Debian Linuxtask-1.8.0-0.i386.deb
    OS X Leopard (Intel)task-1.8.0.pkg
    1.7.0 (Prior)
    5/14/2009
    Sourcetask-1.7.0.tar.gz
    Fedora RPMtask-1.7.0-2.fc10.i386.rpm
    + Unless you are a developer, you should not use the + development version. It is provided for those who + wish to contribute code to the project. +
    +
    +
    Development versionGit repositoryhttp://github.com/pbeckingham/task
    +
    + +
    +
    +
    +

    + Copyright 2006-2009, P. Beckingham. All rights reserved. +

    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    + + + +
    + +

    + + + + + + + diff --git a/html/faq.html b/html/faq.html index 5984ca489..94d6e249c 100644 --- a/html/faq.html +++ b/html/faq.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/filter.html b/html/filter.html index 373be27f5..d3f111573 100644 --- a/html/filter.html +++ b/html/filter.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/git.html b/html/git.html index 21b65305c..5ed782371 100644 --- a/html/git.html +++ b/html/git.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/import.html b/html/import.html index 3a488af36..8702261a1 100644 --- a/html/import.html +++ b/html/import.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/links.html b/html/links.html index 609f023a4..c42146540 100644 --- a/html/links.html +++ b/html/links.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    @@ -36,11 +37,18 @@ Task links from around the web...

    +
    + February 2009, Cmd Task Manager +
    +
    + Elliott Bradley takes a brief look at task 1.4.3. +
    +
    February 2009, Todo.txt CLI Manages Your Tasks from the Command Line
    - Gina Trapani generously mentions task in an article about the newly updated, todo.sh 2.0. + Gina Trapani generously mentions task in an article about the newly updated todo.sh 2.0.

    diff --git a/html/recur.html b/html/recur.html index a6963b842..925cd9c9d 100644 --- a/html/recur.html +++ b/html/recur.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/sequence.html b/html/sequence.html index e2885e4fc..bed36eb1a 100644 --- a/html/sequence.html +++ b/html/sequence.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/setup.html b/html/setup.html index 2cbcad404..dabe31a35 100644 --- a/html/setup.html +++ b/html/setup.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/shadow.html b/html/shadow.html index 1488a0167..bb8ade27d 100644 --- a/html/shadow.html +++ b/html/shadow.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/shell.html b/html/shell.html index 661f3723c..2545e5650 100644 --- a/html/shell.html +++ b/html/shell.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/simple.html b/html/simple.html index c256422fd..6cbe45dde 100644 --- a/html/simple.html +++ b/html/simple.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/tab_completion.html b/html/tab_completion.html index 02f6e27a3..a6b918e15 100644 --- a/html/tab_completion.html +++ b/html/tab_completion.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    diff --git a/html/task.html b/html/task.html index a4b62710b..bb375ebf7 100644 --- a/html/task.html +++ b/html/task.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download
    @@ -112,7 +113,7 @@
    - + - +
    Source:Source task-1.8.0.tar.gz
    Git - get the whole source and history:Git repository http://github.com/pbeckingham/task
    @@ -180,7 +181,9 @@

    If you have difficulties building task, have found a bug, have a suggestion for improvement, or a feature request, please send mail to - task@beckingham.net. + task@beckingham.net, or + post a message to the + taskprogram@googlegroups.com.

    diff --git a/html/versions.html b/html/versions.html index 1b1cda5e9..7488e7e6d 100644 --- a/html/versions.html +++ b/html/versions.html @@ -25,6 +25,7 @@ FAQ Old Versions Task on the Web + Download

    @@ -35,304 +36,156 @@
    -

    New in version 1.7.0 (5/14/2009)

    -

    - - - - - - - - - - -
    Source:task-1.7.0.tar.gz
    Git - get the whole source and history:http://github.com/pbeckingham/task
    - -

      -
    • Improved the errors when parsing a corrupt or unrecognized pending.data - or completed.data file (thanks to T. Charles Yun). -
    • Added details to the "info" report about recurring tasks (thanks to T. - Charles Yun). -
    • Now writes a sample "defaultwidth" configuration variable to the default - .taskrc file (thanks to T. Charles Yun). -
    • Task allows commands that require an ID to now be given a sequence, which - is a set of IDs. This allows commands like "task delete 1 2 5-10,12". -
    • Fixed bug in the ghistory report, which caused it to only show a new - month if a task was added during that month. -
    • New command "duplicate" which allows an existing task to be duplicated, - and also have modifications applied (thanks to David J Patrick). -
    • The "append", and "done" commands now allow modifications to be applied - to the task(s) (thanks to David J Patrick). -
    • Improved word wrapping in various output. -
    • Fixed bug that added an extra line between header and graph in the - ghistory report. -
    • Added simple 'taskprogram' mailing list subscribe form to the web site. -
    • For custom reports that define a "limit" to the number of rows of output - such as "oldest" and "newest", task allows an override value. For - example "task oldest 5" will display the 5 oldest tasks. -
    • Modified the "stats" report so that it has the same aesthetics as the - other reports. -
    • New "timesheet" command displays tasks completed and started, per week, - and can display multiple weeks. -
    • New tab completion script, task_completion.sh, for bash users, is installed - to /usr/local/share/task (thanks to Federico Hernandez). -
    • Applied patch to allow task to build on Arch Linux (thanks to Johan Friis). -
    • Applied patch to fix a UUID bug on Solaris 8 (thanks to Steven de Brouwer). -
    • The task man page is now installed. Try "man task" (thanks to Federico - Hernandez and P.C. Shyamshankar). -
    • Fixed bug that causes task to create a default .task directory, even if - data.location specified otherwise (thanks to Federico Hernandez). -
    • New "edit" command that fires up a text editor (uses 'editor' configuration - variable, $VISUAL or $EDITOR environment variable) and allows direct - editing of all editable task details. -
    -

    +
      +
    • Improved the errors when parsing a corrupt or unrecognized pending.data + or completed.data file (thanks to T. Charles Yun). +
    • Added details to the "info" report about recurring tasks (thanks to T. + Charles Yun). +
    • Now writes a sample "defaultwidth" configuration variable to the default + .taskrc file (thanks to T. Charles Yun). +
    • Task allows commands that require an ID to now be given a sequence, which + is a set of IDs. This allows commands like "task delete 1 2 5-10,12". +
    • Fixed bug in the ghistory report, which caused it to only show a new + month if a task was added during that month. +
    • New command "duplicate" which allows an existing task to be duplicated, + and also have modifications applied (thanks to David J Patrick). +
    • The "append", and "done" commands now allow modifications to be applied + to the task(s) (thanks to David J Patrick). +
    • Improved word wrapping in various output. +
    • Fixed bug that added an extra line between header and graph in the + ghistory report. +
    • Added simple 'taskprogram' mailing list subscribe form to the web site. +
    • For custom reports that define a "limit" to the number of rows of output + such as "oldest" and "newest", task allows an override value. For + example "task oldest 5" will display the 5 oldest tasks. +
    • Modified the "stats" report so that it has the same aesthetics as the + other reports. +
    • New "timesheet" command displays tasks completed and started, per week, + and can display multiple weeks. +
    • New tab completion script, task_completion.sh, for bash users, is installed + to /usr/local/share/task (thanks to Federico Hernandez). +
    • Applied patch to allow task to build on Arch Linux (thanks to Johan Friis). +
    • Applied patch to fix a UUID bug on Solaris 8 (thanks to Steven de Brouwer). +
    • The task man page is now installed. Try "man task" (thanks to Federico + Hernandez and P.C. Shyamshankar). +
    • Fixed bug that causes task to create a default .task directory, even if + data.location specified otherwise (thanks to Federico Hernandez). +
    • New "edit" command that fires up a text editor (uses 'editor' configuration + variable, $VISUAL or $EDITOR environment variable) and allows direct + editing of all editable task details. +

    New in version 1.6.1 (4/24/2009)

    -

    - - - - - - - - - - -
    Source:task-1.6.1.tar.gz
    Git - get the whole source and history:http://github.com/pbeckingham/task
    - -

      -
    • Fixed bug that caused new, first-time .taskrc files to be written without - including the custom report labels (thanks to P.C. Shyamshankar). -
    -

    +
      +
    • Fixed bug that caused new, first-time .taskrc files to be written without + including the custom report labels (thanks to P.C. Shyamshankar). +

    New in version 1.6.0 (4/13/2009)

    -

    - - - - - - - - - - - - - - -
    Source:task-1.6.0.tar.gz
    - Red Hat: - (Thanks to Federico Hernandez): - task-1.6.0-1.FC10.i386.rpm
    Git - get the whole source and history:http://github.com/pbeckingham/task
    +

      +
    • Added support for new "append" command that adds more description text to + an existing task. +
    • Added support for the "weekdays" recurrence, which means a task can recur + five times a week, and not on weekends (thanks to Chris Pride). +
    • UTF8 text is now supported in task project names, tags and descriptions. +
    • Fixed bug that caused the y/n confirmation on task deletion to ignore the + Enter key and fail to re-prompt (thanks to Bruce Dillahunty). +
    • When the "echo.command" configuration variable is set to "yes", it causes + commands that modify tasks to display which task was affected (thanks to + Bruce Dillahunty). +
    • A task can now be annotated with the command "task annotate ...", and + a timestamped annotation will appear in reports. +
    • A 'description_only' column is now available for use in custom reports, + and it excludes annotations. +
    • A task can now be upgraded to a recurring task by adding a recurrence + frequency, a due date, and an optional until date. +
    • When a recurring task is modified, all other instances of the recurring + task are also modified. +
    • Custom reports now support user-specified column labels (thanks to T. + Charles Yun). +
    • Task can now import tasks from a variety of data formats, including task + export files from versions 1.4.3 and earlier, versions 1.5.0 and later, + todo.sh 2.x, CSV, plain text and task command line. See online docs for + full details. +
    • Export was including 'id' in the column header even though it was not + included in the data. +
    • The task file format has changed slightly. Please back up your task + data files before upgrading to 1.6.0. +
    • Added new column 'recurrence_indicator' that displays an 'R' if the task + is a recurring task. This column can be added to any custom report. +
    • Added new column 'tag_indicator' that displays a '+' if the task + has any tags. This column can be added to any custom report. +
    • Fixed bug where sometimes a task description was concatenated oddly if + there was a colon somewhere in the description. +
    • Fixed bug that caused recurring annual tasks to exhibit a creeping due + date, because of an assumption of 365 days per year, which failed to + consider leap years (thanks to T. Charles Yun). +
    • Annotations can now be modified with the substitution commands /from/to/. +
    • Substitutions can now be made global with /from/to/g and all occurrences + of "from" will be replaced with "to". +
    -
      -
    • Added support for new "append" command that adds more description text to - an existing task. -
    • Added support for the "weekdays" recurrence, which means a task can recur - five times a week, and not on weekends (thanks to Chris Pride). -
    • UTF8 text is now supported in task project names, tags and descriptions. -
    • Fixed bug that caused the y/n confirmation on task deletion to ignore the - Enter key and fail to re-prompt (thanks to Bruce Dillahunty). -
    • When the "echo.command" configuration variable is set to "yes", it causes - commands that modify tasks to display which task was affected (thanks to - Bruce Dillahunty). -
    • A task can now be annotated with the command "task annotate ...", and - a timestamped annotation will appear in reports. -
    • A 'description_only' column is now available for use in custom reports, - and it excludes annotations. -
    • A task can now be upgraded to a recurring task by adding a recurrence - frequency, a due date, and an optional until date. -
    • When a recurring task is modified, all other instances of the recurring - task are also modified. -
    • Custom reports now support user-specified column labels (thanks to T. - Charles Yun). -
    • Task can now import tasks from a variety of data formats, including task - export files from versions 1.4.3 and earlier, versions 1.5.0 and later, - todo.sh 2.x, CSV, plain text and task command line. See online docs for - full details. -
    • Export was including 'id' in the column header even though it was not - included in the data. -
    • The task file format has changed slightly. Please back up your task - data files before upgrading to 1.6.0. -
    • Added new column 'recurrence_indicator' that displays an 'R' if the task - is a recurring task. This column can be added to any custom report. -
    • Added new column 'tag_indicator' that displays a '+' if the task - has any tags. This column can be added to any custom report. -
    • Fixed bug where sometimes a task description was concatenated oddly if - there was a colon somewhere in the description. -
    • Fixed bug that caused recurring annual tasks to exhibit a creeping due - date, because of an assumption of 365 days per year, which failed to - consider leap years (thanks to T. Charles Yun). -
    • Annotations can now be modified with the substitution commands /from/to/. -
    • Substitutions can now be made global with /from/to/g and all occurrences - of "from" will be replaced with "to". -
    -

    +

    New in version 1.5.0 (3/15/2009)

    +
      +
    • Removed deprecated TUTORIAL file. +
    • Removed support for the "showage" configuration variable. +
    • "task stop" can remove the start time from a started task. +
    • "task ghistory" now displays a differently aligned graph, allowing + easier comparison by month of tasks added versus completed and deleted. +
    • "task version" command now reports unrecognized configuration variables, + which may be spelling mistakes or deprecated variables. +
    • "configure --enable-debug" now supported to suppress compiler optimization + to allow debugging. +
    • Allow lower case priorities, and automatically upper case them. +
    • Added support for "due" configuration variable which defines the number + of days in the future when a task is considered due. +
    • Added support for custom reports, comprised of a set of column names and + sort order, with optional filtering in the configuration file. This + means user-defined reports can be written, and the reports currently + in the configuration file can be renamed. Several of task's built in + reports have been converted to user-defined reports. +
    • New online documentation for custom reports. +
    • New algorithm for determining when the "nag" message is displayed. +
    • Fixed bug where task hangs with a certain combination of recurring tasks + and shadow files. +
    • Fixed bug with the task sort algorithm, which led to an unstable sequence + when there were only a handful of tasks. +
    • Performance enhanced by eliminating unnecessary sorting. +
    • Task now has a large (and growing) test suite and bug regression tests + to help ensure higher quality releases. +
    • Fixed bug that caused large performance hit during table rendering. +
    • Fixed bug that concatenated a modified description without spaces. +
    • Added new column 'recur' that displays the recurrence period of any + recurring tasks. This column can be added to any custom report. +
    • Added support for "color.recurring" configuration variable which + specifies the color of recurring tasks. +
    • Added support for "locking" configuration variable that controls whether + file locking is used. +
    • Task export feature now includes recurrence information, removes nested + quotes, and limits output to pending tasks. +
    • Task no longer includes deleted tasks in the summary report (thanks to + Benjamin Tegarden). +
    • Fixed bug that prevented the summary report from properly reporting + recently completed tasks. +
    -

    -

    New in version 1.5.0 (3/15/2009)

    - - - - - - - - - - - - - - - - - -
    Source:task-1.5.0.tar.gz
    Mac OS X 10.5 (Leopard) Intel-only:task-1.5.0.pkg
    - Debian: - (Thanks to Richard Querin): - task_1.5.0-1_i386.deb
    - Red Hat: - (Thanks to Federico Hernandez): - task-1.5.0-1.i386.rpm
    -
      -
    • Removed deprecated TUTORIAL file. -
    • Removed support for the "showage" configuration variable. -
    • "task stop" can remove the start time from a started task. -
    • "task ghistory" now displays a differently aligned graph, allowing - easier comparison by month of tasks added versus completed and deleted. -
    • "task version" command now reports unrecognized configuration variables, - which may be spelling mistakes or deprecated variables. -
    • "configure --enable-debug" now supported to suppress compiler optimization - to allow debugging. -
    • Allow lower case priorities, and automatically upper case them. -
    • Added support for "due" configuration variable which defines the number - of days in the future when a task is considered due. -
    • Added support for custom reports, comprised of a set of column names and - sort order, with optional filtering in the configuration file. This - means user-defined reports can be written, and the reports currently - in the configuration file can be renamed. Several of task's built in - reports have been converted to user-defined reports. -
    • New online documentation for custom reports. -
    • New algorithm for determining when the "nag" message is displayed. -
    • Fixed bug where task hangs with a certain combination of recurring tasks - and shadow files. -
    • Fixed bug with the task sort algorithm, which led to an unstable sequence - when there were only a handful of tasks. -
    • Performance enhanced by eliminating unnecessary sorting. -
    • Task now has a large (and growing) test suite and bug regression tests - to help ensure higher quality releases. -
    • Fixed bug that caused large performance hit during table rendering. -
    • Fixed bug that concatenated a modified description without spaces. -
    • Added new column 'recur' that displays the recurrence period of any - recurring tasks. This column can be added to any custom report. -
    • Added support for "color.recurring" configuration variable which - specifies the color of recurring tasks. -
    • Added support for "locking" configuration variable that controls whether - file locking is used. -
    • Task export feature now includes recurrence information, removes nested - quotes, and limits output to pending tasks. -
    • Task no longer includes deleted tasks in the summary report (thanks to - Benjamin Tegarden). -
    • Fixed bug that prevented the summary report from properly reporting - recently completed tasks. -
    -

    - -

    -

    New in version 1.4.3 (11/1/2008)

    - task-1.4.3.tar.gz -
    - Mac OS X 10.5 (Leopard) Intel-only: - task-1.4.3.pkg -
    - Debian package: task_1.4.3-1_i386.deb - (Thanks to Richard Querin) -

    - -

    -

      -
    • Fixed misleading task count at bottom of "info" report. -
    • Added support for a shadow file that contains a plain text task report, - with the "shadow.file" and "shadow.command" configuration variables. - The shadow file is automatically updated whenever the task database - changes. Useful for integrating with "Samurize". -
    • Task now displays a message whenever a shadow file is updated, if the - "shadow.notify" configuration variable is set "on". -
    • Fixed bug whereby adding a task with a \n, \r or \f did not fail properly. -
    • Removed "task usage" command. -
    • Added documentation for Shadow files. -
    • Added documentation for task filters. -
    -

    - -

    -

    New in version 1.4.2 (9/18/2008)

    - task-1.4.2.tar.gz -
    - Mac OS X 10.5 (Leopard) Intel-only: - task-1.4.2.pkg -
    - Debian package: task_1.4.2-1_i386.deb - (Thanks to Richard Querin) -

    +

    New in version 1.4.3 (11/1/2008)

    +
      +
    • Fixed misleading task count at bottom of "info" report. +
    • Added support for a shadow file that contains a plain text task report, + with the "shadow.file" and "shadow.command" configuration variables. + The shadow file is automatically updated whenever the task database + changes. Useful for integrating with "Samurize". +
    • Task now displays a message whenever a shadow file is updated, if the + "shadow.notify" configuration variable is set "on". +
    • Fixed bug whereby adding a task with a \n, \r or \f did not fail properly. +
    • Removed "task usage" command. +
    • Added documentation for Shadow files. +
    • Added documentation for task filters. +
    +

    New in version 1.4.2 (9/18/2008)

    • "task undo" can now retract a "task done" command, provided no reports have been run. @@ -358,17 +211,7 @@ order to build clean using gcc 4.3 (thanks to H. İbrahim Güngör)
    -

    -

    New in version 1.4.1 (7/18/2008)

    - task-1.4.1.tar.gz -
    - Mac OS X 10.5 (Leopard) Intel-only: - task-1.4.1.pkg -
    - Debian package: task_1.4.1-1_i386.deb - (Thanks to Richard Querin) -

    - +

    New in version 1.4.1 (7/18/2008)

    • Fixed bug: Descriptions could not be altered with "task 123 New description"
    • Tweak: For "task calendar" month names are now centered over the month @@ -376,14 +219,7 @@
    • New Mac Intel-only Leopard (10.5) binary package
    -

    -

    New in version 1.4.0 (7/10/2008)

    - Source: task-1.4.0.tar.gz -
    - Debian package: task_1.4.0-1_i386.deb - (Thanks to Richard Querin) -

    - +

    New in version 1.4.0 (7/10/2008)

    • Added new recurring tasks feature
    • Added "task undelete" feature to restore a (very) recently deleted @@ -405,14 +241,7 @@
    • Fixed bug parsing date "07/08/2008" when using dateformat "m/d/Y"
    -

    -

    New in version 1.3.1

    - Source: task-1.3.1.tar.gz -
    - Debian package: task_1.3.1-1_i386.deb - (Thanks to Richard Querin) -

    - +

    New in version 1.3.1

    • New configuration variable "defaultwidth" determines the width of windows in the absense of ncurses support @@ -424,14 +253,7 @@ OR a missing ~/.task directory
    -

    -

    New in version 1.3.0

    - Source: task-1.3.0.tar.gz -
    - Debian package: task_1.3.0-0_i386.deb - (Thanks to Richard Querin) -

    - +

    New in version 1.3.0

    • "task calendar" now displays multiple months per line, adjustable by the "monthsperline" configuration variable. Feature added by @@ -448,14 +270,7 @@
    • Fixed bug whereby "1 wks" was being improperly pluralized
    -

    -

    New in version 1.2.0

    - Source: task-1.2.0.tar.gz -
    - Debian package: task_1.2.0-1_i386.deb - (Thanks to Richard Querin) -

    - +

    New in version 1.2.0

    • Subprojects supported - please see documentation below, or TUTORIAL file @@ -468,14 +283,7 @@
    • Improvements to the TUTORIAL file and this page
    -

    -

    New in version 1.1.0

    - Source: task-1.1.0.tar.gz -
    - Debian package: task_1.1.0-1_i386.deb - (Thanks to Richard Querin) -

    - +

    New in version 1.1.0

    • "blanklines" configuration variable to stop displaying unnecessary white space and thus work better on small-screen devices @@ -485,24 +293,14 @@
    • Added tags to the "task long" report
    -

    -

    New in version 1.0.1

    - Source: task-1.0.1.tar.gz -

    - +

    New in version 1.0.1

    • Fixed bug where the UUID generator not properly terminating strings
    • Fixed bug where srandom/srand not called prior to custom UUID generation
    -

    -

    Version 1.0.0

    - Source: task-1.0.0.tar.gz -

    - -

    - Task 1.0.0 was the first publicly available version of task. -

    +

    Version 1.0.0

    + Task 1.0.0 was the first publicly available version of task.
    From cce755e5da94800fd9dac044acb5e630f423e7bb Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Wed, 20 May 2009 20:46:45 -0400 Subject: [PATCH 029/417] Documentation Update - clarification - Added note about the lack of a need to escape shell metacharacters when they are used in a custom report filter (thanks to Bruce Dillahunty). - Corrected wrong header tag. --- html/shell.html | 11 +++++++---- html/task.html | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/html/shell.html b/html/shell.html index 2545e5650..f52ffb118 100644 --- a/html/shell.html +++ b/html/shell.html @@ -69,10 +69,13 @@
    % task add "Buy bread & milk"

    - Task itself interprets the commands, and it too can make mistakes. - For example, any colon : character will be interpreted by task as a - delimiter between an attribute name and its value. Currently there - is no workaround for this. + Note that if an & character (or any other character that needs + to be escaped for the shell) appears in the + filter of a + custom report + then it does not need to be escaped, as it never gets processed + by the shell. In other words, shell escapes need only be used + when typing task commands at a prompt.

    diff --git a/html/task.html b/html/task.html index bb375ebf7..9daa3d759 100644 --- a/html/task.html +++ b/html/task.html @@ -142,7 +142,7 @@ -

    New in version 1.8.0 (?)

    +

    New in version 1.8.0 (?)