Commit graph

3113 commits

Author SHA1 Message Date
Paul Beckingham
d230ea4001 Diagnostics
- The 'diagnostics' command now checks for duplicate UUID values in the data.
2012-02-28 01:22:57 -05:00
Paul Beckingham
50825bc61a Bug #851
- Fixed bug #851, which failed to recognize durations like '1day' when
  filtering date attributes (thanks to Philipp Woelfel).
- Added unit tests.
2012-02-28 00:27:48 -05:00
Paul Beckingham
9eee2e3e3e Bug #447
- Indicated that #447 was fixed alongside #942.
2012-02-27 20:18:11 -05:00
Paul Beckingham
8c0971425f Bug #942
- Fixed bug #942, which only allowed dates to be edited if they changed day
  (thanks to Owen Clarke).
2012-02-27 20:10:19 -05:00
Paul Beckingham
e42a5a831a Bug #865, #886
- Fixed bugs #865 and #886, which caused silent failure of unrecognized dates
  (thanks to Michelle Crane).
2012-02-27 00:36:53 -05:00
Paul Beckingham
5feb736939 Bug
- Fixed problem where urgency was not properly calculated for waiting tasks.
- Tweaked urgency coefficients to make most of the values closer together, and
  therefore more sensitive.
- Inverted 'waiting' coefficient.
- Boosted 'next', 'due' and 'blocking' coefficients.
- Modified unit tests accordingly.
- Lessened the impact of 'blocked', 'project', 'tags' and 'age'.
2012-02-26 23:13:15 -05:00
Owen Clarke
9fb015f72c Portability
- Added new 'format' overload to resolve compiler warnings on Solaris.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-26 18:49:13 -05:00
Paul Beckingham
0fe5887af8 Unit Tests
- Change #819 test to pass, because the bug is deferred.
- Change #884 test to pass, because the bug is deferred.
- Added Najmi Ahmad Zabidi to AUTHORS file, for suggesting a specific
  verbosity control.
- Added some stealth unit tests.
2012-02-26 17:56:15 -05:00
Paul Beckingham
8af872e289 Bug
- Fixed problem where update-holidays.pl did not use the YYYYMMDD date foramt.
2012-02-26 17:05:16 -05:00
Paul Beckingham
824cba7152 Bugs #552, #863
- Fixed bug #552, where 'rc.verbose=off' suppressed warnings (thanks to Peter
  De Poorter).
- Fixed bug #863, which suppressed report labels with rc.verbose=off (thanks to
  Michelle Crane).
2012-02-26 17:01:13 -05:00
Paul Beckingham
45dba8805c Documentation
- Added deprecated configuration file values.
2012-02-26 15:06:55 -05:00
Paul Beckingham
5b3cba2e70 Unit Tests
- Enabled more recurring task tests.
2012-02-26 14:57:21 -05:00
Paul Beckingham
bcf416e71f Unit Tests
- Added tests for #884.
2012-02-26 14:38:48 -05:00
Paul Beckingham
ceabcdd6c3 Unit Tests
- Reduced complexity in the test.
2012-02-26 14:37:01 -05:00
Paul Beckingham
5396c718ef Unit Tests
- Added test to illustrate the workaround.
2012-02-26 14:02:40 -05:00
Paul Beckingham
1f5146e7a0 Unit Tests
- Corrected test count and removed diag output.
2012-02-26 13:39:55 -05:00
Paul Beckingham
9d74b55d48 Feature #725
- Added feature #725, which provides feedback when tasks become unblocked.
- Added unit tests.
2012-02-26 13:08:40 -05:00
Paul Beckingham
56f0281ab1 Git
- Added doc/misc/tutorial to .gitignore to get it out of my face.
2012-02-26 12:35:43 -05:00
Paul Beckingham
3133616b67 Unit tests
- Enabled some disabled regex filter tests.
2012-02-26 10:57:59 -05:00
Owen Clarke
7c2d97d939 Unit Tests
- Fixed 'witching hour' bug in unit tests that causes problems when run
  in assorted time zones.  By using str2time to get the epoch value of
  a known local time, this should fix failures that occur.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-25 23:13:41 -05:00
Owen Clarke
049f34d339 Portability
- Improved run_all script to run on Solaris.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-25 23:10:11 -05:00
Paul Beckingham
a9de8a6596 Verbosity
- Tweak to 'affected' token.  Needs more.
2012-02-24 18:27:39 -05:00
Paul Beckingham
e0aabe08bf Unit Tests
- Fixed broken DOM tests.
2012-02-24 18:26:35 -05:00
Paul Beckingham
a495b05d6b Bug #938
- Made alternate fix to CmdUrgency.cpp, to avoid the ambiguity around
  the format() signatures (thanks to Owen Clarke).
2012-02-23 20:48:01 -05:00
Owen Clarke
87853bdd78 Bug #938
- Fixed compiler warnings on Solaris.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-23 20:43:54 -05:00
Owen Clarke
25a1b89156 Bug #938
- Fixed incorrect return type.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-23 20:33:05 -05:00
Paul Beckingham
9c641fd778 Credit
- Updated ChangeLog to reflect recent patches.
2012-02-23 20:27:38 -05:00
Owen Clarke
3ba0b62783 Bug #937
- Fixed problem with incomplete 'stat' path.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-23 20:23:05 -05:00
Owen Clarke
8e5afa0d8a Bug #936
- Fixed failing tests on Solaris.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-23 20:16:39 -05:00
Owen Clarke
ed6bdd7bdc Bug #936
- Fixed failing tests on Solaris.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-23 20:13:44 -05:00
Owen Clarke
3b9a737ac4 Bug #936
- Fixed failing tests on Solaris.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-23 19:58:42 -05:00
Paul Beckingham
15a0d7a801 Bug #880
- Fixed bug #880, which listed the wrong file paths for themes (thanks to Peter
  Lewis).
2012-02-23 17:26:52 -05:00
Federico Hernandez
8521e6d1e7 New try for RC1 2012-02-22 01:39:45 +01:00
Paul Beckingham
21e006319a Beta5
- Set version back to beta5 for a quick patch.
2012-02-21 19:30:33 -05:00
Paul Beckingham
33e2a1b52c Merge branch '2.0.0' of tasktools.org:task into 2.0.0 2012-02-21 19:29:11 -05:00
Paul Beckingham
1a7ed9e137 Debugging
- Inadvertently left in a debug statement.
2012-02-21 19:26:17 -05:00
Federico Hernandez
efa1914be5 Bumped version number to RC1 2012-02-22 01:09:49 +01:00
Paul Beckingham
1f8e823593 Holidays Updated
- Modified update-holidays.pl script to include the MIT license.
- Added the URLs used to download the data, in the data.
- Added a refresh script to freshen the files.
2012-02-21 17:23:57 -05:00
Paul Beckingham
b17be021db Credit
- Added Luke Macken to the AUTHORS file.  Forgot to include it in the
  previous patch.
2012-02-20 17:37:38 -05:00
Luke Macken
1358a8302f Portability
Manually include unistd.h in a couple of places get things building with gcc
4.7, which removed it from the global namespace. This fixes the following build
errors:

    src/A3.cpp:283:3: error: 'STDIN_FILENO' was not declared in this scope
    src/commands/CmdEdit.cpp:598:30: error: 'getpid' was not declared in this scope
    src/commands/CmdEdit.cpp:603:47: error: 'chdir' was not declared in this scope

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-20 17:31:30 -05:00
Paul Beckingham
39998d5cc5 Bug #932
- Fixed bug #932, which fixed change propagation for recurring tasks (thanks to
  Jennifer Cormier).
- Added unit tests, corrected some.
2012-02-20 17:25:31 -05:00
Paul Beckingham
259f39f2d2 Performance
- Corrected performance measurement.  The TDB2::gc requires data to
  be loaded first, but load time is measured separately.  This resulted
  in repeat counting.  Now the gc time subtracts any load time that is
  accumulated *during* the gc.  This is now a fair accounting of the time.
2012-02-20 09:26:52 -05:00
Paul Beckingham
d386081c4c Bug
- Modified format 'uuid.short' to show the leftmost 8 characters from
  a UUID, which is the same as partial UUID matching implemented in
  #891.
2012-02-20 01:23:34 -05:00
Paul Beckingham
9f8165e3c6 Bug #932 (part 1)
- Fixed bug that caused only parent recurring tasks to have their attributes
  properly removed.
- When duplicating a parent recurring task, a new recurring parent task is
  created.  When a child recurring task is duplicated, a plain task is created.
- Added unit tests.
- Thanks to Jennifer Cormier.
2012-02-20 01:10:42 -05:00
Paul Beckingham
0a0e8f0d6b Bug - UTF8
- Fixed bug in the handling of UTF8 JSON data from holidata.net, when
  update-holidays.pl when decoding and writing files.
2012-02-19 23:22:45 -05:00
Paul Beckingham
7a45db4d0f Feature #891
- Added feature #891, which allows for leftmost partial matches of UUID values.
  Makes direct comparisons for full-length values, and regular expressions for
  partial values.  Note that there is a minimum length of 8 hex digits.
- Added safety parsing mechanism that fails a partial UUID if immediately
  followed by a hex digit.  This allows for numbers longer than 8 digits to not
  be misinterpreted as a UUID.
- Implemented Nibbler::getPartialUUID.
- Implemented unit tests.
@@ -1145,12 +1145,23 @@ const A3 A3::sequence (const A3& input) const

   for (unsigned int i = 0; i < uuids.size (); ++i)
   {
-    if (ids.size ())
+    if (ids.size () + i > 0)
       sequenced.push_back (Arg ("or", Arg::cat_op));

-    sequenced.push_back (Arg ("uuid",        Arg::type_string, Arg::cat_dom));
-    sequenced.push_back (Arg ("=",                             Arg::cat_op));
-    sequenced.push_back (Arg (uuids[i],      Arg::type_string, Arg::cat_literal));
+    // A full-length UUID requires a string comparison.
+    if (uuids[i].length () == 36)
+    {
+      sequenced.push_back (Arg ("uuid",         Arg::type_string, Arg::cat_dom));
+      sequenced.push_back (Arg ("=",                              Arg::cat_op));
+      sequenced.push_back (Arg (uuids[i],       Arg::type_string, Arg::cat_literal));
+    }
+    // A UUID fragment is a leftmost comparison.
+    else
+    {
+      sequenced.push_back (Arg ("uuid",         Arg::type_string, Arg::cat_dom));
+      sequenced.push_back (Arg ("~",                              Arg::cat_op));
+      sequenced.push_back (Arg ("^" + uuids[i], Arg::type_string, Arg::cat_rx));
+    }
   }

   sequenced.push_back (Arg (")", Arg::cat_op));
@@ -1674,11 +1685,11 @@ bool A3::is_uuid (Nibbler& n, std::string& result)
   n.save ();
   result = "";
   std::string uuid;
-  if (n.getUUID (uuid))
+  if (n.getPartialUUID (uuid))
   {
     result += uuid;
     while (n.skip (',') &&
-           n.getUUID (uuid))
+           n.getPartialUUID (uuid))
     {
       result += ',' + uuid;
     }
@@ -1997,13 +2008,13 @@ bool A3::extract_uuid (
   Nibbler n (input);

   std::string uuid;
-  if (n.getUUID (uuid))
+  if (n.getPartialUUID (uuid))
   {
     sequence.push_back (uuid);

     while (n.skip (','))
     {
-      if (!n.getUUID (uuid))
+      if (!n.getPartialUUID (uuid))
         throw std::string (STRING_A3_UUID_AFTER_COMMA);

       sequence.push_back (uuid);
2012-02-19 22:27:40 -05:00
Paul Beckingham
c785836083 Feature #632
- Added feature #632, which allows environment variables TASKRC and TASKDATA
  to override .taskrc and .task directory locations (thanks to Steve Rader).
- Added unit tests.
+
2012-02-19 18:59:28 -05:00
Paul Beckingham
09431caf1c Bug
- Tag matching was being performed using the regex \b<tag>\b, which makes
  taskwarrior dependent on regex lib bugs for basic functionality.  This is
  now modified to use pseudo-operators _hastag_ and _notag_.
2012-02-19 17:20:11 -05:00
Michal Vyskocil
78e5891cd3 Portability
- lua_open has been declared as deprecated in lua 5.1 and removed from
  5.2. Usage of luaL_newstate is thus recommended in both series.

Signed-off-by: Paul Beckingham <paul@beckingham.net>
2012-02-15 19:26:26 -05:00
Paul Beckingham
26cc4e11f5 Unit Tests
- Improved verbosity unit tests.
2012-02-13 06:16:18 -05:00