Compare commits

...

1015 Commits

Author SHA1 Message Date
Tomas Babej
7400e6ed6b README: Update version reference 2022-03-16 01:52:27 -04:00
Tomas Babej
93394e7054 meta: Update CMake version reference for 2.6.2 2022-03-16 01:52:16 -04:00
Tomas Babej
f030154ef6 docs: Document #2689 2022-03-16 01:39:02 -04:00
Tomas Babej
10a2225aae docs: Document #2707 2022-03-16 01:34:42 -04:00
Tomas Babej
de793e5902 docs: Document #2748 2022-03-14 02:48:13 -04:00
Tomas Babej
1fc1884017 Context: Add parent column among default ones for the recurring report
This helps to identify parent-child relationships.
2022-03-14 02:48:13 -04:00
Tomas Babej
75ce386b44 Context: Adjust definition of the recurring report filter
Ensure the recurring report lists the recurring parent tasks as well as
the child tasks.
2022-03-14 02:48:13 -04:00
Tomas Babej
e60fdafdaa centos8: Fix missing repo metadata 2022-02-11 00:40:31 -05:00
Jan Palus
d541e0da65 TLSClient: fix multiple issues with error handling
- do not check errno on successful function calls (it might not be
  cleared after previous failed one)
- GNUTLS_E_* are not passed through errno but as function return value
- therefore there's more error spectrum than -1
- do not assume whole header is received, check number of bytes fetched

small additional improvements:
- read as many bytes into buffer as possible before appending to data
- skip writing nul byte at the end of buffer and use append() instead
- additional sanity checks
2022-02-11 00:19:04 -05:00
Patrick Flakus
59a1729a05 Cleanup: Fixed typo in docstring 2022-01-27 16:10:47 -05:00
Tomas Babej
112ac54a57 ColDepends: Support dependency removal for the same formats as dependency addition 2022-01-19 20:11:41 -05:00
Tomas Babej
0cc2de6179 tests: Add a test for handling short UUIDs in the depends column 2022-01-19 20:11:41 -05:00
Dustin J. Mitchell
28e268bd26 fix parsing invalid depends from server
The data from the server is read via Task::parseJSON, not Task::parse.

This also reverts the tests for Task::parse, and adds new tests for this
specific issue.
2022-01-19 19:34:45 -05:00
Dustin J. Mitchell
7321febe4f A more thorough fix to corruption of the depends property 2022-01-19 19:34:45 -05:00
Dustin J. Mitchell
96d6c1df9f Add special case for taskserver mis-formatting of depends 2022-01-16 15:36:21 -05:00
Tomas Babej
cb058f2e4b tests: Remove Ubuntu 20.10 (now beyond EOL) from the test matrix 2022-01-05 21:01:21 -05:00
Dustin J. Mitchell
c564bbc0b7 fix test to pass at the end of the year 2021-12-30 15:03:37 -05:00
Dustin J. Mitchell
b066a17ebe use a reference in CurrentTask 2021-12-30 15:03:37 -05:00
Dustin J. Mitchell
277ce0e226 Update doc comment in src/Context.h
Co-authored-by: Tomas Babej <tomas@tbabej.com>
2021-12-30 15:03:37 -05:00
Dustin J. Mitchell
65830dd705 replace the global contextTask with a Context field 2021-12-30 15:03:37 -05:00
Dustin J. Mitchell
53127bf844 add Context::withCurrentTask 2021-12-30 15:03:37 -05:00
Dustin J. Mitchell
2ea6dd627e Just set contextTask in Task::modify
Based on the observation that every command was setting contextTask
immediately before calling `task.modify(..)`.
2021-12-30 15:03:37 -05:00
Dustin J. Mitchell
db26a28bf9 move domSource to Eval, as it's an Eval source 2021-12-30 15:03:37 -05:00
Dustin J. Mitchell
6e9ad1048d move use of contextTask out of columns, into commands 2021-12-30 15:03:37 -05:00
Dustin J. Mitchell
e98b61f2b5 test for dashes in proj without incidentally testing DOM references in 'task add' 2021-12-30 15:03:37 -05:00
Dustin J. Mitchell
4fa1c0bcfb remove temporary function 2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
e3dd91d45e use the existing (but misnamed) orphans method 2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
e768e2c100 compare Tasks directly, not their properties 2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
ac24ec1387 fixup and fix spelling for denotate 2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
3a61289f6c replace a use of Task::data in tests 2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
9f149a7f35 use Task::getAnnotations to get annotatoins 2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
70f83b34ef Move diff formatting into Task (simple refactor)
The Task class already included two forms of diff. This adds another
two.
2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
8d3953183a Only set contextTask if not adding a new task
When adding a new task, the current task is empty, so there is no
context in which to evaluate DOM references.  #2683 will address this in
a more robust fashion.
2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
2812a8c77a Refactor getDOM to use a pointer for the optional context
It's possible to call getDOM without a contextual task.  Previously,
this was done by referencing a "dummy" task which necessitated a way to
distinguish such dummy tasks.  This switches to using a pointer and
treating the NULL value as meaning there is no context.

Note that this cannot use `std::optional<&Task>`, as optional does not
support reference types.
2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
3af5ceadc1 Return early from getDOM if there is no contextual task (refactor)
Before this change, all conditionals checked `have_ref`; returning early
is clearer.
2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
0d9e402d3e Add Task.is_empty, needed to identify "dummy" tasks (simple refactor)
getDOM takes an &Task that may be a reference to a dummy, or may be a
real task.  The is_empty method replaces `task.data.size() == 0` as a
way to distinguish the two.
2021-12-16 23:03:44 -05:00
Dustin J. Mitchell
dede40bc4e Replace direct Task.data access with a temp getter (syntactic refactor)
Now this getter, `data_removeme`, can easily be grepped out and
replaced, one usage at a time in small PRs.
2021-12-16 23:03:44 -05:00
Tomas Babej
3a00956144 ColDepends: Allow specifying short(er) UUIDs 2021-12-03 03:57:37 -05:00
Siôn le Roux
01add8a34a docs: Fix typo in XDG news
This had XFG written in it, it's surely a typo of XDG since on the next
line it's written correctly.
2021-11-23 21:05:01 +01:00
Tomas Babej
a09712d5d2 docs: Document #2655 2021-11-22 15:51:27 +01:00
Tomas Babej
8074e509ba tests: Add bulk removal test for tags attribute 2021-11-22 15:51:27 +01:00
Tomas Babej
af10774aec tests: Add bulk removal test for depends attribute 2021-11-22 15:51:27 +01:00
Tomas Babej
d54c7e090e Task: Correctly handle bulk removal of virtual tags/depends attributes
This edge case would happen if a user issued a following command

    $ task 1 mod depends:
or

    $ task 1 mod tags:

which would not perform as expected for tasks with non-empty depends /
tags attributes.

The problem under the hood is the fact that current synchronization
between 'tags" attribute and its constituent decomposed `tag_X`
attributes is performed in a way where the set of tags obtained from
`tag_X` attributes is taken as the source of truth.

If the legacy 'tags:' attribute was set to empty, the fixTags() method
would then restore its previous value from the `tag_X` attributes,
effectively leading to a no-op.

The same happens with dependencies. The fix here is to detect removal of
depends and tags attributes, and instead of setting the legacy
attributes to empty values, we iteratively remove all tags/dependencies.

Closes #2655.
2021-11-22 15:51:27 +01:00
Dustin J. Mitchell
3937f1efb0 Don't look for a specific sha when testing task version
This allows tests to pass even with a dirty working copy or when running
tests via `git rebase`.
2021-11-21 23:34:46 +01:00
Tomas Babej
3e8190831c docs: Document #502 2021-11-20 15:19:34 -05:00
Tomas Babej
3c2b74a36f tests: Remove expected failure for ID-range based dependencies 2021-11-20 15:19:34 -05:00
Tomas Babej
0558b6c7aa ColDepends: Recognize and properly handle ID ranges 2021-11-20 15:19:34 -05:00
Tomas Babej
774f6df210 docs: Document #2671 2021-11-09 08:00:05 -05:00
Tomas Babej
1e1c0e8f04 libshared: Bump to include fix for soww
See https://github.com/GothenburgBitFactory/libshared/pull/66 for
reference. Closes #2671.
2021-11-09 07:57:37 -05:00
Tomas Babej
caf0f9db3e tests: Clarify we're testing OpenSUSE 15.x rolling 2021-11-06 13:08:51 -04:00
Tomas Babej
da43078eba tests: Add Ubuntu 21.10 into the test matrix 2021-11-06 12:59:16 -04:00
Tomas Babej
6fae705b43 tests: Add Ubuntu 20.10 into the test matrix 2021-11-06 12:57:26 -04:00
Tomas Babej
e4f1e05c1d tests: Add Fedora 35 into the test matrix 2021-11-06 12:54:46 -04:00
Tomas Babej
4559287d07 tests: Remove tests on F31
This distribution release is more than a year out of its support window.
2021-11-06 12:52:24 -04:00
Tomas Babej
2d4776586d README: Remove inacurrate badge
The commit count has been inacurrate for some time, undercounting
(perhaps due to aggreessive caching), but also overcounting at times
(due to merges).
2021-11-06 12:39:22 -04:00
Tomas Babej
ed4b932530 tests: Add test to cover invalid contexts due to tag exclusion 2021-11-06 11:58:47 -04:00
Tomas Babej
f0f704fc99 tests: Fix copy-paste error
The context name in these two tests was invalid in some assertions.
2021-11-06 11:58:46 -04:00
Tomas Babej
403c44b1fa docs: Document #2664 2021-11-06 11:58:45 -04:00
Tomas Babej
493f36ecdd CmdContext: Utilize new reason-providing validateWriteContext 2021-11-06 11:53:45 -04:00
Tomas Babej
5d8f8dac35 validateWriteContext: Refactor to return the underlying reason for invalidity directly 2021-11-06 11:53:44 -04:00
Tomas Babej
f5dce013ce CmdContext: Expand the definition of an invalid write context to incllude tag exclusion 2021-11-06 11:53:44 -04:00
Tomas Babej
531881f651 validateWriteContext: Tag exclusion should also be detected as invalid write context 2021-11-06 11:53:43 -04:00
Tomas Babej
7de681aa3b validateWriteContext: Apply early break when detected the OR operator 2021-11-06 11:53:42 -04:00
Jakub Wilk
04ef785eea Fix typo 2021-11-06 11:50:02 -04:00
Tomas Babej
e1cfb91d42 docs: Document #2648 2021-11-06 11:28:05 -04:00
Tomas Babej
72930708ec CmdNews: Support Mac OS-X url opener 2021-11-04 22:07:39 -04:00
Tomas Babej
58763fd49f reproduce: Make vim available in the reproduction image 2021-10-30 06:12:48 -04:00
Steven Kreuzer
a89c875c49 Fix typo in ChangeLog
Change 'precendence' to 'precedence'
2021-10-22 18:54:32 -04:00
Tomas Babej
e0f598f91c Changelog: Document 2.6.1 release commit hash 2021-10-19 00:30:53 -04:00
Tomas Babej
a696b6b155 cmake: Bump project version to 2.6.1 2021-10-19 00:23:40 -04:00
Tomas Babej
d8770133f0 docs: Update dev branch references in README 2021-10-19 00:23:16 -04:00
Tomas Babej
5c32372d42 docs: Update DEVELOPER.md 2021-10-19 00:20:07 -04:00
Tomas Babej
4d7c7531d0 docs: Document #2632 2021-10-18 23:56:38 -04:00
Tomas Babej
c99dab0dae meta: Ensure Cygwin compatibility 2021-10-18 23:53:26 -04:00
Tomas Babej
3dee86c997 docs: Document #2639 2021-10-18 23:48:37 -04:00
Tomas Babej
df75d1ce43 test: Add tests for parsing ID ranges of various sizes 2021-10-18 23:46:45 -04:00
Tomas Babej
2469943c98 meta: Bump libshared
This bumps libshared version to the one not suffering from
misidentification of certain ID ranges.

Closes #2639.
2021-10-18 23:15:03 -04:00
Tomas Babej
072b38d326 CmdCustom: Increase probability of displaying upgrade message
We have received reports from people that have upgraded, but seemingly
have not seen release notes in the `task news` command. One of the
causes here could be the fact that the probability of displaying the
footnote about running `task news` is `1/10`.

Increase the probability to 1/4.
2021-10-18 21:32:53 -04:00
Tomas Babej
dc81bf5fb5 CmdNews: Adjust for brevity 2021-10-18 21:31:41 -04:00
Tomas Babej
8e7401d2f4 docs: Document #2626 2021-10-16 11:28:36 -04:00
Tomas Babej
6a79e614da tests: Expand test for waiting report
Add tasks to test exclusion of completed and deleted tasks.
2021-10-16 11:11:45 -04:00
Tomas Babej
4287b33796 Task: Only consider pending tasks as waiting 2021-10-16 11:11:15 -04:00
Tomas Babej
3b37dc2480 tests: Adjust test description 2021-10-16 11:02:38 -04:00
Tomas Babej
dec99b0deb docs: Document #2622 2021-10-16 10:22:34 -04:00
Tomas Babej
3840c4e768 tests: Add test for UDA Orphan identification 2021-10-16 10:22:34 -04:00
Tomas Babej
793b23411a CmdUDAs: Do not identify tags and dependencies as orphan UDAs 2021-10-16 10:22:34 -04:00
Tomas Babej
fd549c764b Task: Do not identify tag and dependency attributes as orphans 2021-10-16 10:22:34 -04:00
Tomas Babej
339a4ddb51 Task: Make isTag/Dep/AnnotationAttr methods static
This allows usage of these helper methods outside of Task class.
2021-10-16 10:22:34 -04:00
Bent Witthold
3dbad09f72 consiered -> considered 2021-10-16 09:07:18 -04:00
Tomas Babej
d480f6a0db docs: Document #2629 2021-10-15 01:09:19 -04:00
Tomas Babej
e21ae0d7d8 docs: Document #2620 2021-10-15 00:56:13 -04:00
Tomas Babej
f6d9837b07 tests: Add test for legacy context interpretation 2021-10-14 22:36:11 -04:00
Tomas Babej
d5a026d91a context: Interpret legacy-style context as read context only
This provides a better migration path than surprising users with the
write context functionality out of the blue.

Closes #2620.
2021-10-14 22:34:48 -04:00
Tomas Babej
1d4baca0d9 context: Do not interpret empty filter/mods as missing context definition
This is a corner case bug, when user has both old-style and new-style
context defined, where new-style is defined as empty string, the
old-style will (incorrectly) take precedence.

Closes #2629.
2021-10-14 17:47:11 -04:00
Tomas Babej
887b04f7f4 docs: Document #2619 2021-10-11 15:50:42 -04:00
Alexandre Provencio
d4a9ce614b Fix fish completions
Closes #2619
2021-10-11 15:45:57 -04:00
Orhun Parmaksız
db76a15ba5 changelog: mark 2.6.0 as current release 2021-10-04 21:07:44 -04:00
Tomas Babej
64ea936d7f README: Describe the new branch names 2021-10-04 20:56:27 -04:00
Tomas Babej
c010855bac Merge branch '2.6.0' 2021-10-02 22:04:54 -04:00
Tomas Babej
2f47226f91 cmake: Prevent nested tarballs (or other archives) in the release
This happened dring the release of the version 2.5.2.
2021-01-04 00:20:08 -05:00
Tomas Babej
d26f79a458 docs: Update copyright 2021-01-03 22:58:02 -05:00
Tomas Babej
ce6ff451b0 cmake: Update list of ignored source files 2021-01-03 22:52:50 -05:00
Tomas Babej
5466f19441 README: Update build status badge prior to the release 2021-01-03 22:52:02 -05:00
Tomas Babej
0db0ab1b3c ci: Pass CONTAINER variable to the test execution step 2021-01-03 22:48:56 -05:00
Tomas Babej
fd34737330 ci: Remove rednudant declaration of runs-on 2021-01-03 22:48:44 -05:00
Tomas Babej
f48f89fbd9 ci: Remove integration with Travis 2021-01-03 22:48:37 -05:00
Tomas Babej
7de0a3afa4 ci: Add Github-workflow based CI pipeline 2021-01-03 22:47:08 -05:00
Tomas Babej
c5aba94233 NEWS: Update tested configurations 2021-01-03 22:35:21 -05:00
Tomas Babej
b7500776fe docs: Document TW #2375 2021-01-03 22:34:54 -05:00
Tomas Babej
d29ddec34f NEWS: Fix URL for issue submission 2020-12-08 00:44:33 -05:00
Tomas Babej
83f71520d2 tests: Make faketime tests less susceptible to race conditions
The duration can be 10:01 if the original task call happened a split
second before the faketime fixation of +10 minutes.

Use more relaxed regular expresison to check.
2020-12-06 12:00:38 -05:00
Tomas Babej
ee15bfa1db tests: Skip the diagnostics test on Ubuntu 16.04
This is a byproduct of recent bump to C++17 compliant compilers. Ubuntu
16.04 does not have C++17 compliant compiler, but it's still useful to
for us to test 2.5.3 there as the branch does not actually use any of
the C++17 features not available on gcc on Ubuntu.
2020-12-06 11:48:41 -05:00
Tomas Babej
f2abee3606 travis: Preserve Ubuntu 16.04 2020-12-06 10:11:03 -05:00
Tomas Babej
c6ec416e30 ci: Rename Arch container to make it clear we're testing on rolling base 2020-12-06 10:09:53 -05:00
Tomas Babej
9a193e26ec ci: Add support for CentOS 8 2020-12-06 10:09:46 -05:00
Tomas Babej
2657880ff3 ci: Replace F28 and F29 with F31, F32 and F33 2020-12-06 10:09:39 -05:00
Tomas Babej
497262d23c ci: Add Ubuntu 20.04 2020-12-06 10:09:31 -05:00
Tomas Babej
1b745bc505 ci: Properly setup en_US.UTF-8 locale for Ubuntu containers 2020-12-06 10:09:20 -05:00
Max Rossmannek
2620714b43 Fix Arch docker image 2020-12-06 10:01:54 -05:00
Max Rossmannek
4ebf611b91 Fix faketime packages 2020-12-06 10:01:45 -05:00
Max Rossmannek
862ae0b969 Replace libfaketime with faketime in debianstable
I verified locally that this avoids skipping all of the
faketime-dependent unittests. The Travis CI logs will have to be
investigated for all of the other docker images on which distros we may
need to apply a similar fix.
2020-12-06 10:01:30 -05:00
Max Rossmannek
b634dea7ab Attempt greedy docker config update
This is an attempt at updating all docker configurations by simply
replacing the `python` packages with `python3`. The Travis CI will let
us know if this works.
2020-12-06 10:01:19 -05:00
Max Rossmannek
2931be613b Enforce Python 3 in test_hooks/wrapper
This change was not included in the previous commit because the sed
command I used included the `/usr/bin/env` path to ensure I don't
replace any occurences of the word `python` which I did not wish to
replace.
2020-12-06 10:01:09 -05:00
Max Rossmannek
6d2ecaa15c Enforce Python 3 for unittests
This commit updates all tests to enforce the Python3 executable. This is
necessary because the `assertRegex` function we use was renamed to this
name only in Python 3.2 [1]

For reference:
s;/usr/bin/env python;/usr/bin/env python3;g

[1]: https://docs.python.org/3/library/unittest.html#unittest.TestCase.assertRegex
2020-12-06 10:00:59 -05:00
Tomas Babej
a8c215774b tests: Implement mechanism for expected failures in C++ tests
Implements detection of unexpected successes and expected failures. Both
classes are represented in the TAP output as 'not ok', unexpected
successes with '# FIXED' metadata and expected failures as '# TODO'.

This brings C++ tests to feature parity with Python-based ones when it
comes to expected failures and unexpected successes.
2020-12-06 09:56:37 -05:00
Max Rossmannek
0ae2f2a5fd Revert "Poor implementation of linewrap restored to task"
This reverts commit 64243e6ec1.
2020-12-06 09:45:30 -05:00
Tomas Babej
9f5a38df60 NEWS: Remove 2.5.2 content, put placeholders for 2.5.3 2020-12-05 18:19:24 -05:00
Tomas Babej
5e30a65689 CMake: Bump version number to 2.5.3 2020-12-05 18:16:58 -05:00
Tomas Babej
c1de01d594 ChangeLog: Update the current release 2020-12-05 17:48:45 -05:00
Tomas Babej
2dd21de678 Merge branch '2.5.2' into master 2020-12-05 17:46:20 -05:00
Tomas Babej
b0c17d1163 holidays: Update holidays using newest holidata.net data
Remove outdated holiday files that could not be updated.
2020-12-05 17:11:36 -05:00
Tomas Babej
36d13508d4 CMake: Also ignore .travis for the tarball build 2020-12-05 16:59:14 -05:00
Tomas Babej
fdc290c546 CMake: Exclude .github directory 2020-12-05 16:51:54 -05:00
Tomas Babej
cd1d42bc9d tests: Mark failing corner case tests as expected for 2.5.2 2020-12-05 16:40:28 -05:00
Leo
643166a337 Uncoditionally include errno.h instead of guessing
POSIX tells us that it is errno.h, musl fails to build with -Werror
because it redirects sys/errno.h->errno.h and uses #warning

(cherry picked from commit 041248e7cc)
2020-11-30 00:53:20 -05:00
John Nguyen
4c714e10a3 Fix typo in man page
The example for _unique has typo, should be using attribute for project.
Fixes #2277

(cherry picked from commit cf45f28cc0)
2020-11-30 00:53:20 -05:00
Tomas Janousek
b6910b9428 Add missing "QUARTER" to feedback_reserved_tags
A while ago I noticed that 630a1530e0 only
added the QUARTER virtual tag to src/Task.cpp, and when I checked that
again today, it was still missing from src/feedback.cpp, so I'm fixing
that.
2020-11-24 18:46:53 -05:00
mrossinek
4f14b8923f Fix variant_subtract test case after PR #2095 2020-11-24 08:12:39 -05:00
Tomas Babej
1417be626f TW-1511: Interpret string subtraction as concanetation with a dash
Fixes #1537 (previously known as TW-1511).
2020-11-24 08:12:39 -05:00
Max Rossmannek
cad9a4f834 Update diag.t to correct C++ version
The default C++ version was updated in 4729876 and this commit reflects
this change in the test.
2020-11-24 08:12:39 -05:00
mrossinek
ca1e2a5a6b Mark project.t 1455 as expected failure 2020-11-24 08:12:39 -05:00
Tomas Babej
79e076c3c0 tests: Use updated unittest method 2020-11-24 08:12:39 -05:00
mrossinek
7d567c3ac9 Fix wait.t to correct expected output 2020-11-24 08:12:39 -05:00
Tomas Babej
351965a87b Update copyright to 2020 2020-11-21 12:43:40 -05:00
Tomas Babej
d1b867f7b5 tests: Do not require line buffering
Test runner complains about it not being supported with binary files and
it does not look like it affects any tests in the first place anyway.
2020-11-21 12:41:18 -05:00
Tomas Babej
52c49169b4 tests: Use updated unittest methods 2020-11-21 12:39:03 -05:00
Tomas Babej
720c561b75 tests: Use updated Thread object API
Replace isAlive with is_alive as the former is no longer supported in
Python 3.9.
2020-11-21 12:38:14 -05:00
Leo
041248e7cc Uncoditionally include errno.h instead of guessing
POSIX tells us that it is errno.h, musl fails to build with -Werror
because it redirects sys/errno.h->errno.h and uses #warning
2020-11-21 12:27:29 -05:00
Tomas Babej
3855ba9136 travis: Disable testing on gentoo
We would love to test on gentoo, but this currently breaks CI. Open to
community contributions to improve our coverage of this distrubition.
2020-11-21 00:59:35 -05:00
Paul Beckingham
4729876714 Updated build to use C++17 by default 2020-11-20 17:47:13 -05:00
Paul Beckingham
4ae73ba871 Updated libshared for bug fix 2020-11-20 17:36:01 -05:00
Tomas Babej
10b64adb58 CmdAdd: Make sure a UUID is printed if ID does not exist
This fixes a regression was introduced in
4e80d5d5fd.

Currently, if a user (with default configuration) adds a completed or
deleted task, they do not get a confirmation message ("Created task
..."). This is due to the fact that:
a) new-uuid is not set by default
b) new-id is set by default, but only prints message if the added task
   is in pending or waiting state

Make sure to print a message containing UUID reference if the newly
added task is in completed or deleted state.
2020-09-18 00:24:50 -04:00
John Nguyen
cf45f28cc0 Fix typo in man page
The example for _unique has typo, should be using attribute for project.
Fixes #2277
2020-05-17 09:48:24 +02:00
0xACE
64243e6ec1 Poor implementation of linewrap restored to task
This addresses #2023

For many years linewrap has been broken in taskwarrior, rendering the
application basically useless in terminals with short widths and tasks
containing URLs in them... This janky line wrap patch sort of works but
introduces other minor graphical glitches.

But seeing as no one took the time to fix it over the years, here some a
small salvation to those who suffer as much as me.

One problem of this patch is, when a line is wrapped, it may be 1 column
smaller than the terminal width, resulting in each line not fully
utilizing the terminal width.

This patch is not polished and could probably need to be tended by
someone who cares more.
2020-03-12 10:40:24 -04:00
Paul Beckingham
e186d375dc Issue 2091: duration of task is set to a wrong and extremely big value
- Thanks to Wray Zheng.
2019-08-11 19:57:52 -04:00
Paul Beckingham
04bc1a7998 - Thanks to Adrien Lemaire. 2019-08-11 14:01:22 -04:00
Doron Behar
82ed5d35b7 Truely remove priority from hardcoded attrributes 2019-05-20 09:43:24 -04:00
Doron Behar
e1998346e1 Complete attributes dynamically incl UDAs
This is the major refinement of the completion: Most of it just moved
the global variables from up above to inside _task_filter so every array
of attributes will be calculated dynamically there.
2019-05-20 09:43:24 -04:00
Doron Behar
f04d66e10b Fix small TODO and move main function to bottom 2019-05-20 09:43:24 -04:00
Doron Behar
da49dbdd84 Add TODOs to make zsh completion awesome 2019-05-20 09:43:24 -04:00
Paul Beckingham
ac97523275 libshared: Upgraded to 4178b49db1c5fed5006a4ab6aa2df3f9937f770b 2019-04-26 20:54:16 -04:00
Paul Beckingham
fb97883bef Build: Do not set CMP0037 on CMake 3.11.0 and above
- This policy is no longer necessary because CMake issue #16062, which caused
  incorrect warnings to be shown, has been resolved in 3.11.0.
- Thanks to Janik Rabe
2019-04-26 20:45:46 -04:00
Paul Beckingham
415ce36861 Updated AUTHOR and Changelog 2019-04-14 19:47:52 -04:00
Paul Beckingham
18395a8dc0 - Thanks to Chad Phillips 2019-04-14 19:47:41 -04:00
Chad Phillips
2ac1787dae JSON encode/decode string UDAs
Previously, multiline string UDAs were not preserved when editing
a task via 'task X edit'. String UDAs are now JSON encoded/decoded
during the edit cycle to allow preservation of multiline
2019-04-14 19:45:58 -04:00
Lionel Miller
62944f3c7d Workaround for alias grep=rg in fish 2019-04-14 19:45:54 -04:00
mrossinek
f06eb12d10 Add unit test 2019-04-14 19:45:13 -04:00
mrossinek
0e58226f3b Fix #1999 2019-04-14 19:45:11 -04:00
mrossinek
2821c5ac44 Add missing newline 2019-04-14 19:45:04 -04:00
mrossinek
b0c9bf6c8d Fix #2002 2019-04-14 19:44:35 -04:00
Paul Beckingham
b87703eb39 Tests: REmoved check for absence of a segfault
- Testing for the absence of a segfault is not a good test.
2019-03-03 10:50:49 -05:00
Paul Beckingham
863038905c Tests: Version test removed
- Veriying that the diag  command emits the correct commit SHA1 creates
  sporadic failures when CMake has not been run against the current
  commit, and this is not a good test.
2019-03-03 10:34:09 -05:00
Paul Beckingham
2eb488359d Certs: Updated test certs 2019-03-03 10:03:42 -05:00
Paul Beckingham
9030d90894 Docs: Updated to add Lionel and remove dev comment 2019-03-03 09:57:36 -05:00
Paul Beckingham
473eb628bc Revert "Workaround for alias grep=rg in fish"
This reverts commit 672611435a.
2019-03-02 19:48:09 -05:00
Lionel Miller
672611435a Workaround for alias grep=rg in fish 2019-03-02 19:45:21 -05:00
Paul Beckingham
3c73af7964 Updated Copyright 2019-03-02 14:33:04 -05:00
Paul Beckingham
e8f183b403 libshared: Upgraded to aa4471478a88ad53ee8f087700726341a8a80157 2019-03-02 14:21:00 -05:00
Paul Beckingham
3313e1f6cc Updated copyright 2019-03-02 14:13:31 -05:00
Paul Beckingham
9fd12498ed CmdVersion: Updated YYYY 2019-03-02 14:06:39 -05:00
Paul Beckingham
49a5937ace Test: Updated diag test expectation 2019-03-02 14:03:34 -05:00
Paul Beckingham
bf8fa9a504 libshared: Upgraded to 4c0d722188a5362695064e443df505d23c524170 2019-03-02 14:01:12 -05:00
Tomas Babej
a6405e8935 README: Make the build badge point to 2.5.2 branch 2019-02-07 08:37:59 -05:00
Tomas Babej
d457bca59a tests: Add CentOS7 CI testing support 2019-02-07 08:37:59 -05:00
Tomas Babej
8f8a04fdb5 tests: Install libfaketime in all containers 2019-02-07 08:37:59 -05:00
Tomas Babej
a4ce40add4 tests: Improve bytes python3 compatibility 2019-02-07 08:37:59 -05:00
Tomas Babej
b8347821c4 tests: due:yesterday does not match current year on 1st of January 2019-02-07 08:37:59 -05:00
Tomas Babej
3f97a034c7 tests: mkstemp_exec needs argument in bytes 2019-02-07 08:37:59 -05:00
Tomas Babej
74949bb049 tests: Fix incorrect assert method 2019-02-07 08:37:59 -05:00
Tomas Babej
9e7f259d03 tests: Do not use filter objects
The filter objects are not well handled by the unittest framework, pass
a concrete number of occurences instead.
2019-02-07 08:37:59 -05:00
Tomas Babej
b8b06e6680 tests: Encode input data for the subprocess
Needed for Python2/3 compatibility.
2019-02-07 08:37:59 -05:00
Tomas Babej
928befeea2 tests: Use verbose output when running the tests 2019-02-07 08:37:59 -05:00
Tomas Babej
e171c0aa9b travis: Reorder platform entries, move Gentoo to the top
Since the Gentoo build takes the longest, it makes sense to start
executing it as first.
2019-02-07 08:37:59 -05:00
Tomas Babej
2140298af2 tests: Do not explicitly require Python 2.7 2019-02-07 08:37:59 -05:00
Tomas Babej
adece30891 tests: Add Archlinux 2018 platform 2019-02-07 08:37:59 -05:00
Tomas Babej
012430cfb6 tests: Add OpenSUSE platform 2019-02-07 08:37:59 -05:00
Tomas Babej
0b20a7eef8 tests: Add Debian Testing as a platform 2019-02-07 08:37:59 -05:00
Tomas Babej
82102f59ba tests: Add gentoo platform 2019-02-07 08:37:59 -05:00
Tomas Babej
539dae2148 travis: Be explicit about Mac OS X version 2019-02-07 08:37:59 -05:00
Tomas Babej
d3d7055103 travis: Use docker run instead of docker up 2019-02-07 08:37:59 -05:00
Tomas Babej
ea2c4d96b4 tests: Add support for Fedora 29 2019-02-07 08:37:59 -05:00
Tomas Babej
9518cdc1e9 tests: Add testing support for Ubuntu 18.04 2019-02-07 08:37:59 -05:00
Tomas Babej
290fb4380c travis: Use travis_terminate instead of exit 2019-02-07 08:37:59 -05:00
Tomas Babej
420892d7a9 travis: Make sure error codes propagate outside of the if clause 2019-02-07 08:37:59 -05:00
Tomas Babej
7153a03a5f tests: Properly set the xtrace flag 2019-02-07 08:37:59 -05:00
Tomas Babej
53b5e5c8ee travis: Execute tests instead of rebuilding the container again in the script phase 2019-02-07 08:37:59 -05:00
Tomas Babej
d748650691 tests: Add OS X test sript 2019-02-07 08:37:59 -05:00
Tomas Babej
e850823809 travis: Set generic language to avoid Ruby default 2019-02-07 08:37:59 -05:00
Tomas Babej
d19b3aa837 travis: Remove syntax errors 2019-02-07 08:37:59 -05:00
Tomas Babej
534303795a travis: Remove language 2019-02-07 08:37:59 -05:00
Tomas Babej
d543b4c625 travis: Fix bash syntax error 2019-02-07 08:37:59 -05:00
Tomas Babej
4fdb042ad4 travis: Specify test matrix explicitly and add OS X 2019-02-07 08:37:59 -05:00
Tomas Babej
276039cf35 README: Move badges below the heading 2019-02-07 08:37:59 -05:00
Tomas Babej
0ef837bc19 README: Add travis badge 2019-02-07 08:37:59 -05:00
Tomas Babej
f6e7ac2e5e tests: Add intial version of the Travis CI file 2019-02-07 08:37:59 -05:00
Tomas Babej
cf9f6e958c tests: Add test container for Debian Stable 2019-02-07 08:37:59 -05:00
Tomas Babej
c2e1a9216d tests: Rename docker-compose service to keep naming consistent 2019-02-07 08:37:59 -05:00
Tomas Babej
a1b3cfece4 tests: Add docker-compose file 2019-02-07 08:37:59 -05:00
Tomas Babej
b5cf4ca56e tests: Change default command of the test containers to end with ./problems
This makes sure that non-zero return code is propagated out of the
container.
2019-02-07 08:37:59 -05:00
Tomas Babej
a071694324 test: Workaround the cyclic dependencies between the libraries 2019-02-07 08:37:59 -05:00
Tomas Babej
3c4b27608e test: Add fedora28 and ubuntu1604 dockerfiles
These dockerfiles can be used to run taskwarrior's test suite on the
respective platforms using the following commands:

$ cd taskwarrior.git
$ docker build -t test-tw-fedora28 -f test/docker/fedora28 .
$ docker run test-tw-fedora28

For ubuntu, replace fedora28 with ubuntu1604.
2019-02-07 08:37:59 -05:00
Paul Beckingham
493bbadb18 Create index.html 2018-11-21 12:14:15 -05:00
Simon Désaulniers
df70bb0173 doc/man: ready tasks sorted with started tasks 1st 2018-08-19 09:24:07 -04:00
Alexandre Provencio
78033ea2d3 Updates vim's ftdetect
As described on issue #2032.
2018-08-19 09:21:27 -04:00
Vladimir Shulyak
08d985f40c Display task ID when unwaiting task 2018-06-03 14:16:35 -04:00
Paul Beckingham
376d336525 libshared: Upgraded to 230c63bd385b2a5a6ee5eb431df54b0c5c229b4d 2018-05-26 10:00:05 -04:00
Paul Beckingham
edfa8ed4ea Cleanup: Removed file that was accidentally cherry-picked 2018-05-26 09:50:50 -04:00
Paul Beckingham
09f9b9e625 Build: Fixed missed context reference 2018-05-14 01:12:19 -04:00
Paul Beckingham
27055ea1b9 TW #2020: reserved.lines is not affecting the burndown height
- Thanks to ad₋si.
2018-05-14 01:04:59 -04:00
Paul Beckingham
9fefe4a378 Docs: Removed incorrect URL 2018-05-14 01:04:45 -04:00
Simon Ruderich
c5ac2e2d00 Docs: mention "urgency" as possible attribute for filters 2018-05-14 01:04:35 -04:00
Paul Beckingham
75ad38f244 TW #1922: Can't find export scripts
- Thanks to tom-doerr
2018-05-14 01:04:26 -04:00
Paul Beckingham
1133f02df7 TW #1986: [Nit] Update DEVELOPER.md after migration to Github
- Thanks to Kirill Bobyrev
2018-05-14 01:04:15 -04:00
Paul Beckingham
ce924349c1 Code cleanup: used auto 2018-05-14 01:04:02 -04:00
Paul Beckingham
24a68b2ad8 TW #1973: Don't nag when no tasks are READY
- Thanks to Martin F. Krafft
2018-05-14 01:03:54 -04:00
Kirill Bobyrev
06521a1b55 Update notes regarding C++14 support
4a929197ae introduced C++14 support.
The build will now terminate unless the compiler supports C++14
dialect. The documentation does not reflect that: this commit updates
few reference files to actually say that the building process requires
a C++14-compliant compiler.
2018-05-14 01:03:31 -04:00
Paul Beckingham
3594e1886f libshared: Upgraded to 999c824cf1139d208e884042eddef87a1d76fb7e 2018-05-14 01:03:17 -04:00
Paul Beckingham
aacf75d414 Updated AUTHORS 2018-05-14 01:03:08 -04:00
Kirill Bobyrev
511a235215 Use nullptr instead lf C-styled NULL 2018-05-14 01:02:57 -04:00
Simon Ruderich
6f19a3fbae Docs: remove duplication in task-color.5
In the example there are more than the three listed wildcard patterns.
Instead of listing them all, list just one. This is enough to describe
the idea.
2018-05-14 01:02:24 -04:00
Simon Ruderich
c6267c526d Docs: fix incorrect value in task-color.5 2018-05-14 01:02:16 -04:00
Simon Ruderich
90cc2a441d Context: remove duplicate default value for rule.precedence.color 2018-05-14 01:02:07 -04:00
Simon Ruderich
286fca3935 Docs: fix outdated link in task-sync.5 2018-05-14 01:01:51 -04:00
Paul Beckingham
9bfc8c2ff6 Docs: Updated AUTHORS 2018-05-14 01:01:42 -04:00
Paul Beckingham
e3dab66ad1 Update task-sync.5.in
Downgraded 'Always secure' to 'Secure communication', for accuracy.
2018-05-14 01:01:32 -04:00
Simon Ruderich
eabda340ef Docs: remove instructions which are already default in task-color.5
The text even mentions, that it might not be necessary. So just remove
this section.
2018-05-14 01:01:22 -04:00
Simon Ruderich
d0bbe2a0e8 Docs: don't mark cloud provides as "always secure" in task-sync.5
The data is stored remotely and possibly (depending on the provider) not
transfered securely.
2018-05-14 01:01:14 -04:00
Simon Ruderich
7441e6cf74 Docs: remove insecure CA configuration from task-sync.5
The option taskd.trust is documented in taskrc.5 if the user really
needs it. But we shouldn't suggest an insecure configuration in the
default setup instructions.
2018-05-14 01:01:06 -04:00
Simon Ruderich
a87dfe62ad Docs: sync "SEE ALSO" sections of task-color.5 and task-sync.5 2018-05-14 01:00:56 -04:00
Simon Ruderich
02470c5647 Docs: always use https:// link for taskwarrior.org 2018-05-14 01:00:44 -04:00
Simon Ruderich
c7edf914e1 Always use https:// link for opensource.org
It was already used in a few places, make this consistent.
2018-05-14 01:00:23 -04:00
Simon Ruderich
f98084bbd3 Docs: always use <> tags for placeholders in man pages 2018-05-14 00:57:53 -04:00
Simon Ruderich
ef538ef9da Docs: use unabbreviated "task colors" command in taskrc.5 2018-05-14 00:57:45 -04:00
Simon Ruderich
f492d423dd Docs: quote values for calendar.details in taskrc.5 2018-05-14 00:57:33 -04:00
Simon Ruderich
abc00ab6ca Docs: try to clarify what falls under header/footnote verbose settings 2018-05-14 00:57:00 -04:00
Simon Ruderich
243f613444 Docs: "recur" also implies "footnote" 2018-05-14 00:56:49 -04:00
Simon Ruderich
8fdd18f897 Docs: fix typos in taskrc man page 2018-05-14 00:56:33 -04:00
Paul Beckingham
822909d046 Docs: Added Tiago 2018-05-14 00:56:25 -04:00
Tiago Matias
95becc4f6f typo -> very simply syntax -> very simple syntax 2018-05-14 00:56:08 -04:00
Federico Hernandez
11a281b862 Changed to a more generic URL for testing 2018-05-14 00:55:57 -04:00
Federico Hernandez
b97e1400e6 Updated URL references 2018-05-14 00:55:45 -04:00
Federico Hernandez
a8c0646d18 Updated URLs and copyright year 2018-05-14 00:55:30 -04:00
Federico Hernandez
98175bac4b Udated URL in .gitmodules to point to GH 2018-05-14 00:54:42 -04:00
Paul Beckingham
81e65b43bf Docs: Updated Changelog with pull request info 2018-05-14 00:54:33 -04:00
Jakub Wilk
23d63ccb44 Tests: Don't hardcode errno constants
The values of ENOENT and ESRCH are architecture-dependent, so don't
assume they're always 2 and 3.
2018-05-14 00:54:10 -04:00
Paul Beckingham
59342bc10f TW-54/#115: Reduce output for timesheet
- Thanks to Aikido guy.
2018-05-14 00:53:49 -04:00
Paul Beckingham
ea81976ee9 TW-1917/#1930: "above" does a string comparison, even when the value is numeric
- Thanks to Dirk Deimeke.
2018-05-14 00:53:40 -04:00
Paul Beckingham
53088dae65 Build: C++14 support added 2018-05-14 00:53:32 -04:00
Paul Beckingham
2623d101e7 - Thanks to php-coder 2018-05-14 00:53:09 -04:00
Paul Beckingham
4f7ca3f2d1 TW-1906/#1919: sync sub-command is missing from task(1) manual page
- Thanks to rjc.
2018-05-14 00:52:45 -04:00
Dirk Deimeke
0411fd1ddc README.md
- Added instructions for failing clone of libshared.git
2018-05-14 00:52:07 -04:00
Paul Beckingham
eed9664173 Docs: Updated URLs 2018-05-14 00:51:53 -04:00
Paul Beckingham
7410b01cad Docs: Fixed md 2018-05-14 00:51:00 -04:00
Paul Beckingham
a9a60c4f9c Docs: Fixed md 2018-05-14 00:50:49 -04:00
Paul Beckingham
3a79bd908a Docs: Updated README.md
- Thanks to Thomas Lauf
2018-05-14 00:50:25 -04:00
Paul Beckingham
573ad560b6 Templates: Combined two sentences for readability 2018-05-14 00:50:10 -04:00
Federico Hernandez
e09699a029 Reformatting 2018-05-14 00:49:59 -04:00
Federico Hernandez
a6833c62f8 Made the question a checkbox
To be checked off by the submitter.
2018-05-14 00:49:47 -04:00
Dirk Deimeke
3585d21a41 Added Link to "How to request a feature" 2018-05-14 00:49:32 -04:00
Paul Beckingham
f34b2e23cb Github: typo 2018-05-14 00:45:06 -04:00
Paul Beckingham
0e38cdc4a9 Github: Added pull request template 2018-05-14 00:44:57 -04:00
Paul Beckingham
683141d14a Issues: /Updated template for feature requests 2018-05-14 00:44:48 -04:00
Paul Beckingham
36fac4efe1 Docs: Updated URLs 2018-05-14 00:44:34 -04:00
Paul Beckingham
ea4a23654f Issues: Create issue-template.md 2018-05-14 00:43:32 -04:00
Lynoure Braakman
cf42496970 Update and rename DEVELOPER to DEVELOPER.md
Rough markdownification, no content changes
2018-05-14 00:43:16 -04:00
buhtz
6db06524b1 URL formating 2018-05-14 00:42:04 -04:00
Paul Beckingham
a4c72238d0 Docs: Updated man page discussing rc.recurrence 2018-05-14 00:41:54 -04:00
Paul Beckingham
ae27a1b343 Eval: Eliminated string def 2018-05-14 00:41:45 -04:00
Mark Scannell
c7f2739dda Portability: Updated to make main re-entrant()
- New INSTALL instructions to emscripten, and AUTHORS for contribution.
2018-05-14 00:40:59 -04:00
Paul Beckingham
3d7c681ed0 Lexer: Migrated to unicodeLatinDigit 2018-05-14 00:36:16 -04:00
Paul Beckingham
0086a51311 Lexer: Migrated to unicodeLatinAlpha 2018-05-14 00:35:38 -04:00
Paul Beckingham
ea26369f80 Lexer: Migrated to unicodeHexDigit 2018-05-14 00:35:27 -04:00
Paul Beckingham
49dedfbc86 Lexer: Migrated to unicodeWhitespace 2018-05-14 00:35:17 -04:00
Paul Beckingham
2c89688b46 TW-1947: "urgency.over" filter seems to not work correct
- Thanks to Marc Richter.
2018-05-14 00:34:46 -04:00
Paul Beckingham
d5a0b616e1 Lexer: Fixed DOM missing lookahead 2018-05-14 00:34:32 -04:00
Paul Beckingham
e0dbf4b691 Tests: Fixed broken color merge tests 2018-05-14 00:34:22 -04:00
Paul Beckingham
41491843de Tests: Fixed brokend color.footnote test 2018-05-14 00:34:10 -04:00
Paul Beckingham
34c5a68635 I18N: Removed language build settings 2018-05-14 00:34:00 -04:00
Paul Beckingham
7be5b86618 l10n: Eliminated i18n.h 2018-05-14 00:33:43 -04:00
Paul Beckingham
1ea9721e90 l10n: Eliminated some column labels 2018-05-14 00:33:20 -04:00
Paul Beckingham
0ffadafe3c l10n: Eliminated some column labels 2018-05-14 00:33:08 -04:00
Paul Beckingham
a9adf06d98 l10n: Eliminated some column labels 2018-05-14 00:32:54 -04:00
Paul Beckingham
540484f92f l10n: Eliminated some column labels 2018-05-14 00:32:44 -04:00
Paul Beckingham
238f81f621 l10n: Eliminated some column labels 2018-05-14 00:32:34 -04:00
Paul Beckingham
20508c45f2 l10n: Eliminated some column labels 2018-05-14 00:32:07 -04:00
Paul Beckingham
ef58767834 l10n: Eliminated some column labels 2018-05-14 00:31:43 -04:00
Paul Beckingham
0ef1166b0b DOM: No more I18N 2018-05-14 00:30:10 -04:00
Paul Beckingham
6e3c556d0b l10n: Eliminated some column labels 2018-05-14 00:30:01 -04:00
Paul Beckingham
02f786694e l10n: Eliminated some column labels 2018-05-14 00:29:47 -04:00
Paul Beckingham
4b485ad570 l10n: Eliminated some column labels 2018-05-14 00:29:34 -04:00
Paul Beckingham
3df06e6482 l10n: Eliminated some column labels 2018-05-14 00:29:16 -04:00
Paul Beckingham
c94f481f2a l10n: Eliminated some column labels 2018-05-14 00:28:45 -04:00
Paul Beckingham
41f2133693 l10n: Eliminated some column labels 2018-05-14 00:26:40 -04:00
Paul Beckingham
2872b44b45 l10n: Eliminated some column labels 2018-05-14 00:22:16 -04:00
Paul Beckingham
5c9d96d5a8 l10n: Eliminated some column labels 2018-05-14 00:20:44 -04:00
Paul Beckingham
3d8be2119e l10n: Eliminated some column labels 2018-05-14 00:20:32 -04:00
Paul Beckingham
569522b007 l10n: Eliminated some column labels 2018-05-14 00:20:20 -04:00
Paul Beckingham
dccb8081bc l10n: Eliminated some column labels 2018-05-14 00:20:06 -04:00
Paul Beckingham
df5cf4ff9c l10n: Eliminated some column labels 2018-05-14 00:19:56 -04:00
Paul Beckingham
03ede837e4 l10n: Eliminated some column labels 2018-05-14 00:19:42 -04:00
Paul Beckingham
e6fd4efd08 l10n: Eliminated some column labels 2018-05-14 00:19:22 -04:00
Paul Beckingham
1cd810f8f6 l10n: Eliminated some column labels 2018-05-14 00:19:10 -04:00
Paul Beckingham
ce1c98ec52 l10n: Eliminated some column labels 2018-05-14 00:18:58 -04:00
Paul Beckingham
42a9352f48 l10n: Eliminated some column labels 2018-05-14 00:18:41 -04:00
Paul Beckingham
a7b915299a l10n: Eliminated STRING_COLUMN_LABEL_ADDED, STRING_COLUMN_LABEL_AGE 2018-05-14 00:18:27 -04:00
Paul Beckingham
4819584714 l10n: Eliminated STRING_COLUMN_LABEL_ACTIVE, STRING_COLUMN_LABEL_STARTED 2018-05-14 00:18:16 -04:00
Paul Beckingham
d58184efa1 l10n: Eliminated STRING_COLUMN_EXAMPLES_* 2018-05-14 00:18:04 -04:00
Paul Beckingham
1f833dcae2 l10n: Eliminated STRING_COLUMN_LABEL_DESC 2018-05-14 00:17:54 -04:00
Paul Beckingham
c66e8917c8 l10n: Eliminated some STRING_COLUMN_EXAMPLES_* 2018-05-14 00:17:41 -04:00
Paul Beckingham
247355f15b l10n: Eliminated STRING_CMD_UNDO_* 2018-05-14 00:17:31 -04:00
Paul Beckingham
5112479372 l10n: Eliminated STRING_CMD_UDAS_* 2018-05-14 00:17:17 -04:00
Paul Beckingham
5dd5de0d76 l10n: Eliminated STRING_CMD_COMTAGS_USAGE 2018-05-14 00:17:01 -04:00
Paul Beckingham
0339feecda l10n: Eliminated STRING_CMD_*IDS_* 2018-05-14 00:16:48 -04:00
Paul Beckingham
2098b0166f l10n: Eliminated STRING_CMD_CUSTOM_* 2018-05-14 00:16:35 -04:00
Paul Beckingham
28d60d8b10 l10n: Eliminated STRING_CMD_ZSHATTS_USAGE 2018-05-14 00:16:21 -04:00
Paul Beckingham
a730a482c3 l10n: Eliminated STRING_CMD_*COMMANDS_* 2018-05-14 00:16:09 -04:00
Paul Beckingham
bd836d763c l10n: Eliminated STRING_CMD_EXEC_* 2018-05-14 00:15:51 -04:00
Paul Beckingham
a7d75c9071 l10n: Eliminated STRING_CMD_URGENCY_* 2018-05-14 00:15:37 -04:00
Paul Beckingham
fdc045a230 l10n: Eliminated STRING_CMD_TAGS_* 2018-05-14 00:15:20 -04:00
Paul Beckingham
faf6ecceda l10n: Eliminated STRING_CMD_CAL_* 2018-05-14 00:14:59 -04:00
Paul Beckingham
3a2b5df05d l10n: Eliminated STRING_CMD_ALIASES_* 2018-05-14 00:14:38 -04:00
Paul Beckingham
6c4e861eac l10n: Eliminated STRING_CMD_INFO_* 2018-05-14 00:14:11 -04:00
Paul Beckingham
a21a523896 l10n: Eliminated STRING_CMD_REPORTS_* 2018-05-14 00:13:52 -04:00
Paul Beckingham
4b77ee5c25 Code cleanup: Removed unnecessary include 2018-05-14 00:13:34 -04:00
Paul Beckingham
8badebca26 l10n: Eliminated STRING_CMD_IMPORT_* 2018-05-14 00:13:27 -04:00
Paul Beckingham
b5388cb3a4 Code cleanup: Removed unnecessary include 2018-05-14 00:13:13 -04:00
Paul Beckingham
4b75865e47 l10n: Eliminated STRING_CMD_ADD_* 2018-05-14 00:13:04 -04:00
Paul Beckingham
9640f5a02b Code cleanup: Removed unnecessary include 2018-05-14 00:12:47 -04:00
Paul Beckingham
881c38e301 L10N: Normalized files 2018-05-14 00:10:55 -04:00
Paul Beckingham
20b9ead82a l10n: Eliminated STRING_CMD_UNIQUE_* 2018-05-14 00:07:43 -04:00
Paul Beckingham
fb62263871 Code cleanup: Removed unnecessary include 2018-05-14 00:07:29 -04:00
Paul Beckingham
c5f24f6481 l10n: Eliminated STRING_CMD_LOG_* 2018-05-14 00:07:17 -04:00
Paul Beckingham
c2fad1fa90 L10N: Eliminated check_translations.sh 2018-05-14 00:06:55 -04:00
Paul Beckingham
02f3ce74d7 l10n: Eliminated STRING_CMD_{G,}HISTORY_* 2018-05-14 00:06:36 -04:00
Paul Beckingham
489515968c l10n: Eliminated STRING_CMD_CALC_* 2018-05-14 00:06:16 -04:00
Paul Beckingham
76b7dc3820 Code cleanup: Removed unnecessary include 2018-05-14 00:06:03 -04:00
Paul Beckingham
7f23fe3f64 l10n: Eliminated STRING_CMD_VERSION_* 2018-05-14 00:05:53 -04:00
Paul Beckingham
e269626982 CmdVersion: Uses libshared osName 2018-05-14 00:05:41 -04:00
Paul Beckingham
92adb55c7a l10n: Eliminated STRING_CMD_PREPEND_* 2018-05-14 00:05:30 -04:00
Paul Beckingham
8e01baa49a l10n: Eliminated STRING_CMD_TIMESHEET_* 2018-05-14 00:05:17 -04:00
Paul Beckingham
375294a56c l10n: Eliminated STRING_CMD_CONFIG_* 2018-05-14 00:04:55 -04:00
Paul Beckingham
765c12a2d1 l10n: Eliminated STRING_CMD_CONTEXT_* 2018-05-14 00:04:44 -04:00
Paul Beckingham
5d08b64c23 l10n: Eliminated STRING_CMD_COLOR_* 2018-05-14 00:04:24 -04:00
Paul Beckingham
86f260672b l10n: Eliminated STRING_FEEDBACK_NO_TASKS_SP 2018-05-14 00:04:12 -04:00
Paul Beckingham
98f02b62b2 l10n: Eliminated STRING_CMD_APPEND_* 2018-05-14 00:03:46 -04:00
Paul Beckingham
44a94b0b50 l10n: Eliminated STRING_CMD_PURGE_* 2018-05-14 00:03:34 -04:00
Paul Beckingham
12171e3318 l10n: Eliminated STRING_CMD_PROJECTS_* 2018-05-14 00:03:18 -04:00
Paul Beckingham
cafe1478e6 l10n: Eliminated STRING_CMD_DENO_* 2018-05-14 00:03:07 -04:00
Paul Beckingham
bbc9c0bb47 l10n: Eliminated STRING_CMD_ANNO_* 2018-05-14 00:02:53 -04:00
Paul Beckingham
df7967c6f8 l10n: Eliminated STRING_CMD_COUNT_* 2018-05-14 00:02:40 -04:00
Paul Beckingham
7c5dca0553 l10n: Eliminated STRING_CMD_STATS_* 2018-05-14 00:02:25 -04:00
Paul Beckingham
b3aa531f4a l10n: Eliminated STRING_CMD_SUMMARY_* 2018-05-14 00:02:12 -04:00
Paul Beckingham
e830176d13 l10n: Eliminated STRING_CMD_BURN_* 2018-05-14 00:01:55 -04:00
Paul Beckingham
23cc9b23e3 l10n: Eliminated STRING_CMD_GET_* 2018-05-14 00:01:29 -04:00
Paul Beckingham
dbf76874b9 l10n: Eliminated STRING_CMD_SHOW* 2018-05-14 00:01:15 -04:00
Paul Beckingham
cf1395afd8 l10n: Eliminated STRING_CMD_DELETE_* 2018-05-14 00:01:00 -04:00
Paul Beckingham
7b2e45692e l10n: Eliminated STRING_CMD_UDAS_* 2018-05-14 00:00:48 -04:00
Paul Beckingham
0e2cb5866c l10n: Eliminated STRING_COLUMN_LABEL_DEP* 2018-05-14 00:00:34 -04:00
Paul Beckingham
c44a6433fd calc: Fixed string param 2018-05-14 00:00:21 -04:00
Paul Beckingham
a66fe6de73 l10n: Eliminated STRING_CMD_DUPLICATE_* 2018-05-13 23:59:48 -04:00
Paul Beckingham
026ac59326 l10n: Eliminated STRING_CMD_MODIFY_* 2018-05-13 23:59:30 -04:00
Paul Beckingham
4e9267eed2 l10n: Eliminated STRING_CMD_SYNC_* 2018-05-13 23:59:15 -04:00
Paul Beckingham
0daaf05782 l10n: Eliminated STRING_CMD_DIAG_* 2018-05-13 23:58:59 -04:00
Paul Beckingham
9244828618 l10n: Eliminated STRING_CMD_DONE_* 2018-05-13 23:58:25 -04:00
Paul Beckingham
3d1a430b62 l10n: Eliminated STRING_CMD_STOP_* 2018-05-13 23:58:00 -04:00
Paul Beckingham
4f08212415 l10n: Eliminated STRING_CMD_LOGO_* 2018-05-13 23:57:42 -04:00
Paul Beckingham
58ff0e74f4 l10n: Eliminated STRING_CMD_START_* 2018-05-13 23:57:29 -04:00
Paul Beckingham
61a377cc29 l10n: Eliminated STRING_TASK_VALID_DESC 2018-05-13 23:57:09 -04:00
Paul Beckingham
a3bf98deff l10n: Eliminated STRING_COLUMN_LABEL_ID 2018-05-13 23:56:54 -04:00
Paul Beckingham
083efc265b l10n: Eliminated STRING_COLUMN_LABEL_TASKS 2018-05-13 23:56:36 -04:00
Paul Beckingham
bbb00ac7ef l10n: Eliminated STRING_COLUMN_BAD_FORMAT 2018-05-13 23:56:22 -04:00
Paul Beckingham
78c2c1c2da l10n: Eliminated STRING_COLUMN_BAD_NAME 2018-05-13 23:56:10 -04:00
Paul Beckingham
7123784734 l10n: Eliminated STRING_ERROR_NO_FILTER 2018-05-13 23:55:46 -04:00
Paul Beckingham
47ef45ee38 l10n: Eliminated STRING_ERROR_DETAILS 2018-05-13 23:55:30 -04:00
Paul Beckingham
ead5322340 l10n: Eliminated STRING_INVALID_MOD 2018-05-13 23:55:17 -04:00
Paul Beckingham
67c5bc97ce l10n: Eliminated STRING_UDA_COLLISION 2018-05-13 23:55:02 -04:00
Paul Beckingham
5301e98942 l10n: Eliminated STRING_LOCALIZATION_* 2018-05-13 23:54:51 -04:00
Paul Beckingham
cece9201bb l10n: Eliminated STRING_UDA_TYPE 2018-05-13 23:54:36 -04:00
Paul Beckingham
1857882d9e l10n: Eliminated STRING_CMD_COLUMNS_* 2018-05-13 23:54:23 -04:00
Paul Beckingham
e1fda18164 l10n: Eliminated STRING_HELPER_PROJECT_* 2018-05-13 23:54:06 -04:00
Paul Beckingham
977e2a3c35 l10n: Eliminated STRING_ERROR_BAD_STATUS 2018-05-13 23:53:50 -04:00
Paul Beckingham
92ecc4d7fd l10n: Eliminated STRING_INFINITE_LOOP 2018-05-13 23:53:37 -04:00
Paul Beckingham
a432cec468 l10n: Eliminated STRING_TRIVIAL_INPUT 2018-05-13 23:53:23 -04:00
Paul Beckingham
f27ddea013 l10n: Eliminated STRING_ERROR_PREFIX 2018-05-13 23:53:11 -04:00
Paul Beckingham
e2ffcbd3d6 l10n: Eliminated STRING_PARSER_* 2018-05-13 23:52:59 -04:00
Paul Beckingham
e65f1ecffe l10n: Eliminated STRING_EDIT_* 2018-05-13 23:52:43 -04:00
Paul Beckingham
51241c5a95 l10n: Eliminated STRING_RECORD_* 2018-05-13 23:52:11 -04:00
Paul Beckingham
9925b4e3a9 l10n: Eliminated STRING_COLOR_UNRECOGNIZED 2018-05-13 23:51:57 -04:00
Paul Beckingham
cdb1326219 l10n: Eliminated STRING_EDIT_TABLE_HEADER 2018-05-13 23:51:44 -04:00
Paul Beckingham
d8bd32aee8 l10n: Eliminated STRING_DEPEND_* 2018-05-13 23:51:31 -04:00
Paul Beckingham
7b3d2e5cd6 l10n: Eliminated STRING_CONFIG_* 2018-05-13 23:51:14 -04:00
Paul Beckingham
58dce57b7e l10n: Eliminated STRING_CONFIG_DEPRECATED_COL 2018-05-13 23:50:57 -04:00
Paul Beckingham
c0281b21f0 l10n: Eliminated STRING_CONFIG_DEPRECATED_VAR 2018-05-13 23:50:46 -04:00
Paul Beckingham
a43ec0189a l10n: Eliminated STRING_DATE_BAD_WEEKSTART 2018-05-13 23:50:32 -04:00
Paul Beckingham
f6d2fe6093 l10n: Eliminated STRING_DATE_INVALID_FORMAT 2018-05-13 23:50:18 -04:00
Paul Beckingham
d56487e509 l10n: Eliminated STRING_DATE_<month> 2018-05-13 23:50:04 -04:00
Paul Beckingham
4763b1da6e l10n: Eliminated STRING_DATE_*DAY 2018-05-13 23:49:41 -04:00
Paul Beckingham
8eec5c82c2 l10n: Eliminated STRING_CMD_CONFIG_NO_CHANGE 2018-05-13 23:49:27 -04:00
Paul Beckingham
2854aba5e3 l10n: Eliminated STRING_TDB2_* 2018-05-13 23:49:05 -04:00
Paul Beckingham
b1a593d27e l10n: Eliminated STRING_VIEW_TOO_SMALL 2018-05-13 23:48:41 -04:00
Paul Beckingham
61d4cb2a6e l10n: Eliminated STRING_RECUR_CREATE 2018-05-13 23:48:27 -04:00
Paul Beckingham
72383a7d7f l10n: Eliminated STRING_TASK_VALID_RECUR 2018-05-13 23:48:06 -04:00
Paul Beckingham
1fc7dc3951 l10n: Eliminated STRING_CMD_EXPORT_USAGE 2018-05-13 23:46:42 -04:00
Paul Beckingham
8e87f3f969 l10n: Eliminated STRING_LEGACY_PRIORITY 2018-05-13 23:46:28 -04:00
Paul Beckingham
bc90b9a4e1 l10n: Eliminated STRING_UTIL_CONFIRM_* 2018-05-13 23:46:17 -04:00
Paul Beckingham
ff02cf8613 l10n: Eliminated STRING_ERROR_CONFIRM_SIGINT 2018-05-13 23:45:58 -04:00
Paul Beckingham
7361431799 l10n: Eliminated STRING_DOM_UNREC 2018-05-13 23:42:42 -04:00
Paul Beckingham
bd41582b97 l10n: Eliminated STRING_EVAL_* 2018-05-13 23:42:20 -04:00
Paul Beckingham
d4edf577eb l10n: Eliminated translation instructions 2018-05-13 23:42:00 -04:00
Paul Beckingham
12865e3b85 l10n: Eliminated STRING_CMD_VERSION_* 2018-05-13 23:41:37 -04:00
Paul Beckingham
f2e725b3c9 l10n: Eliminated STRING_HOOKS_* 2018-05-13 23:41:18 -04:00
Paul Beckingham
f1049b4a7a l10n: Eliminated STRING_TASK_INVALID_DUR 2018-05-13 23:41:00 -04:00
Paul Beckingham
fe93e72f0b l10n: Eliminated STRING_COLUMN_LABEL_PARENT 2018-05-13 23:40:41 -04:00
Paul Beckingham
8d1f66cd41 Utils: Removed l10n utility 2018-05-13 23:38:24 -04:00
Paul Beckingham
06734487ee Docs: Added note about translations no longer being supported 2018-05-13 23:38:01 -04:00
Paul Beckingham
aefe06b296 l10n: Eliminated STRING_CMD_HELP_USAGE_LABEL 2018-05-13 23:37:20 -04:00
Paul Beckingham
3576e8f784 l10n: Eliminated STRING_CMD_HELP_USAGE_DESC 2018-05-13 23:37:05 -04:00
Paul Beckingham
5cf7c12dc9 l10n: Eliminated STRING_CMD_HELP_ALIASED 2018-05-13 23:36:53 -04:00
Paul Beckingham
fc418d1195 l10n: Eliminated STRING_CMD_HELP_TEXT 2018-05-13 23:36:41 -04:00
Paul Beckingham
b942cae98e l10n: Eliminated STRING_CMD_HELP_TEXT 2018-05-13 23:36:24 -04:00
Paul Beckingham
3987828294 l10n: Eliminated STRING_CONTEXT_CREATE_RC 2018-05-13 23:35:42 -04:00
Paul Beckingham
e25a64af9b l10n: Eliminated STRING_CONTEXT_DATA_OVERRIDE 2018-05-13 23:35:27 -04:00
Paul Beckingham
4ce0113395 l10n: Eliminated STRING_CONTEXT_RC_OVERRIDE 2018-05-13 23:35:11 -04:00
Paul Beckingham
efff69bc49 l10n: Eliminated STRING_CONTEXT_NEED_RC 2018-05-13 23:34:56 -04:00
Paul Beckingham
487d504486 l10n: Eliminated STRING_CONFIG_BAD_WRITE 2018-05-13 23:34:38 -04:00
Paul Beckingham
47e9aa9abb l10n: Eliminated STRING_ASSUME_INFO 2018-05-13 23:34:26 -04:00
Paul Beckingham
4ad3c48f2d l10n: Eliminated STRING_DATE_SUNDAY 2018-05-13 23:34:12 -04:00
Paul Beckingham
bfcb3eac49 l10n: Eliminated STRING_INVALID_SORT_COL 2018-05-13 23:33:59 -04:00
Paul Beckingham
b30e19b23c l10n removal of STRING_COLUMN_LABEL_MASK, STRING_COLUMN_LABEL_MASK_IDX 2018-05-13 23:33:39 -04:00
Paul Beckingham
3f14491e31 l10n removal of STRING_UDA_NUMERIC 2018-05-13 23:31:28 -04:00
Paul Beckingham
798cd5b658 l10n removal of STRING_UNKNOWN_ERROR 2018-05-13 23:31:15 -04:00
Paul Beckingham
f24ea5e56c libshared: Updated to 1fa5dcbf53a280857e35436aef6beb6a37266e33 2018-05-13 23:30:53 -04:00
Paul Beckingham
216d4d63bc Copyright 2018 2018-05-13 23:30:21 -04:00
Paul Beckingham
018770e894 TI-91: Timewarrior does not compile on DragonFly
- Thanks to Michael Neumann.
2018-05-13 23:27:51 -04:00
Paul Beckingham
2e2bdb0d0d Docs: Updated ChangeLog 2018-05-13 23:27:36 -04:00
Paul Beckingham
3ad683a370 Test: Improved C+ Core Guidelines compliance 2018-05-13 23:27:25 -04:00
Paul Beckingham
ad21e86f06 TW-1938: Adjust behaviour of new-uuid and new-id verbosity levels
- Thanks to Paul J. Fenwick.
2018-05-13 23:27:03 -04:00
Paul Fenwick
4e80d5d5fd [TW-1938] Resolve conflicts between new-id and new-uuid
- new-uuid is *not* set by default
- new-uuid overrides new-id when set

The reasoning is that new-uuid is mostly used by code (eg: Python's
taskw module), whereas new-id is mostly used by humans.

By making new-uuid not set by default, calling code can set it to
receive UUIDs (preserving 2.5.x behaviour), but humans can continue to
use integer task IDs.
2018-05-13 23:26:48 -04:00
Paul Beckingham
f7dc21d24d TW-1930: Typo in help
- Thanks to Kai HTML.
2018-05-13 23:26:28 -04:00
Paul Beckingham
5e93134ea4 TW-1935: Separate verbosity category for rc overrides
- Thanks to Paul J. Fenwick.
2018-05-13 23:26:11 -04:00
Paul Fenwick
8baf544040 CLI2/Context: Add vim hints
No need for vim to guess indent style with these handy vim hints!
2018-05-13 23:26:02 -04:00
Paul Fenwick
ec31b93447 CLI2,Config: Add 'override' verbosity option
This allows for 'override' messages to be silenced without requiring
footnotes be completely disabled.

The 'override' verbosity implies 'footnotes'.
2018-05-13 23:25:52 -04:00
Paul Fenwick
aefe16a6e2 Docs/CLI2: Additional dev docs for applyOverrides 2018-05-13 23:25:32 -04:00
Paul Beckingham
9d26327ae4 TW-1936: Tweak tests to have fuller TAP compliance
- Thanks to Paul J. Fenwick.
2018-05-13 23:25:20 -04:00
Paul Fenwick
f767ef2f19 test/problems: Updated to handle TAP spec output 2018-05-13 23:25:11 -04:00
Paul Fenwick
3b46553f47 Improve TAP compliance in test suite
This allows tools like `prove` to operate on our test-suite, allowing us
to do things like run recently-failing tests first, randomising test
order, and fancier reporting options.

Changes made:

- TAP output always goes to STDOUT, never to STDERR
- Skipped tests signaled as `ok 1 # skip` as per standard
- Expected failures signaled as `not ok 1 # TODO` as per standard
- `.prove` added to .gitignore
2018-05-13 23:24:57 -04:00
Paul Beckingham
b3192b94b4 Docs: Removed obsolete URL 2018-05-13 23:24:36 -04:00
Paul Beckingham
878256306c Error: Changed (1) error format 2018-05-13 23:24:26 -04:00
Tomas Babej
87bcbeda37 DEVELOPER: Update git repo url 2018-05-13 23:24:10 -04:00
Tomas Babej
7465410c5a context: Do not allow show, list or none as new context names
- Thanks to silviof.
2018-05-13 23:23:53 -04:00
Paul Beckingham
d987c9f5cd Scripts: Updated URLs 2018-05-13 23:22:41 -04:00
Tomas Babej
bb8092a5e4 tests: Add tests for complex and-or queries 2018-05-13 23:22:15 -04:00
Tomas Babej
f10d1432f3 tests: Add tests for complex and-or queries 2018-05-13 23:21:34 -04:00
Paul Beckingham
1f8eae0071 Reapplying include removal without libshared update 2018-05-13 23:21:22 -04:00
Paul Beckingham
9c5e3750c4 Revert "TLSClient: Remove double include"
This reverts commit 2321c17d8d.
2018-05-13 23:21:13 -04:00
Tomas Babej
3c1157fe5d TLSClient: Remove double include 2018-05-13 23:20:56 -04:00
Tomas Babej
de0b54cfb6 Update AUTHORS and ChangeLog file 2018-05-13 23:20:47 -04:00
Tomas Babej
7fc6d7c5bf TW-1910: Remove unreachable statement
- Thanks to Martin Strunz.
2018-05-13 23:20:35 -04:00
Paul Beckingham
bbd764d249 Tests: Added dom tests 2018-05-13 23:20:14 -04:00
Paul Beckingham
4c53da5be1 DOM: Implemented DOM::Node object 2018-05-13 23:19:59 -04:00
Paul Beckingham
eba68ac2ff DOM: Added dtor that delegate to DOM::Node 2018-05-13 23:19:20 -04:00
Paul Beckingham
0742e5fbbd Tests: Added tw.version DOM test 2018-05-13 23:18:59 -04:00
Paul Beckingham
8bbc35560f DOM: New reference tw.version. 2018-05-13 23:18:49 -04:00
Paul Beckingham
0ea3215e7a DOM: Fixed ::count bug 2018-05-13 23:18:30 -04:00
Paul Beckingham
d5a7769b4f Tests: Added first DOM test 2018-05-13 23:18:17 -04:00
Paul Beckingham
ba372e106f Tests: Renamed dom.t to make way for new DOM object tests 2018-05-13 23:18:00 -04:00
Paul Beckingham
f6566838f6 DOM: Added framework 2018-05-13 23:17:50 -04:00
Paul Beckingham
ee3e8c46dc DOM: Stubbed DOM tree 2018-05-13 23:17:26 -04:00
Paul Beckingham
4afe912f84 Docs: Added to AUTHORS file 2018-05-13 23:16:06 -04:00
Øyvind A. Holm
ac392561c1 Docs: Typo fix in task.1.in 2018-05-13 23:15:53 -04:00
Paul Beckingham
a1bdb8f99d Docs: Updated platform list 2018-05-13 23:15:41 -04:00
Tomas Babej
5e52acf63a INSTALL: Use https link for cmake.org 2018-05-13 23:13:39 -04:00
Tomas Babej
d6930e89ef LICENSE: Use https link instead of http 2018-05-13 23:13:29 -04:00
Paul Beckingham
be594918a9 libshared: Updated URL 2018-05-13 23:12:59 -04:00
Paul Beckingham
d81fb1d17f Recurrence: Relocate nag function out of the way 2018-05-13 23:11:39 -04:00
Paul Beckingham
66e3dc8218 TW-1903: grammar error -- There are 1 local changes.
- Thanks to Eric Hymowitz.
2018-05-13 23:10:59 -04:00
Paul Beckingham
5a1b069b73 CmdHistory: Corrected date label justification 2018-05-13 23:10:24 -04:00
Paul Beckingham
71ca9e8c4c Tests: Added WAITING tests 2018-05-13 23:10:06 -04:00
Paul Beckingham
9078ce5976 Tests: Added UNTIL tests 2018-05-13 23:09:05 -04:00
Paul Beckingham
91b45925e9 Tests: Added SCHEDULED tests 2018-05-13 23:08:10 -04:00
Paul Beckingham
45dda0c9fd Tests: Added READY tests 2018-05-13 23:08:02 -04:00
Paul Beckingham
79fc4f2d47 Tests: Made history tests independent of TZ 2018-05-13 23:07:53 -04:00
Paul Beckingham
0d6fee4053 Tests: Fixed bad regexes 2018-05-13 23:07:40 -04:00
Paul Beckingham
1bb34cb165 Tests: Fixed bad duplicate class/method name 2018-05-13 23:07:29 -04:00
Paul Beckingham
fdc37c037f CmdHistory: Formatting 2018-05-13 23:07:19 -04:00
Paul Beckingham
7490663d9e CmdHistory: Fixed bug where all strategies were rendered in the wrong width 2018-05-13 23:07:01 -04:00
Paul Beckingham
0b4fa9472d Tests: Fixed spaing issue in history test 2018-05-13 23:06:49 -04:00
Paul Beckingham
203ee9f1c2 CmdHistory: Set no-wrap for ghistory output 2018-05-13 23:06:39 -04:00
Paul Beckingham
3b97209663 CmdHistory: Removed table header coloring which is handled elsewhere 2018-05-13 23:06:30 -04:00
Paul Beckingham
2929c46d68 CmdHistory: Formatting 2018-05-13 23:06:19 -04:00
Paul Beckingham
f640dbb34e CmdHistory: Formatting 2018-05-13 23:06:06 -04:00
Paul Beckingham
315c455314 CmdSummary: Set no-wrap for progress bar column 2018-05-13 23:05:58 -04:00
Paul Beckingham
9295fa49e4 libshared: Updated to f1a3cd6bfabfb083fe3c26f580a15c0d60a92ee9 2018-05-13 23:05:43 -04:00
Paul Beckingham
8f2059a4c4 util: Removed unused strippedLength() function 2018-05-13 23:05:35 -04:00
Paul Beckingham
129fea0a76 Tests: Removed strippedLength() tests 2018-05-13 23:05:22 -04:00
Tomas Babej
dd1633f453 Remove unused auxiliary script task_functions.sh
The definitions contained in this file were used only by the already
removed 'context' bash script, see: fc6507803b
2018-05-13 23:05:09 -04:00
Paul Beckingham
a9ff077046 calc: Uses same configuration setting for Datetime/Duration as task 2018-05-13 23:04:57 -04:00
Paul Beckingham
2949a7e86a Tests: Removed taskd group features from test framework 2018-05-13 23:04:47 -04:00
Paul Beckingham
b9699bb93e CmdUDAs: Table headers consistent 2018-05-13 23:04:30 -04:00
Paul Beckingham
1f9bd897a7 CmdTimesheet: Table headers consistent 2018-05-13 23:04:19 -04:00
Paul Beckingham
c1445b3859 CmdTags: Table headers consistent 2018-05-13 23:04:10 -04:00
Paul Beckingham
44b3082234 CmdSummary: Table headers consistent 2018-05-13 23:04:02 -04:00
Paul Beckingham
3442e17f83 CmdStats: Table headers consistent 2018-05-13 23:03:46 -04:00
Paul Beckingham
5d3f97819b CmdShow: Table headers consistent 2018-05-13 23:03:36 -04:00
Paul Beckingham
9218462477 CmdReports: Table headers consistent 2018-05-13 23:03:27 -04:00
Paul Beckingham
4c802a6ff7 CmdProjects: Table headers consistent 2018-05-13 23:03:19 -04:00
Paul Beckingham
35f4681929 CmdInfo: Table headers consistent 2018-05-13 23:03:10 -04:00
Paul Beckingham
943b73b287 CmdHistory: Formatting 2018-05-13 23:02:56 -04:00
Paul Beckingham
15da5fc702 CmdHistory: Table headers consistent 2018-05-13 23:02:45 -04:00
Paul Beckingham
717e8c3be5 CmdContext: Table headers consistent 2018-05-13 23:02:36 -04:00
Paul Beckingham
d6b989c837 CmdCommands: Table headers consistent 2018-05-13 23:02:29 -04:00
Paul Beckingham
6703992cf3 CmdColumns: Table headers consistent 2018-05-13 23:02:16 -04:00
Paul Beckingham
412e804b93 CmdCalendar: Table headers consistent 2018-05-13 23:02:07 -04:00
Paul Beckingham
b162748e26 TDB2: Table headers consistent 2018-05-13 23:01:57 -04:00
Paul Beckingham
b6d65a434b util: Added helper function to properly manage table header color/underline 2018-05-13 23:01:45 -04:00
Paul Beckingham
78922d8433 Tests: Disabled ambiguous test (matching libshared) 2018-05-13 23:01:25 -04:00
Paul Beckingham
14474170f0 CmdInfo: Fixed header underline problem 2018-05-13 23:01:16 -04:00
Paul Beckingham
23c6950692 Tests: Syntax error in Python that went unnoticed 2018-05-13 23:01:00 -04:00
Paul Beckingham
55ba3b11cb libshared: Updated to 9a05fb5040008aa5f2c95e7ad060aa249367fe92 2018-05-13 23:00:40 -04:00
Paul Beckingham
67dc65a67d Tests: Lexer tests now stable with Datetime/duration features disabled 2018-05-13 23:00:30 -04:00
Paul Beckingham
70ce4eef7e Context: Selects Datetime/Duration features to match expectations 2018-05-13 23:00:19 -04:00
Paul Beckingham
82935c585a libshared: Updated to f2ac7ef9cc9f33f634f9aacd65ca9c1f828f50e3 2018-05-13 23:00:08 -04:00
Paul Beckingham
60fc24ce2b Cleanup: Formatting 2018-05-13 23:00:00 -04:00
Paul Beckingham
b3c1d94e75 libshared: Updated to b1686ad3e14c766faa3bdec3d5afe7152ace5e71 2018-05-13 22:59:47 -04:00
Paul Beckingham
2dba81e460 libshared: Updated to 6f0900d86743405f24d52f9eafe6c8e941d40ec3 2018-05-13 22:59:39 -04:00
Paul Beckingham
99f92beac9 libshared: Updated to 320f65961505019d276e5b36316bd11bdd0025b1 2018-05-13 22:59:31 -04:00
Paul Beckingham
f06ca50df9 Task: Uses named dates for YEAR virtual tag 2018-05-13 22:59:24 -04:00
Paul Beckingham
2485efa5f3 Task: Uses named dates for QUARTER virtual tag 2018-05-13 22:59:18 -04:00
Paul Beckingham
2e1e295ba4 Task: Uses named dates for MONTH virtual tag 2018-05-13 22:59:00 -04:00
Paul Beckingham
ec3e14c8f6 Task: Uses named dates to WEEK virtual tag 2018-05-13 22:58:51 -04:00
Paul Beckingham
9841ce1107 libshared: Updated to cbe3fd84a8950a42ed271a0dd8e7c4e1564b1333 2018-05-13 22:58:42 -04:00
Paul Beckingham
5c56f9008c libshared: Updated to 5bd493494fe2b1f0ab208e1edb4854316eeb5423 2018-05-13 22:58:31 -04:00
Paul Beckingham
6009e20aa4 Tests: Named date tests migrated to libshared 2018-05-13 22:58:25 -04:00
Paul Beckingham
850ef84b0b CMake: Eliminated Dates.cpp 2018-05-13 22:58:06 -04:00
Paul Beckingham
0143ced07c Task: Eliminated namedDates 2018-05-13 22:57:43 -04:00
Paul Beckingham
ce7f2e799e Tests: Eliminated old-style EOD math 2018-05-13 22:57:31 -04:00
Paul Beckingham
f030333766 Tests: Corrected lexer data type for newly-supported date types 2018-05-13 22:57:22 -04:00
Paul Beckingham
1039320a9c Tests: Eliminated namedDates 2018-05-13 22:57:12 -04:00
Paul Beckingham
d8526a388d CmdCalc: Eliminated namedDates 2018-05-13 22:56:53 -04:00
Paul Beckingham
06a78e1aff ColTypeString: Eliminated namedDates 2018-05-13 22:56:42 -04:00
Paul Beckingham
d6bbdb90b9 ColTypeNumeric: Eliminated namedDates 2018-05-13 22:56:31 -04:00
Paul Beckingham
2e34d9ffd4 ColTypeDuration: Eliminated namedDates 2018-05-13 22:56:22 -04:00
Paul Beckingham
8269a3a235 ColTypeDate: Eliminated namedDates 2018-05-13 22:56:11 -04:00
Paul Beckingham
c4b41734a9 ColTags: Eliminated namedDates 2018-05-13 22:56:02 -04:00
Paul Beckingham
23569ad5e7 ColRecur: Eliminated namedDates 2018-05-13 22:55:53 -04:00
Paul Beckingham
d390b02be5 ColProject: Eliminated namedDates 2018-05-13 22:55:45 -04:00
Paul Beckingham
fa71f846ae calc: Eliminated namedDates 2018-05-13 22:55:36 -04:00
Paul Beckingham
8f3d6c575d Filter: Eliminated namedDates 2018-05-13 22:55:27 -04:00
Paul Beckingham
d424a885bd Nibbler: Elimnated, migrated to Pig 2018-05-13 22:55:17 -04:00
Paul Beckingham
f2483538d2 Tests: Removed unused Nibbler tests 2018-05-13 22:54:58 -04:00
Paul Beckingham
15ceb61d96 ISO8601: Migrated all to Datetime/Duration 2018-05-13 22:54:39 -04:00
Paul Beckingham
c5f5b4a1f0 Tests: Eliminated ISO8601d tests 2018-05-13 22:53:10 -04:00
Paul Beckingham
c488e1d45c Tests: Eliminated ISO8601p tests 2018-05-13 22:52:31 -04:00
Paul Beckingham
6f727d3a39 Context: Eliminated ISO8601 2018-05-13 22:52:07 -04:00
Paul Beckingham
dfde9ba4b8 Variant: Migraded from ISO8601d to Datetime 2018-05-13 22:51:51 -04:00
Paul Beckingham
1571981b57 Lexer: Migrated from ISO8601p to Duration 2018-05-13 22:51:30 -04:00
Paul Beckingham
e20fb95a43 Lexer: Migrated from ISO8601d to Datetime 2018-05-13 22:51:18 -04:00
Paul Beckingham
3421f5bc18 libshared: Updated to 0dbe6c2818d4dc99f5d0089d6afb1559ed05ebf7 2018-05-13 22:51:08 -04:00
Paul Beckingham
88968af20b dependency: CPP Core Guidlines compliance 2018-05-13 22:51:02 -04:00
Paul Beckingham
42e0c17de7 sort: Greater use of auto 2018-05-13 22:50:51 -04:00
Paul Beckingham
4cbbaec833 CmdEdit: Properly captures an unmodified errno 2018-05-13 22:50:33 -04:00
Paul Beckingham
180e018a36 util: Removed unused header 2018-05-13 22:50:21 -04:00
Paul Beckingham
113358fa50 Docs: Typo 2018-05-13 22:50:11 -04:00
Paul Beckingham
37d65a6296 Docs: Typo 2018-05-13 22:50:02 -04:00
Paul Beckingham
ecd0646f41 Docs: Typo 2018-05-13 22:49:22 -04:00
Paul Beckingham
eb6cc1fa77 Docs: Typo 2018-05-13 22:47:42 -04:00
Paul Beckingham
6dffdaa471 Docs: Typo 2018-05-13 22:47:35 -04:00
Paul Beckingham
4dab89f7e6 Docs: Typo 2018-05-13 22:47:26 -04:00
Paul Beckingham
16ac2c70ab Docs: Updated build parallelism 2018-05-13 22:46:41 -04:00
Paul Beckingham
e7d9aaec4e Docs: Updated requirements 2018-05-13 22:46:28 -04:00
Paul Beckingham
2297b2d3a1 Feedback: Sync message now indicates how many local changes will be synced 2018-05-13 22:45:55 -04:00
Paul Beckingham
de8d9d88ff Lexer: Typo 2018-05-13 22:45:38 -04:00
Paul Beckingham
e2e9725812 Variant: Reduced dependence on ISO8601 2018-05-13 22:45:30 -04:00
Paul Beckingham
60e5c488ac DOM: tw.syncneeded should be 0/1, not false/true 2018-05-13 22:45:18 -04:00
Paul Beckingham
146a72b331 DOM: Partial DOM match is no longer an error 2018-05-13 22:45:07 -04:00
Paul Beckingham
65c351f50e Docs: Updated dev file 2018-05-13 22:44:47 -04:00
Paul Beckingham
18c8b41f3f Config: Eliminated 2018-05-13 22:44:21 -04:00
Paul Beckingham
f28b68661d Docs: Removed references to $TERM, which is irrelevant anyway 2018-05-13 22:43:58 -04:00
Paul Beckingham
1751bbaea6 Context: Added local config load timing 2018-05-13 22:43:45 -04:00
Paul Beckingham
b57a734625 Config: Migrated to libshared Configuration 2018-05-13 22:43:33 -04:00
Paul Beckingham
00bbca275c Config: Separated configuration from defaults 2018-05-13 22:43:06 -04:00
Paul Beckingham
e2271f9a03 Docs: Updated man page for DOM ref changes 2018-05-13 22:42:17 -04:00
Paul Beckingham
3eff3d2704 Config: Removed unused ::clear method
- This was used back when shadow file support needed to reset CLI parsing.
2018-05-13 22:42:05 -04:00
Paul Beckingham
bc517cecf3 libshared: Updated to d009b1de631c576510841593c85b257e96371b40 2018-05-13 22:41:55 -04:00
Paul Beckingham
2210528581 Docs: Updated test platform list 2018-05-13 22:41:46 -04:00
Paul Beckingham
e458c17f4f Tests: Added new DOM reference tests 2018-05-13 22:41:38 -04:00
Paul Beckingham
3a69609ffd DOM: New references: tw.syncneeded, tw.program, tw.args, tw.width, tw.height
- And deprecating context.program, context.args, context.width, context.height
2018-05-13 22:41:19 -04:00
Paul Beckingham
6641ca13a1 DOM: Typo 2018-05-13 22:40:10 -04:00
Paul Beckingham
6d1857c253 Docs: Typo 2018-05-13 22:39:55 -04:00
Paul Beckingham
29ec7d6bf3 Docs: Typo 2018-05-13 22:39:47 -04:00
Paul Beckingham
fd45b7f93f Docs: Typo 2018-05-13 22:39:40 -04:00
Paul Beckingham
3fb591714a Docs: Typo 2018-05-13 22:39:29 -04:00
Paul Beckingham
c5e0577aee Docs: Typo 2018-05-13 22:39:16 -04:00
Paul Beckingham
95ca400826 Docs: Typo 2018-05-13 22:38:34 -04:00
Paul Beckingham
5125bb840d Docs: Typo 2018-05-13 22:38:11 -04:00
Paul Beckingham
89fffbb4da Docs: Typo 2018-05-13 22:36:51 -04:00
Paul Beckingham
a190fb447d Docs: Typo 2018-05-13 22:36:42 -04:00
Paul Beckingham
06f91ed4b9 Docs: Typo 2018-05-13 22:36:33 -04:00
Paul Beckingham
187ae4b938 Docs: Update for testing flod2 2018-05-13 22:36:20 -04:00
Paul Beckingham
a1abc46138 TW-1885: Task Sync does not send TLS SNI headers
- Thanks to Dan Callahan.
2018-05-13 22:36:10 -04:00
Tomas Babej
5c243b6c4c TLSClient: Improve diagnostics
Task now correctly distinguishes the situation where CA file is present,
but not valid in some sense (empty file, not valid PEM, ..). In this
case the gnutls_certificate_set_x509_trust_file returns 0, as the number
of certificates detected in the file.

The method returns negative numbers for other errors, such as the CA
file itself missing.

Also clarify that when validating client cert/key pair, each of them can
be the source of the problem, not only the cliet certificate file.
2018-05-13 22:35:42 -04:00
Tomas Babej
4f28f26626 TLSClient: Respect 'allow all' and 'ignore hostname' trust settings 2018-05-13 22:35:18 -04:00
Tomas Babej
0907fbf906 style: Remove doubled spaces in the error message 2018-05-13 22:35:04 -04:00
Tomas Babej
4a27ba8bce TLSClient: Free error data after extracting error message 2018-05-13 22:34:53 -04:00
Tomas Babej
f2177e1254 docs: Update the build toolchain requirements 2018-05-13 22:34:41 -04:00
Tomas Babej
be4ca80842 build: Fix linking problem on non-OS-X platforms 2018-05-13 22:34:23 -04:00
Federico Hernandez
18001a9d2d Mentioned cmake handling of submodule in DEVELOPER file 2018-05-13 22:34:02 -04:00
Federico Hernandez
7d2ce304c4 Mentioned cmake handling of submodule in DEVELOPER file 2018-05-13 22:33:08 -04:00
Federico Hernandez
24538da200 Handling of git submodule in cmake 2018-05-13 22:31:40 -04:00
Paul Beckingham
0a2f6caba0 TLS: Now uses SNI 2018-05-13 22:31:27 -04:00
Paul Beckingham
eb6af955c3 libshared: Updated to 6aa2b315c476bac3fdb7bf2bc259af55eee89f83 2018-05-13 22:31:15 -04:00
Paul Beckingham
dbfab0a535 Docs: Updated docs with new history/ghistory commands. 2018-05-13 22:31:02 -04:00
Lukas Barth
d2a1b9f18e Add localized strings 2018-05-13 22:30:45 -04:00
Lukas Barth
80a3f74852 Add unit tests for new history commands 2018-05-13 22:30:28 -04:00
Lukas Barth
e934065cf8 Update manpage for history commands 2018-05-13 22:30:18 -04:00
Lukas Barth
7ef0287467 Adding weekly/daily history commands 2018-05-13 22:30:09 -04:00
Paul Beckingham
5b42cb37c7 libshared: Updated to 09ddc067c8db2d19472283d037ff38d76d63eff8 2018-05-13 22:29:47 -04:00
Paul Beckingham
a5d7f1093e CmdTimesheet: Rewrote the command
- Updated the 'timesheet' command with a more compact report that accepts a
  filter, and has a default filter showing the last four weeks of completed and
  started tasks.
2018-05-13 22:29:36 -04:00
Paul Beckingham
01c095cac7 Tests: Improved documenation in template 2018-05-13 22:28:56 -04:00
Paul Beckingham
fa654473c9 TLSClient: Removed test code 2018-05-13 22:28:46 -04:00
Paul Beckingham
1f0df70ac3 TLSClient: Typo 2018-05-13 22:28:38 -04:00
Paul Beckingham
c5024ddea4 Doc: Test change 2018-05-13 22:28:30 -04:00
Paul Beckingham
2e0c7418e4 calc: Fixed Dirk 2018-05-13 22:28:17 -04:00
Paul Beckingham
a598dc4d3f CmdCalc: 'auto infix{true}' doesn't compile 2018-05-13 22:28:04 -04:00
Paul Beckingham
77077fb5f4 Doc: Test change 2018-05-13 22:27:56 -04:00
Paul Beckingham
84f371ca51 Doc: Test change 2018-05-13 22:27:47 -04:00
Paul Beckingham
dd92f7004d Doc: Test change 2018-05-13 22:27:38 -04:00
Paul Beckingham
adea891229 Doc: Test change 2018-05-13 22:27:28 -04:00
Lukas Barth
c4f060413e Move strategies to cpp file 2018-05-13 22:26:51 -04:00
Paul Beckingham
29f2bce64d CmdModify: Code cleanup 2018-05-13 22:26:25 -04:00
Paul Beckingham
5915d3834d CmdInfo: Code cleanup 2018-05-13 22:26:01 -04:00
Paul Beckingham
8f7ec80666 CmdImport: Code cleanup 2018-05-13 22:25:46 -04:00
Paul Beckingham
0a6d606342 CmdIDs: Code cleanup 2018-05-13 22:25:32 -04:00
Paul Beckingham
24882e4ce5 CmdHistory: Code cleanup 2018-05-13 22:25:21 -04:00
Paul Beckingham
595fcef9bb CmdHelp: Code cleanup 2018-05-13 22:25:08 -04:00
Paul Beckingham
98fd46549c CmdEdit: Code cleanup 2018-05-13 22:25:00 -04:00
Paul Beckingham
45ecb72c16 CmdDuplicate: Code cleanup 2018-05-13 22:24:43 -04:00
Paul Beckingham
b5aadd0899 CmdDone: Code cleanup 2018-05-13 22:24:29 -04:00
Paul Beckingham
acd61f14fd CmdDiagnostics: Code cleanup 2018-05-13 22:24:11 -04:00
Paul Beckingham
613911dc10 CmdDenotate: Code cleanup 2018-05-13 22:23:56 -04:00
Paul Beckingham
24d5be3e14 CmdDelete: Code cleanup 2018-05-13 22:23:40 -04:00
Paul Beckingham
cd4e406dc9 CmdCustom: Code cleanup 2018-05-13 22:23:22 -04:00
Paul Beckingham
6671861e54 CmdCount: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
bc2b8cca52 CmdConfig: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
0aa7b4c3e3 CmdCommands: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
9e28c62730 CmdCalendar: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
5806cddfd3 CmdColumns: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
6828ce30f5 CmdColor: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
8ea7a88281 CmdCalc: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
a206d9405b CmdBurndown: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
4a0c6995ed CmdAttributes: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
396e923f22 CmdAppend: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
cefc287986 CmdAnnotate: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
fe24e078a4 CmdUnique: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
b2beb34e9a CmdAliases: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
087cee5425 CmdLogo: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
91132a42c8 CmdHistory: Code Cleanup
- Fixed formatting inconsistencies.
- Added Lukas to AUTHORS.
2018-05-13 22:22:42 -04:00
Lukas Barth
9bf0bf7a39 Also refactor ghistory 2018-05-13 22:22:42 -04:00
Lukas Barth
4f6c3afa3e Refactor history.monthly and history.annual 2018-05-13 22:22:42 -04:00
Paul Beckingham
f337bb6458 recur: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
e99786e726 recur: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
819dbc5285 recur: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
02efddca75 recur: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
809a1ff357 recur: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
952a299914 recur: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
67af4137af main: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
9a88084edc legacy: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
95bac8b612 Calc: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
7894e16e43 Calc: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
0c19c3cde1 Calc: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
b2188abb5d Context: Code cleanup 2018-05-13 22:22:42 -04:00
Paul Beckingham
8ace57bbef Context: Code cleanup 2018-05-13 22:22:41 -04:00
Paul Beckingham
8b766894b7 Context: Code cleanup 2018-05-13 22:22:41 -04:00
Paul Beckingham
5ecb00fe0e Context: Code cleanup 2018-05-13 22:22:41 -04:00
Paul Beckingham
04453f5f24 Context: Code cleanup 2018-05-13 22:22:41 -04:00
Paul Beckingham
dd54c26f9a Context: Code cleanup 2018-05-13 22:22:41 -04:00
Paul Beckingham
fa3abfad2e Dependency: Code cleanup 2018-05-13 22:22:41 -04:00
Paul Beckingham
28948fc7b2 Dependency: Code cleanup 2018-05-13 22:22:41 -04:00
Paul Beckingham
792a4e1445 Themes: Updated readme 2018-05-13 22:22:41 -04:00
Paul Beckingham
dc7efab0ab Docs: Updated man page 2018-05-13 22:22:41 -04:00
Paul Beckingham
899547dcc8 Docs: Updated exposition 2018-05-13 22:22:41 -04:00
Paul Beckingham
728390b6e5 Color: Now uses libshared 2018-05-13 22:22:41 -04:00
Paul Beckingham
ffb7f94e2a Docs: Updated compiler version 2018-05-13 22:22:41 -04:00
Paul Beckingham
e8517e748d Docs: Removed untested platform 2018-05-13 22:22:23 -04:00
Paul Beckingham
02fde10c12 Variant: Removed uneeded header 2018-05-13 22:22:23 -04:00
Paul Beckingham
b0c60f1c08 Variant: Relocate strings 2018-05-13 22:22:23 -04:00
Paul Beckingham
9ccb83be57 PKI: Updated test_client 2018-05-13 22:22:23 -04:00
Paul Beckingham
424592b873 PKI: Updated CRL 2018-05-13 22:22:23 -04:00
Paul Beckingham
d772eb6add PKI: Updated server 2018-05-13 22:22:23 -04:00
Paul Beckingham
a9651883cd PKI: Updated client 2018-05-13 22:22:23 -04:00
Paul Beckingham
ff67f8c791 PKI: Updated CA 2018-05-13 22:22:23 -04:00
Paul Beckingham
c690a3d58d TW-1869 segmentation fault (on unusual installation)
- Thanks to Eric Hymowitz.
2018-05-13 22:22:23 -04:00
Paul Beckingham
3e7958619a TW-1877: task done, task edit, task is now pending
- Thanks to Eric Hymowitz.
2018-05-13 22:22:23 -04:00
Paul Beckingham
54c1ca0786 Docs: Updated NEWS 2018-05-13 22:22:23 -04:00
Paul Beckingham
241fbe0581 TW-1881: Missing last character(s) in Description field
- Thanks to Hubert Toullec.
2018-05-13 22:22:04 -04:00
Paul Beckingham
5ff5a5c1ae TW-1881: default.scheduled seems not to work
- Thanks to Onion.
2018-05-13 22:22:04 -04:00
Paul Beckingham
a60c373caf TW-1861: Truncated description when adding annotation
- Thanks to eezewaek.
2018-05-13 22:22:04 -04:00
Paul Beckingham
8dcf0d0c72 TW-1823: Incorrect unicode text wrapping / justifying.
- Thanks to Sergey Trofimov.
2018-05-13 22:22:04 -04:00
Paul Beckingham
ce97fd5901 TW-1827: Extract annotations from a task
- Thanks to Ryan.
2018-05-13 22:22:04 -04:00
Paul Beckingham
e71be41e72 Tests: Added debug info, which makes it look like TW-1837 it working 2018-05-13 22:22:04 -04:00
Paul Beckingham
ee49ce3165 Tests: Added TW-1837 test 2018-05-13 22:22:04 -04:00
Paul Beckingham
b21e0baa47 TW-1667: hooks: upon failure indicate which hook failed
- Thanks to Daniel Shahaf.
2018-05-13 22:22:04 -04:00
Paul Beckingham
444e16fdd2 TW-1572: Alternative approach to urgency inheritance
- Thanks to Jens Erat, Wim Schuermann.
2018-05-13 22:22:03 -04:00
Paul Beckingham
5e98ac943b TW-213: Align countdown column on boundary between number and text.
- Thanks to Eric Fluger.
2018-05-13 22:22:03 -04:00
Paul Beckingham
116d192584 libshared: Updated to 2daeeb7e6e0716ce42f7a3d0e4400aee71531d6e 2018-05-13 22:22:03 -04:00
Paul Beckingham
3ec14a8844 Docs: Updated NEWS 2018-05-13 22:22:03 -04:00
Antonio Huete Jimenez
bdd5bc90c4 task: Fix build in SunOS-like environments.
Tested in:
 - OpenIndiana 2816291
 - OmniOS bed3013
 - SmartOS 20161129T003638Z
2018-05-13 22:21:16 -04:00
Paul Beckingham
e096462005 Docs: Added Antonion to AUTHORS 2018-05-13 22:21:16 -04:00
Antonio Huete Jimenez
24ae19b8e5 Add missing cast to double 2018-05-13 22:21:16 -04:00
Paul Beckingham
61685714c6 TLS: Aligned source with Taskserver 2018-05-13 22:21:16 -04:00
Paul Beckingham
53310d1ea0 CmdDiagnostics: Uses libshared cppCompliance call 2018-05-13 22:21:16 -04:00
Paul Beckingham
12e30bf969 libshared: Updated to bfb0e90e0c94918b86dd16d8b0e05a74bab8fb75 2018-05-13 22:21:16 -04:00
Paul Beckingham
264cc7e2fe Tests: Combined two almost identical tests into one 2018-05-13 22:21:16 -04:00
Paul Beckingham
14e047e7c4 util: Migrated osName to libshared 2018-05-13 22:21:16 -04:00
Paul Beckingham
f5bcec66e5 libshared: Updated to aff911bd080a05e5e12a240e13adb27f435b5bb2 2018-05-13 22:21:16 -04:00
Paul Beckingham
9dd2365485 docs: Add missing submodule init step to the DEVELOPER file 2018-05-13 22:21:16 -04:00
Paul Beckingham
bb45ed3fce Columns: Removed redundant format checking 2018-05-13 22:20:50 -04:00
Paul Beckingham
a951332367 Columns: Attribute objects properly delegate to Column::setStyle to validate formats 2018-05-13 22:20:50 -04:00
Paul Beckingham
f8578ecc28 Columns: Consistency 2018-05-13 22:20:50 -04:00
Paul Beckingham
8c0bfb030a Task: Improved method signature 2018-05-13 22:20:50 -04:00
Paul Beckingham
04043d267f Task: Improved method signature 2018-05-13 22:20:50 -04:00
Paul Beckingham
7e629ef30a Task: Improved method signature 2018-05-13 22:20:50 -04:00
Paul Beckingham
fab2979b87 Task: Improved method signature 2018-05-13 22:20:50 -04:00
Paul Beckingham
6c9660aee8 Task: Renamed ::getUDAOrphans to ::getUDAOrphanUUIDs 2018-05-13 22:20:50 -04:00
Paul Beckingham
fdcb084df6 ColString: Removed obsolete column for ViewText 2018-05-13 22:20:50 -04:00
Paul Beckingham
5fb7b24011 CmdCommands: Removed obsolete include 2018-05-13 22:20:50 -04:00
Paul Beckingham
1fa467aa9f ColUDA: Removed redundant code 2018-05-13 22:20:50 -04:00
Paul Beckingham
0fc6b46c4c ColTags: Removed redundant code 2018-05-13 22:20:50 -04:00
Paul Beckingham
e18b4b2063 ColRecur: Removed redundant code 2018-05-13 22:20:50 -04:00
Paul Beckingham
f4b2589149 ColID: Documented ID 0 case 2018-05-13 22:20:50 -04:00
Paul Beckingham
d99eb3c970 ColDepends: Removed redundant code 2018-05-13 22:20:50 -04:00
Paul Beckingham
3fa0e7c1ad ColTags: Corrected use of _name 2018-05-13 22:20:50 -04:00
Paul Beckingham
92e289cb3d ColStart: Removed redundant code 2018-05-13 22:20:50 -04:00
Paul Beckingham
0e4f11afc5 ColRecur: Corrected use of _name 2018-05-13 22:20:50 -04:00
Paul Beckingham
49d5a16db3 ColRecur: Added _modifiable 2018-05-13 22:20:50 -04:00
Paul Beckingham
33d7ea6569 ColMask: Corrected use of _name 2018-05-13 22:20:50 -04:00
Paul Beckingham
b55ef724f6 ColIMask: Corrected use of _name 2018-05-13 22:20:50 -04:00
Paul Beckingham
6057ecc83a ColEntry: Added _modifiable 2018-05-13 22:20:50 -04:00
Paul Beckingham
0150df0b05 ColDue: Added _modifiable 2018-05-13 22:20:50 -04:00
Paul Beckingham
df8e951324 ColDescription: Added _modifiable 2018-05-13 22:20:50 -04:00
Paul Beckingham
e2d9ae379b ColUDA: Removed redundant code 2018-05-13 22:20:50 -04:00
Paul Beckingham
a2684a6a12 ColUDA: Added _modifiable 2018-05-13 22:20:50 -04:00
Paul Beckingham
b8641d7d5e ColUUID: Removed unnecessary header 2018-05-13 22:20:50 -04:00
Paul Beckingham
14b632f1a5 ColUrgency: Marked column as unmodifiable 2018-05-13 22:20:50 -04:00
Paul Beckingham
7470af24a9 ColWait: Formatting cleanup 2018-05-13 22:20:50 -04:00
Paul Beckingham
b45e226db9 ColDepends: Corrected use of _name 2018-05-13 22:20:50 -04:00
Paul Beckingham
e1e21f30fe ColUntil: Formatting cleanup 2018-05-13 22:20:50 -04:00
Paul Beckingham
29e4b21a8b ColScheduled: Fixed bug where the wrong column label was used 2018-05-13 22:20:50 -04:00
Paul Beckingham
19e5ed6313 ColScheduled: Formatting cleanup 2018-05-13 22:20:50 -04:00
Paul Beckingham
a91cd72829 ColType*: Push the ::validate and ::modify methods down from Column 2018-05-13 22:20:50 -04:00
Paul Beckingham
56530a1f24 Improved certificate validation diagnostics
- Thanks to Jelle van der Waa.
2018-05-13 22:20:50 -04:00
Paul Beckingham
daabfcaf91 Tests: Fixed test harness for Python 3.x.
- Thanks to jrabbit.
2018-05-13 22:19:56 -04:00
Paul Beckingham
97400df68d Config: Changed to 0/1 boolean values for the defaults.
- Deprecated use of alternate Boolean configuration settings. Use values "0" for
  off, and "1" for on. Avoid used of "on", "off", "true", "t", "false", "f",
  "yes", "y", "no", "n".
2018-05-13 22:19:33 -04:00
Paul Beckingham
79ffa53ace Docs: Added Ran Benita 2018-05-13 22:18:18 -04:00
Paul Beckingham
25e326c55c Docs: Added QUARTER virtual tag 2018-05-13 22:18:03 -04:00
Paul Beckingham
5dfc367420 Task: Corrected false-positive warning about relative dates 2018-05-13 22:17:46 -04:00
Tomas Babej
e1deef327f NEWS: Deprecate new-uuid verbosity option 2018-05-13 22:17:46 -04:00
Paul Beckingham
7747cf07e7 L10N: Fixed ambiguity in the esp-ESP localization
- Thanks to Fidel Mato.
2018-05-13 22:17:23 -04:00
Paul Beckingham
5fc5fbc8e7 Task: Deprecated the 'DUETODAY' virtual tag, which is a synonym for the 'TODAY'
virtual tag.

- Thanks to Tomas Babej
2018-05-13 22:15:37 -04:00
Lynoure Braakman
8470763c31 juhannus as an alternative name for midsommarafton 2018-05-13 22:15:12 -04:00
Tomas Babej
546357662f TW-1788: Closing a reopened task does not update the end time
- Thanks to Ralph Bean.
2018-05-13 22:14:50 -04:00
Tomas Babej
5f8de9fd2c TW-1772: Implementation of circular dependency detection is inefficient
- Thanks to Michael Meier.
2018-05-13 22:14:50 -04:00
Tomas Babej
1264ffa4b4 docs: Update ChangeLog and NEWS 2018-05-13 22:14:24 -04:00
Paul Beckingham
35421403cf TD-64: sync conflict deleted all annotations of the task
- Thanks to Markus Beppler, Konstantin Vorobyev.
2018-05-13 22:14:24 -04:00
Paul Beckingham
13b8283666 Cleanup: Removed deprecated 'alias._query' setting 2018-05-13 22:13:55 -04:00
Federico Hernandez
1016dd4a40 Bumped documentation to 2.6.0 2018-05-13 22:10:48 -04:00
Paul Beckingham
88516acdaa Copyright update 2018-05-13 20:50:26 -04:00
Paul Beckingham
ea0fa20579 TW-1878: uuids subcommand produces a space-delimited list, not comma-delimited
- Thanks to Scott Kostyshak.
2018-05-13 20:48:31 -04:00
Paul Beckingham
778d2af36e Config: 'debug.tls' was missing from 'show' command 2018-05-13 20:48:19 -04:00
Paul Beckingham
934f6aeada TW-1855: "Well-known" CA certificates not properly auto-loaded
- Thanks to Flavio Poletti.
2018-05-13 20:48:09 -04:00
Paul Beckingham
72463f414c Improved certificate validation diagnostics
- Thanks to Jelle van der Waa.
2018-05-13 20:47:57 -04:00
Paul Beckingham
a67ce9db0e TLSClient: Added GnuTLS 3.4.6 API support
- This greatly simplifies cert validation.
2018-05-13 20:47:44 -04:00
Paul Beckingham
55854907a2 TLSClient: Corrected version number for API call 2018-05-13 20:47:24 -04:00
Paul Beckingham
304a6f7a33 TLSClient: Added handshake timeout 2018-05-13 20:47:13 -04:00
Paul Beckingham
41234c4f97 TLSClient: Commented possible need for version protection 2018-05-13 20:47:00 -04:00
Paul Beckingham
40b8aab7d4 TLSClient: Labelled GnuTLS calls with version numbers 2018-05-13 20:46:50 -04:00
Paul Beckingham
44522b11bc TW-1873: Specify different path to extensions/hooks directory
- Thanks to Eli.
2018-05-13 20:46:27 -04:00
Paul Beckingham
3c879e868a Docs: Updated dev docs 2018-05-13 20:46:08 -04:00
Paul Beckingham
c64e019f29 recur: Migrated from ISO8601d to Datetime 2018-05-13 20:45:52 -04:00
Paul Beckingham
afe6bdbfb3 Context: Migrated from ISO8601d to Datetime 2018-05-13 20:45:33 -04:00
Paul Beckingham
73e373527f Task: Migrated from ISO8601d to Datetime 2018-05-13 20:45:24 -04:00
Paul Beckingham
d8d5b14e66 CmdHistory: Migrated from ISO8601d to Datetime 2018-05-13 20:45:02 -04:00
Paul Beckingham
70ad78d234 CmdCalendar: Migrated from ISO8601d to Datetime 2018-05-13 20:44:45 -04:00
Paul Beckingham
57f6e0c1a5 CmdBurndown: Migrated from ISO8601d to Datetime 2018-05-13 20:44:28 -04:00
Paul Beckingham
d455d2b9bf Dates: Migrated from ISO8601d to Datetime 2018-05-13 20:44:11 -04:00
Paul Beckingham
af4222d7d2 CmdTimesheet: Migrated from ISO8601d to Datetime 2018-05-13 20:43:51 -04:00
Paul Beckingham
e15bf5105c ColDescription: Migrated from ISO8601d to Datetime 2018-05-13 20:43:35 -04:00
Paul Beckingham
c3d47f02d3 rules: Migrated from ISO8601d to Datetime 2018-05-13 20:43:25 -04:00
Paul Beckingham
4c8456a86d TDB2: Migrated from ISO8601d to Datetime 2018-05-13 20:43:17 -04:00
Paul Beckingham
29300ea9e1 Config: Migrated form ISO8601d to Datetime 2018-05-13 20:43:02 -04:00
Paul Beckingham
cdac253556 ViewText: Eliminated 2018-05-13 20:42:52 -04:00
Paul Beckingham
7001e38c30 CmdSummary: Migrated from ViewText to Table 2018-05-13 20:42:15 -04:00
Paul Beckingham
6c90de1974 TDB2: Migrated from ViewText to Table 2018-05-13 20:42:00 -04:00
Paul Beckingham
17fc9e5a91 CmdHistory: Migrated from ViewText to Table 2018-05-13 20:41:39 -04:00
Paul Beckingham
cc438b4411 CmdCalendar: Migrated from ViewText to Table 2018-05-13 20:41:23 -04:00
Paul Beckingham
d8d5a15321 Tests: Broke one tests into eight, so it is clear which one fails 2018-05-13 20:41:12 -04:00
Paul Beckingham
9be1494357 CmdInfo: Added Table::forceColor 2018-05-13 20:41:02 -04:00
Paul Beckingham
2c07858bd3 CmdInfo: Migrated from ViewText to Table 2018-05-13 20:40:47 -04:00
Paul Beckingham
74e50359b5 util: Migrated obfuscateText calls to libshared 2018-05-13 20:40:34 -04:00
Paul Beckingham
31eb477a0e libshared: Updated to 6d35bef52da4b881fcfb9946dddb01f603e225c8 2018-05-13 20:40:21 -04:00
Paul Beckingham
142d097ef0 libshared: Updated to 1aa5c92f925a1eeec16639766994f2e6f70bcf8f 2018-05-13 20:40:13 -04:00
Paul Beckingham
c69dfba6bb CmdProjects: Migrated from ViewText to Table 2018-05-13 20:40:04 -04:00
Paul Beckingham
c1d4cea638 CmdCommands: Migrated from ViewText to Table 2018-05-13 20:39:54 -04:00
Paul Beckingham
245b0c58c6 CmdColumns: Migrated from ViewText to Table 2018-05-13 20:39:45 -04:00
Paul Beckingham
9042477415 CmdShow: Migrated from ViewText to Table 2018-05-13 20:39:34 -04:00
Paul Beckingham
d551dff4cf CmdTimesheet: Migrated from ViewText to Table 2018-05-13 20:39:21 -04:00
Paul Beckingham
2ec89e68ba CmdColor: Conencted rc.color to Table::forceColor 2018-05-13 20:39:10 -04:00
Paul Beckingham
ff6dcee84c CmdColor: Migrated from ViewText to Table 2018-05-13 20:39:01 -04:00
Paul Beckingham
8db15d143b CmdStats: Migrated from ViewText to Table 2018-05-13 20:38:52 -04:00
Paul Beckingham
a4c2ec0440 CmdReports: Migrated from ViewText to Table 2018-05-13 20:38:41 -04:00
Paul Beckingham
cd2fe40a59 CmdHelp: Migrated from ViewText to Table 2018-05-13 20:38:29 -04:00
Paul Beckingham
7a0707342b CmdTags: Migrated from ViewText to Table 2018-05-13 20:38:20 -04:00
Paul Beckingham
624ccd12fc CmdVersion: Migrated from ViewText to Table 2018-05-13 20:38:05 -04:00
Paul Beckingham
a79e1d65a7 libshared: Updated to c3f1919945bd370b397314dc1ec245960a401820 2018-05-13 20:37:56 -04:00
Paul Beckingham
0721aae353 L10N: Removed unused strings 2018-05-13 20:37:45 -04:00
Paul Beckingham
abac5bdf48 util: Added missing include 2018-05-13 20:37:08 -04:00
Paul Beckingham
b463c56c93 Context: Removed unused class global 2018-05-13 20:36:56 -04:00
Paul Beckingham
2fb589b131 CmdStats: Converted from ISO8601 to Datetime/Duration 2018-05-13 20:36:46 -04:00
Paul Beckingham
b53a585756 CmdSummary: Converted from ISO8601 to Duration 2018-05-13 20:36:19 -04:00
Paul Beckingham
6b55c54af9 CmdBurndown: Converted from ISO8601 to Duration 2018-05-13 20:36:04 -04:00
Paul Beckingham
86d3ec5cee CmdInfo: Converted from ISO8601 to Datetime/Duration 2018-05-13 20:35:54 -04:00
Paul Beckingham
d26fa9b04b ColUDA: Converted from ISO8601 to Datetime/Duration 2018-05-13 20:35:34 -04:00
Paul Beckingham
0467637500 ColRecur: Converted from ISO8601 to Duration 2018-05-13 20:35:24 -04:00
Paul Beckingham
1a4db03d5e CmdEdit: Converted from ISO8601 to Datetime/Duration 2018-05-13 20:35:12 -04:00
Paul Beckingham
28bcb7e491 ColTypeDate: Converted fomr ISO8601 to Datetime/Duration 2018-05-13 20:34:53 -04:00
Paul Beckingham
c0c476e53d DOM: Converted from ISO8601 to Datetime/Duration
- In addition fixed the week number of 2011-09-01 to 35, therefore the
  tests change also.
2018-05-13 20:34:39 -04:00
Paul Beckingham
26aa2761c0 feedback: Migrated from ISO8601 to Datetime/Duration 2018-05-13 20:34:24 -04:00
Paul Beckingham
cf4bd29d44 recur: Converted from ISO8601p to Duration 2018-05-13 20:34:05 -04:00
Paul Beckingham
12459e8c8b Task: Converted from ISO8601p to Duration 2018-05-13 20:33:53 -04:00
Paul Beckingham
43d49d17d0 sort: Converted from ISO8601p to Duration 2018-05-13 20:33:34 -04:00
Paul Beckingham
b344f95e97 Variant: Converted from ISO8601p to Duration 2018-05-13 20:33:21 -04:00
Paul Beckingham
6bfb3fab3c DOM: Migrated from Nibbler to Lexer 2018-05-13 20:33:08 -04:00
Paul Beckingham
c571f6b4fb Msg: Migrated to use libshared 2018-05-13 20:32:56 -04:00
Paul Beckingham
f684e821d4 Task: Migrated from Nibbler to Pig 2018-05-13 20:32:29 -04:00
Paul Beckingham
06f177534d libshared: Updated to 9685a22c90ca6f832748f8c71bae3cfad352bc64 2018-05-13 20:32:16 -04:00
Paul Beckingham
a6c8303839 text: Eliminated module 2018-05-13 20:32:05 -04:00
Paul Beckingham
ec84d0f372 util: Migrated optionalBlankLine from text 2018-05-13 20:31:47 -04:00
Paul Beckingham
026a8aa9a1 Tests: Eliminated empty text.t test 2018-05-13 20:31:26 -04:00
Paul Beckingham
b4e4727887 util: Migrated strippedLength from text 2018-05-13 20:31:11 -04:00
Paul Beckingham
14e3038571 util: Migrated nontrivial from text 2018-05-13 20:30:51 -04:00
Paul Beckingham
9ae171f57c util: Migrated obfuscateText from text 2018-05-13 20:30:34 -04:00
Paul Beckingham
b9f55997ae Context: GC timing correction not always needed 2018-05-13 20:30:15 -04:00
Paul Beckingham
ecd0ae1b16 libshared: Updated to dfb31a41ced0fe48d98efa2b55689201d8e19667 2018-05-13 20:29:58 -04:00
Paul Beckingham
98278eff2a Task: Corrected str_replace calls 2018-05-13 20:29:49 -04:00
Paul Beckingham
f0988b52d0 CLI2: Corrected str_replace calls 2018-05-13 20:29:38 -04:00
Paul Beckingham
4232f1a599 Task: Migrated unquoteText to Lexer::dequote 2018-05-13 20:29:26 -04:00
Paul Beckingham
8462120c0a Tests: Removed migrated autoComplete tests 2018-05-13 20:29:14 -04:00
Paul Beckingham
a79d4cb803 Tests: Removed migrated text tests 2018-05-13 20:29:00 -04:00
Paul Beckingham
8c35f0a4ce Tests: Removed migrated util tests 2018-05-13 20:28:39 -04:00
Paul Beckingham
232d266fb5 text: Removed local join/split implementation 2018-05-13 20:28:24 -04:00
Paul Beckingham
db0f8d33e1 util: Removed confirm 2018-05-13 20:27:57 -04:00
Paul Beckingham
f99fc16e14 util: Removed execute 2018-05-13 20:27:42 -04:00
Paul Beckingham
4bbb5fadb3 util: Removed formatBytes 2018-05-13 20:27:23 -04:00
Paul Beckingham
488673ea9a text: Removed replace_positional 2018-05-13 20:27:10 -04:00
Paul Beckingham
060787a5db calc: Migration to libshared 2018-05-13 20:26:57 -04:00
Paul Beckingham
8a43f4902d libhsared: migrating from local to libshared 2018-05-13 20:26:34 -04:00
Paul Beckingham
0e56abd0f9 libshared: Updated to 2af7d037559f84450fffa812829fc553498a7ae4 2018-05-13 20:25:05 -04:00
Paul Beckingham
2e06bb6561 libshared: Updated to 9473050234dd3a90bff5400a081ee54881b6b0f5 2018-05-13 20:24:56 -04:00
Paul Beckingham
3d3ad553a6 Docs: Typos in ref PDF
- Thanks to eldios.
2018-05-13 20:24:39 -04:00
Paul Beckingham
a821c886b3 Tests: Set sys.stdout as utf8 2018-05-13 20:23:05 -04:00
Paul Beckingham
b323069419 Tests: Fixed test harness for Python 3.x.
- Thanks to jrabbit.
2018-05-13 20:22:52 -04:00
Paul Beckingham
992b41b82a TLSClient: Improved C++ core guidelines 2018-05-13 20:22:37 -04:00
Paul Beckingham
3be7803d30 libshared: Updated to ce5c3414de56a2d1390893bbdc46e7116c38cd90 2018-05-13 20:22:24 -04:00
Paul Beckingham
80ea2bb51d TDB2: Made sure file exists before checking readability 2018-05-13 20:22:04 -04:00
Paul Beckingham
764ada3a17 CmdDiagnostics: Made sure file existence is checked before readability 2018-05-13 20:21:52 -04:00
Paul Beckingham
570cd3d810 Context: Eliminated load timer 2018-05-13 20:21:36 -04:00
Paul Beckingham
197f130593 Context: Eliminated render timer 2018-05-13 20:21:22 -04:00
Paul Beckingham
e3d006f867 Context: Eliminated hooks timer 2018-05-13 20:21:07 -04:00
Paul Beckingham
ae128f587d Context: Eliminated sort timer 2018-05-13 20:20:49 -04:00
Paul Beckingham
ff36a87551 Context: Eliminated commit timer 2018-05-13 20:20:35 -04:00
Paul Beckingham
14f1002680 Context: Eliminated filter timer 2018-05-13 20:20:22 -04:00
Paul Beckingham
89b8c9f198 Context: Eliminated gc timer 2018-05-13 20:20:06 -04:00
Paul Beckingham
c7cb2f26ff Context: Uses inline member initialization 2018-05-13 20:19:49 -04:00
Paul Beckingham
0849501ef5 Context: Migrated to libshared Timer 2018-05-13 20:19:35 -04:00
Paul Beckingham
ced7490df6 TDB2: Migrated to libshared Timer 2018-05-13 20:19:22 -04:00
Paul Beckingham
d5cb31922e Hooks: Migrated to libshared Timer 2018-05-13 20:19:09 -04:00
Paul Beckingham
d9c72e8f58 Config: Migrated to libshared Timer 2018-05-13 20:18:56 -04:00
Paul Beckingham
a50dc97332 Context: Added ::debugTiming to wrap Timer formatting 2018-05-13 20:18:45 -04:00
Paul Beckingham
c4909ac657 libshared: Updated to 200f8c699b3011dbe49483e6343affad86e0ac96 2018-05-13 20:18:31 -04:00
Paul Beckingham
e1adf6766b Test: Removed binary output from test 2018-05-13 20:18:21 -04:00
Paul Beckingham
772c68ff62 Test: Removed binary output from test 2018-05-13 20:18:08 -04:00
Paul Beckingham
952171337c Tests: Fixed unit test that emitted unicode, that 'run_all' dislikes 2018-05-13 20:17:55 -04:00
Paul Beckingham
660cd61da7 Test: Fixed bad typo in test framework 2018-05-13 20:17:40 -04:00
Paul Beckingham
cf66c2a191 TLSClient: Improved C+ Core Guidelines compliance 2018-05-13 20:17:27 -04:00
Paul Beckingham
9a85c45bf7 TLSClient: No longer calls gnutls_global_{de,}init for 3.3.0+ 2018-05-13 20:17:12 -04:00
Tomas Babej
7ab0e9c722 l10n: Make safete valve message more explicit about completed/deleted tasks 2018-05-13 20:17:00 -04:00
Paul Beckingham
4079fb2326 Tests: Removed unnecessary imports 2018-05-13 20:16:33 -04:00
Paul Beckingham
6bf05083bd Timer: Migrated to libshared 2018-05-13 20:16:18 -04:00
Paul Beckingham
a9061dc299 ViewTask: Removed unused include 2018-05-13 20:15:54 -04:00
Paul Beckingham
161ebc1166 CmdEdit: Migrated from Nibbler to Pig 2018-05-13 20:15:41 -04:00
Paul Beckingham
6345b0c7de CmdUDAs: Migrated from ViewText to Table 2018-05-13 20:15:25 -04:00
Paul Beckingham
6ad736346f CmdContext: Migrated from ViewText to Table 2018-05-13 20:15:07 -04:00
Paul Beckingham
4792bc8c3a Dependency: Don't use string literals when character literals are needed 2018-05-13 20:14:54 -04:00
Paul Beckingham
6c62617fd0 Docs: Updated regarding TW-1857 2018-05-13 20:14:36 -04:00
inbinder
67feb5bab7 Src: rules.cpp changed Task::get to Task::has in colorizeProjectNone function 2018-05-13 20:14:23 -04:00
Paul Beckingham
814d7d69fa Cleanup: Don't use string literals when character literals are needed 2018-05-13 20:14:11 -04:00
Paul Beckingham
35e518cbc2 Cleanup: Don't use string literals when character literals are needed 2018-05-13 20:11:49 -04:00
Paul Beckingham
99a7cfceac libshared: Updated to d84d1bc70b14c85af771bb5cc7299c290d5372b5 2018-05-13 20:09:37 -04:00
Paul Beckingham
1ebf75e7d0 ColScheduled: Removed unused includes 2018-05-13 20:09:29 -04:00
Paul Beckingham
b3fe15dc41 ColParent: Removed unused includes 2018-05-13 20:09:20 -04:00
Paul Beckingham
67d4510e9b ColMask: Removed unused includes 2018-05-13 20:09:09 -04:00
Paul Beckingham
7ad546504c ColIMask: Removed unused includes 2018-05-13 20:08:53 -04:00
Paul Beckingham
d9b528351c ColDue: Removed unused includes 2018-05-13 20:08:42 -04:00
Paul Beckingham
4f003cdb60 ColDescription: Don't use string literals when character literals are needed 2018-05-13 20:08:29 -04:00
Paul Beckingham
f04cc0c9e6 Build: Eliminated compiler warning 2018-05-13 20:08:05 -04:00
Paul Beckingham
1fad357f26 Docs: Removed old reference to support forums 2018-05-13 20:07:56 -04:00
Paul Beckingham
43e1a2c991 Tests: Updated to non-deprecated Boolean values 2018-05-13 20:07:43 -04:00
Paul Beckingham
2e11c3c104 Config: Changed to 0/1 boolean values for the defaults.
- Deprecated use of alternate Boolean configuration settings. Use values "0" for
  off, and "1" for on. Avoid used of "on", "off", "true", "t", "false", "f",
  "yes", "y", "no", "n".
2018-05-13 20:07:01 -04:00
Paul Beckingham
b7e71a1c3c Docs: Updated dev build instructions 2018-05-13 20:06:12 -04:00
Paul Beckingham
c5d32c58f9 TW-1778: Unicode strings are truncated in task description
- Thanks to Andrew, bjonnh, OKOMPer, Vladimir.
2018-05-13 20:06:00 -04:00
Paul Beckingham
98611888af L10N: Updated error message to not refer to only pending tasks 2018-05-13 20:05:45 -04:00
Paul Beckingham
e0aea4a5f5 Docs: Added Ran Benita 2018-05-13 20:05:33 -04:00
Ran Benita
1f2c5bfed7 Scripts: Quoted regular expression to avoid bash glob expansion
The quote is needed, otherwise it is treated as a bash glob first, which
causes trouble if there actually happens to be matching files, and
fails entirely if `shopt -s failglob` is set.
2018-05-13 20:05:19 -04:00
Paul Beckingham
04c068e514 Docs: ChangeLog had wrong bug id 2018-05-13 20:05:08 -04:00
Paul Beckingham
555dc98f5b Tests: Removed redundant FS tests 2018-05-13 20:04:55 -04:00
Paul Beckingham
61763f278f libshared: Integrated FS 2018-05-13 20:04:25 -04:00
Paul Beckingham
b6ef010595 DOM: Eiminated Nibbler 2018-05-13 20:03:17 -04:00
Paul Beckingham
5de313272f libshared: Added Table 2018-05-13 20:03:06 -04:00
Paul Beckingham
d0251642bc Tests: Removed redundant utf8 tests 2018-05-13 20:02:56 -04:00
Paul Beckingham
1ca91b9e0c libshared: Integrated utf8, wcwidth 2018-05-13 20:02:39 -04:00
Paul Beckingham
9a63bd5d6f Tests: Removed redundant listt tests 2018-05-13 20:02:03 -04:00
Paul Beckingham
a7900205e5 Tests: Removed redundant format tests 2018-05-13 20:01:45 -04:00
Paul Beckingham
dbb22f506d Tests: Removed JSON tests 2018-05-13 20:01:27 -04:00
Paul Beckingham
3cf4f337e7 Git: Now ignores liblibshared.a 2018-05-13 20:00:14 -04:00
Paul Beckingham
22baaecd14 libshared: Integrated JSON 2018-05-13 19:59:53 -04:00
Paul Beckingham
db182f4612 Tests: Removed RX tests 2018-05-13 19:59:09 -04:00
Paul Beckingham
d33a62ffa6 libshared: Integrated the submodule
- Integrated RX.
2018-05-13 19:58:52 -04:00
Paul Beckingham
83ddb3f99f libshared: Added libshared 2018-05-13 19:58:05 -04:00
Paul Beckingham
35ab335cb2 Docs: Removed one suggestion for reporting bugs 2018-05-13 19:57:40 -04:00
Paul Beckingham
395329fb6c TW-1820: Install with -DLANGUAGE=2 flag not work.
- Thanks to E. Manuel Cerr'on Angeles
2018-05-13 19:57:25 -04:00
Paul Beckingham
1efeea3884 L10N: Removed unused strings 2018-05-13 19:57:10 -04:00
Tomas Babej
54aaac9964 TW-61: Extract only tasks with annotations
- Thanks to Aikido Guy.
- Note: This is just bookkeeping commit, the solution (+ANNOTATED
  virtual tag) is present since 2.3.0.
2018-05-13 19:56:42 -04:00
Paul Beckingham
071adeeba4 TW-1813: Range filter doesn't work
- Thanks to george js.
2018-05-13 19:56:11 -04:00
Paul Beckingham
6358b22289 Docs: Added QUARTER virtual tag 2018-05-13 19:55:52 -04:00
Paul Beckingham
edeac7e6a2 Task: Made better use of ::sameN methods 2018-05-13 19:55:06 -04:00
Paul Beckingham
62944cdf6f Task: Added QUARTER virtual tag 2018-05-13 19:54:52 -04:00
Paul Beckingham
8e8e0201f0 Tests: Added ::sameQuarter tests 2018-05-13 19:54:39 -04:00
Paul Beckingham
0820549b4c ISO8601: Added ::sameQuarter 2018-05-13 19:54:22 -04:00
Paul Beckingham
c99754391f Tests: Added 'w' dateformat test 2018-05-13 19:54:06 -04:00
Paul Beckingham
271d55506a TW-1807: dateformat lacks a flag to display day of week
- Thanks to Ellington Santos.
2018-05-13 19:53:53 -04:00
Paul Beckingham
bac71c7670 TW-1806: project:ide is not allowed
- Thanks to Slaven ʙanovic.
2018-05-13 19:53:33 -04:00
Paul Beckingham
0683e14777 Cleanup: Removed debug output 2018-05-13 19:53:03 -04:00
Paul Beckingham
7d2d06dbcd Task: Corrected false-positive warning about relative dates 2018-05-13 19:48:00 -04:00
Paul Beckingham
038126d59c ColTypeDate: Fixed countdown format only showing values in the past 2018-05-13 19:47:45 -04:00
Paul Beckingham
f29583d81d util: Corrected comment 2018-05-13 19:47:17 -04:00
Tomas Babej
a7153a082f NEWS: Deprecate new-uuid verbosity option 2018-05-13 19:47:04 -04:00
Paul Beckingham
079e2f3008 L10N: Fixed ambiguity in the esp-ESP localization
- Thanks to Fidel Mato.
2018-05-13 19:46:50 -04:00
Paul Beckingham
c6e190118f Tests: Removed broken test
- It was not only broken between easter and midsommarafton, but just performing
  an additional comparison. Not needed.
2018-05-13 19:46:28 -04:00
Paul Beckingham
ea2faa0607 TW-1795: Calendar underline on Day padding
- Thanks to Renato Alves.
2018-05-13 19:44:59 -04:00
Paul Beckingham
4395818e72 CMake: Added snotty comment about CMake bullshit 2018-05-13 19:44:41 -04:00
Paul Beckingham
dde7e6781d Tests: Wrong test count causes unexpected 'green' in test results 2018-05-13 19:44:19 -04:00
Paul Beckingham
300e7e125e cmake: Use the CXXSniffer 2018-05-13 19:43:55 -04:00
Tomas Babej
8dfd71ccc6 TW-1792: The info command uses '0' to reference dependencies on non-pending tasks
- Thanks to Paul Beckingham for providing screenshots capturing the bug.
2018-05-13 19:42:41 -04:00
Tomas Babej
084383a644 feedback: Use task identifiers instead of IDs
During construction of a feedback string for a dependency change,
a list of IDs of the dependencies was used. However, if the tasks
being referred to are already deleted / completed, their respective
IDs are all 0s.

Use shortened UUIDs in such case.
2018-05-13 19:32:53 -04:00
Paul Beckingham
1ebc8034b4 TW-1791: taskrc(5) manpage: spurious "pri." in rule.precedence.color
- Thanks to Sebastien Badia.
2018-05-13 19:32:30 -04:00
Paul Beckingham
81ac8e2be9 Tests: Updated test harness 2018-05-13 19:31:31 -04:00
Paul Beckingham
c44900bf8f Task: Deprecated the 'DUETODAY' virtual tag, which is a synonym for the 'TODAY'
virtual tag.

- Thanks to Tomas Babej
2018-05-13 19:31:14 -04:00
Lynoure Braakman
ea8a499769 juhannus as an alternative name for midsommarafton 2018-05-13 19:30:52 -04:00
Paul Beckingham
7f91e014a0 Tests: Typo in test 2018-05-13 19:30:28 -04:00
Tom Sydney Kerckhove
6d6bdebb57 Docs: fixed inconsistency in the spelling of CMake 2018-05-13 19:30:12 -04:00
Tomas Babej
1980df89c0 TW-1788: Closing a reopened task does not update the end time
- Thanks to Ralph Bean.
2018-05-13 19:29:54 -04:00
Tomas Babej
c42a73d572 tests: Add test for TW-1788 2018-05-13 19:29:41 -04:00
Tomas Babej
8a50d8b6a9 validate: Pending tasks cannot have end attribute set 2018-05-13 19:29:12 -04:00
Tomas Babej
75403c0ec1 TW-1772: Implementation of circular dependency detection is inefficient
- Thanks to Michael Meier.
2018-05-13 19:28:57 -04:00
Tomas Babej
726c31f8de dependencyIsCircular: Do not visit one node multiple times 2018-05-13 19:28:43 -04:00
Tomas Babej
dbec3ad33f l10n: Propagate the purge-related strings into language files 2018-05-13 19:26:54 -04:00
Tomas Babej
3cb974de49 Docs: Update ChangeLog and NEWS 2018-05-13 19:26:31 -04:00
Tomas Babej
75b220dbc4 docs: Document new purge command 2018-05-13 19:25:38 -04:00
Tomas Babej
cae0f15245 tests: Expand test cases for purge command 2018-05-13 19:25:26 -04:00
Tomas Babej
46a36a10a5 tests: The purge command now requires confirmation 2018-05-13 19:25:08 -04:00
Tomas Babej
2467200a3b CmdPurge: Handle child tasks of recurrence templates 2018-05-13 19:24:53 -04:00
Tomas Babej
181f098958 TDB2: Fix wrong comment 2018-05-13 19:24:32 -04:00
Tomas Babej
3e65c3af5e CmdPurge: Simplify implementation 2018-05-13 19:24:21 -04:00
Tomas Babej
c04bdc48aa CmdPurge: Move dependency handling into separate method 2018-05-13 19:23:59 -04:00
Tomas Babej
894eb3ab79 CmdPurge: Prompt before purging a task 2018-05-13 19:23:40 -04:00
Paul Beckingham
58cee899b0 L10N: Propagated new strings to all LANGS 2018-05-13 19:23:14 -04:00
Paul Beckingham
1091cc23af Docs: Added MAKEFLAGS example 2018-05-13 19:22:50 -04:00
Tomas Babej
233d8e3ebf tests: Add coverage for purge command 2018-05-13 19:22:40 -04:00
Tomas Babej
ec1a7b4b40 DEVELOPER: Use multiple jobs during make 2018-05-13 19:22:17 -04:00
Tomas Babej
ffce61da4b CmdPurge: Require GC run prior to execution
Since TDB2::purge method allows purging of the tasks only
on competed.data file, we need to make sure that all the tasks
that were supposed to be moved to completed.data have been
moved - in other words, we need to run GC.

This allows for diract usage of purge after delete, that is:

$ task <filter> delete
$ task <filter> purge

working as expected.
2018-05-13 19:21:56 -04:00
Tomas Babej
909b2e2713 CmdPurge: Remove purged tasks from dependencies 2018-05-13 19:21:34 -04:00
Tomas Babej
70a0e256b0 CmdPurge: Add initial implementation 2018-05-13 19:21:14 -04:00
Tomas Babej
f10a3d6232 TDB2: Add capability to purge tasks out of data files 2018-05-13 19:20:42 -04:00
Paul Beckingham
cbdd04e506 CmdDiagnostics: Typo 2018-05-13 19:19:52 -04:00
Paul Beckingham
bf4b08efd2 TW-1741: Warning "ignoring return value of ‘int ftruncate" while doing make on xubuntu15.10
- Thanks to Sunil Joshi.
2018-05-13 19:13:20 -04:00
Paul Beckingham
2980f5d3ce TD-64: sync conflict deleted all annotations of the task
- Thanks to Markus Beppler, Konstantin Vorobyev.
2018-05-13 19:12:48 -04:00
Paul Beckingham
677c2e87b5 calc: Uses osName() to reduce string literals 2018-05-13 19:12:07 -04:00
Paul Beckingham
48167f53eb Cleanup: Converted all sprintf to snprintf 2018-05-13 19:11:52 -04:00
Paul Beckingham
9e5a0f0e61 Rules: Improved use of 'const' and 'auto' 2018-05-13 19:10:32 -04:00
Paul Beckingham
abefdd506c Cleanup: Removed redundant processing of OS name 2018-05-13 19:10:06 -04:00
Paul Beckingham
88bd2fc9e2 Context: Combined interactive.cpp and Context.cpp 2018-05-13 19:09:34 -04:00
Paul Beckingham
aa0db81300 Cleanup: Removed deprecated alias._query setting 2018-05-13 19:01:45 -04:00
Paul Beckingham
a12fb177e2 Bumped ref page to 2.5.2 2018-05-13 18:58:27 -04:00
Paul Beckingham
2d77ad8aab Build: Bumped version to 2.5.2 2018-05-13 18:55:24 -04:00
Paul Beckingham
9486eb2fde Docs: Updated for 2.5.2 2018-05-13 18:48:42 -04:00
69 changed files with 1225 additions and 503 deletions

View File

@@ -9,9 +9,6 @@ jobs:
- name: "Centos 8"
runner: ubuntu-latest
dockerfile: centos8
- name: "Fedora 31"
runner: ubuntu-latest
dockerfile: fedora31
- name: "Fedora 32"
runner: ubuntu-latest
dockerfile: fedora32
@@ -21,6 +18,9 @@ jobs:
- name: "Fedora 34"
runner: ubuntu-latest
dockerfile: fedora34
- name: "Fedora 35"
runner: ubuntu-latest
dockerfile: fedora35
- name: "Debian Testing"
runner: ubuntu-latest
dockerfile: debiantesting
@@ -33,9 +33,12 @@ jobs:
- name: "Ubuntu 21.04"
runner: ubuntu-latest
dockerfile: ubuntu2104
- name: "OpenSUSE 15.0"
- name: "Ubuntu 21.10"
runner: ubuntu-latest
dockerfile: opensuse1500
dockerfile: ubuntu2110
- name: "OpenSUSE 15"
runner: ubuntu-latest
dockerfile: opensuse15
- name: "Archlinux Base (Rolling)"
runner: ubuntu-latest
dockerfile: arch

View File

@@ -9,7 +9,7 @@ set (HAVE_CMAKE true)
project (task)
include (CXXSniffer)
set (PROJECT_VERSION "2.6.0")
set (PROJECT_VERSION "2.6.2")
OPTION (ENABLE_WASM "Enable 'wasm' support" OFF)

View File

@@ -1,4 +1,45 @@
2.6.0 () -
------ current release ---------------------------
2.6.2 -
- TW #502 Sequence of IDs doesn't work with attribute "depends"
Thanks to Andreas Kalex and Reg for reporting.
- TW #2648 xdg-open is not available on Mac OS-X
Thanks to chapterjson for reporting.
- TW #2655 The bulk removal of depends: and tags: is ignored
Thanks to angelus2014 for reporting.
- TW #2664 Tag exclusion should be detected as invalid write context
Thanks to bentwitthold for reporting.
- TW #2671 The value of soww named date is incorrect
Thanks to Lennart Kill for reporting.
- TW #2689 Corruption of the depends attribute upon syncing with taskd 1.1.0
Thanks to Klaus Ethgen for reporting, Dusting J. Mitchell for
contributing.
- TW #2707 Assigning dependencies via ID ranges
Thanks to jaker-dotcom for reporting.
- TW #2748 Recurring report does not include parent tasks
Thanks to Klaus Ethgen for reporting.
2.6.1 (2021-10-19) - a696b6b155f9c8af87a6a496c0d298c58e6fe369
- TW #2619 Fish autocompletion fails when completing tag removal
Thanks to Alexandre Provencio for reporting, Tin Lai and Alexandre
Provencio for contributing.
- TW #2620 Old-style context definition should only be interpreted as read
context.
Thanks to bongoman and Tom Dörr for reporting.
- TW #2622 Tags and dependencies appear as orphaned UDAs.
Thanks to Scott Mcdermott for reporting.
- TW #2626 Waiting report lists deleted and/or completed tasks.
Thanks to Don Harper for reporting.
- TW #2629 New-style context definition should take precedence over old-style
even if the new-style is an empty string.
Thanks to Denis Kasak for reporting.
- TW #2632 Cannot build on Cygwin
Thanks to Michael Esemplare for contributing.
- TW #2639 Unable to use ranges for some tasks with IDs above 1000.
Thanks to Manuel Haussmann for reporting.
2.6.0 (2021-10-03) - 8174287f917a3b24c19a6601ba36fca9bdaa78c9
- TW #1654 "Due" parsing behaviour seems inconsistent
Thanks to Jim B for reporting.
@@ -134,16 +175,13 @@
Thanks to bharatvaj for contributing.
- TW #2581 Config entry with a trailing comment cannot be modified
------ current release ---------------------------
------ old releases ------------------------------
2.5.3 (2021-01-05) - 2f47226f91f0b02f7617912175274d9eed85924f
- #2375 task hangs then dies when certain tasks are present in a report
Thanks to Max Rossmannek, Tomáš Janoušek and Chad Phillips.
------ old releases ------------------------------
2.5.2 (2020-12-05) - b0c17d11639dc6e783befd89c8508f2abb9b4287
- TD-64 sync conflict deleted all annotations of the task

View File

@@ -11,7 +11,7 @@
```
$ git clone --recursive https://github.com/GothenburgBitFactory/taskwarrior taskwarrior.git
$ cd taskwarrior.git
$ git checkout 2.6.0 # Latest dev branch
$ git checkout develop # Latest dev branch
$ git submodule init # This is now done by cmake as a test
$ git submodule update # Update the libhsared.git submodule
$ cmake -DCMAKE_BUILD_TYPE=debug . # debug or release. Default: neither
@@ -144,13 +144,3 @@
is possible that a patch may be rejected because it conflicts in some way with
plans or upcoming changes. Check with us first, before sinking time and effort
into a patch.
# Current Code Base Condition
**'master' branch**:
* 2.5.3 Current release, locked.
**'2.6.0' branch**:
* Current development branch no plans yet.
---

4
NEWS
View File

@@ -39,8 +39,8 @@ New Features in Taskwarrior 2.6.0
whole units like days, e.g. 'add test due:2021-07-17' would not match
'due.before:tomorrow' (on the 16th), but would match 'due.by:tomorrow'.
- Waiting is now an entirely "virtual" concept, based on a task's
'wait' property and the current time. Task is consiered "waiting" if its
wait attribute is in the future. TaskWarrior no longer explicitly
'wait' property and the current time. Task is considered "waiting" if its
wait attribute is in the future. TaskWarrior no longer explicitly
"unwaits" a task (the wait attribute is not removed once its value is in
the past), so the "unwait' verbosity token is no longer available.
This allows for filtering for tasks that were waiting in the past

View File

@@ -1,10 +1,9 @@
<div align="center">
<img src="https://avatars.githubusercontent.com/u/36100920?s=200&u=24da05914c20c4ccfe8485310f7b83049407fa9a&v=4"></br>
[![GitHub Actions build status](https://github.com/GothenburgBitFactory/taskwarrior/workflows/tests/badge.svg?branch=2.6.0)](https://github.com/GothenburgBitFactory/taskwarrior/actions)
[![GitHub Actions build status](https://github.com/GothenburgBitFactory/taskwarrior/workflows/tests/badge.svg?branch=develop)](https://github.com/GothenburgBitFactory/taskwarrior/actions)
[![Release](https://img.shields.io/github/v/release/GothenburgBitFactory/taskwarrior)](https://github.com/GothenburgBitFactory/taskwarrior/releases/latest)
[![Release date](https://img.shields.io/github/release-date/GothenburgBitFactory/taskwarrior)](https://github.com/GothenburgBitFactory/taskwarrior/releases/latest)
![Commits since release](https://img.shields.io/github/commits-since/GothenburgBitFactory/taskwarrior/latest)
[![GitHub Sponsors](https://img.shields.io/github/sponsors/GothenburgBitFactory?color=green)](https://github.com/sponsors/GothenburgBitFactory/)
</br>
[![Twitter](https://img.shields.io/twitter/follow/taskwarrior?style=social)](https://twitter.com/taskwarrior)
@@ -64,13 +63,15 @@ For code contributions, please use pull requests, or alternately send your code
We use the following branching model:
* `master` is the stable branch. Building from here is the same as building
from the latest tarball, or installing a binary package. No development is
done on the `master` branch.
* `stable` is a branch containing the content of the latest release. Building
from here is the same as building from the latest tarball, or installing a
binary package. No development is done on the `stable` branch.
* `2.6.0` is the current development branch. All work is done here, and upon
release it will be merged to `master`. This development branch is not stable,
and should be treated accordingly. Make backups.
* `develop` is the current development branch. All work is done here, and upon
release it will be merged to `stable`. While development branch is not
stable, we utilize CI to ensure we're at least not merging improvements that
break existing tests, and hence should be relatively safe. We still recommend
making backups when using the development branch.
## Installing
@@ -85,13 +86,13 @@ There are many binary packages available, but to install from source requires:
Download the tarball, and expand it:
$ curl -O https://taskwarrior.org/download/task-2.6.0.tar.gz
$ tar xzf task-2.6.0.tar.gz
$ cd task-2.6.0
$ curl -O https://taskwarrior.org/download/task-2.6.2.tar.gz
$ tar xzf task-2.6.2.tar.gz
$ cd task-2.6.2
Or clone this repository:
$ git clone --recursive -b 2.6.0 https://github.com/GothenburgBitFactory/taskwarrior.git
$ git clone --recursive -b stable https://github.com/GothenburgBitFactory/taskwarrior.git
$ cd taskwarrior
Then build:

View File

@@ -32,6 +32,7 @@ elseif (${CMAKE_SYSTEM_NAME} STREQUAL "GNU")
set (GNUHURD true)
elseif (${CMAKE_SYSTEM_NAME} STREQUAL "CYGWIN")
set (CYGWIN true)
set (_CXX14_FLAGS "-std=gnu++17")
else (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
set (UNKNOWN true)
endif (${CMAKE_SYSTEM_NAME} MATCHES "Linux")

View File

@@ -16,14 +16,6 @@ services:
security_opt:
- label=type:container_runtime_t
tty: true
test-fedora31:
build:
context: .
dockerfile: test/docker/fedora31
network_mode: "host"
security_opt:
- label=type:container_runtime_t
tty: true
test-fedora32:
build:
context: .
@@ -48,6 +40,14 @@ services:
security_opt:
- label=type:container_runtime_t
tty: true
test-fedora35:
build:
context: .
dockerfile: test/docker/fedora35
network_mode: "host"
security_opt:
- label=type:container_runtime_t
tty: true
test-ubuntu1804:
build:
context: .
@@ -72,6 +72,14 @@ services:
security_opt:
- label=type:container_runtime_t
tty: true
test-ubuntu2110:
build:
context: .
dockerfile: test/docker/ubuntu2110
network_mode: "host"
security_opt:
- label=type:container_runtime_t
tty: true
test-debianstable:
build:
context: .
@@ -96,10 +104,10 @@ services:
security_opt:
- label=type:container_runtime_t
tty: true
test-opensuse1500:
test-opensuse15:
build:
context: .
dockerfile: test/docker/opensuse1500
dockerfile: test/docker/opensuse15
network_mode: "host"
security_opt:
- label=type:container_runtime_t

1
index.html Normal file
View File

@@ -0,0 +1 @@
Taskwarrior Docs

View File

@@ -107,7 +107,7 @@ function __fish.task.need_to_complete.attr_value
or return 1
# only start completion when there's a colon in attr_name
set -l cmd (commandline -ct)
string match -q "*:*" "$cmd[-1]"
string match -q -- "*:*" "$cmd[-1]"
end
function __fish.task.need_to_complete.command
@@ -251,13 +251,13 @@ function __fish.task.list.dates
echo -e (string replace --all -r "^|\n" "\n$user_input_numeric" $__fish_task_static_reldates | string collect)
# special cases for 1st, 2nd and 3rd, and 4-0th
set -l suffix 'th' '4th, 5th, etc.'
if string match -q "*1" $user_input_numeric
if string match -q -- "*1" $user_input_numeric
set suffix 'st' 'first'
else if string match -q "*2" $user_input_numeric
else if string match -q -- "*2" $user_input_numeric
set suffix 'nd' 'second'
else if string match -q "*3" $user_input_numeric
else if string match -q -- "*3" $user_input_numeric
set suffix 'rd' 'third'
end
end
echo -e $user_input_numeric"$suffix[1]\t$suffix[2]"
else
echo -e $__fish_task_static_dates

View File

@@ -5,7 +5,7 @@ FROM centos:8
RUN dnf update -y
RUN yum install epel-release -y
RUN dnf install python38 git gcc gcc-c++ cmake make gnutls-devel libuuid-devel libfaketime sudo man gdb -y
RUN dnf install python38 vim git gcc gcc-c++ cmake make gnutls-devel libuuid-devel libfaketime sudo man gdb -y
RUN useradd warrior
RUN echo warrior ALL=NOPASSWD:ALL > /etc/sudoers.d/warrior

View File

@@ -43,6 +43,7 @@
#include <shared.h>
#include <format.h>
#include <main.h>
#include <regex>
#ifdef HAVE_COMMIT
#include <commit.h>
@@ -115,7 +116,7 @@ std::string configurationDefaults =
"expressions=infix # Prefer infix over postfix expressions\n"
"json.array=1 # Enclose JSON output in [ ]\n"
"abbreviation.minimum=2 # Shortest allowed abbreviation\n"
"news.version= # Latest version higlights read by the user\n"
"news.version= # Latest version highlights read by the user\n"
"\n"
"# Dates\n"
"dateformat=Y-M-D # Preferred input and display date format\n"
@@ -358,9 +359,9 @@ std::string configurationDefaults =
"report.completed.context=1\n"
"\n"
"report.recurring.description=Recurring Tasks\n"
"report.recurring.labels=ID,Active,Age,D,P,Project,Tags,Recur,Sch,Due,Until,Description,Urg\n"
"report.recurring.columns=id,start.age,entry.age,depends.indicator,priority,project,tags,recur,scheduled.countdown,due,until.remaining,description,urgency\n"
"report.recurring.filter=status:pending and (+PARENT or +CHILD)\n"
"report.recurring.labels=ID,Active,Age,D,P,Parent,Project,Tags,Recur,Sch,Due,Until,Description,Urg\n"
"report.recurring.columns=id,start.age,entry.age,depends.indicator,priority,parent.short,project,tags,recur,scheduled.countdown,due,until.remaining,description,urgency\n"
"report.recurring.filter=(status:pending and +CHILD) or (status:recurring and +PARENT)\n"
"report.recurring.sort=due+,urgency-,entry+\n"
"report.recurring.context=1\n"
"\n"
@@ -474,7 +475,7 @@ int Context::initialize (int argc, const char** argv)
// [1] Load the correct config file.
// - Default to ~/.taskrc (ctor).
// - If no ~/.taskrc, use $XDG_CONFIG_HOME/task/taskrc if exists, or
// ~/.config/task/taskrc if $XDG_DATA_HOME is unset
// ~/.config/task/taskrc if $XDG_CONFIG_HOME is unset
// - Allow $TASKRC override.
// - Allow command line override rc:<file>
// - Load resultant file.
@@ -667,9 +668,13 @@ int Context::initialize (int argc, const char** argv)
rc = 4;
}
catch (const std::regex_error& e)
{
std::cout << "regex_error caught: " << e.what() << '\n';
}
catch (...)
{
error ("Unknown error. Please report.");
error ("knknown error. Please report.");
rc = 3;
}
@@ -966,16 +971,19 @@ std::string Context::getTaskContext (const std::string& kind, std::string name,
}
// Figure out the context string for this kind (read/write)
std::string contextString = config.get ("context." + name + "." + kind);
if (contextString.empty ())
std::string contextString = "";
if (! config.has ("context." + name + "." + kind) && kind == "read")
{
debug ("Specific " + kind + " context for '" + name + "' not defined. ");
if (fallback)
{
debug ("Falling back on generic.");
debug ("Trying to interpret old-style context definition as read context.");
contextString = config.get ("context." + name);
}
}
else
contextString = config.get ("context." + name + "." + kind);
debug (format ("Detected context string: {1}", contextString.empty() ? "(empty)" : contextString));
return contextString;
@@ -1320,6 +1328,12 @@ void Context::debugTiming (const std::string& details, const Timer& timer)
debug (out.str ());
}
////////////////////////////////////////////////////////////////////////////////
CurrentTask Context::withCurrentTask (const Task *task)
{
return CurrentTask(*this, task);
}
////////////////////////////////////////////////////////////////////////////////
// This capability is to answer the question of 'what did I just do to generate
// this output?'.
@@ -1421,6 +1435,19 @@ void Context::debug (const std::string& input)
debugMessages.push_back (input);
}
////////////////////////////////////////////////////////////////////////////////
CurrentTask::CurrentTask (Context &context, const Task *task)
: context {context}, previous {context.currentTask}
{
context.currentTask = task;
}
////////////////////////////////////////////////////////////////////////////////
CurrentTask::~CurrentTask ()
{
context.currentTask = previous;
}
////////////////////////////////////////////////////////////////////////////////
// vim ts=2:sw=2

View File

@@ -38,6 +38,8 @@
#include <Timer.h>
#include <set>
class CurrentTask;
class Context
{
public:
@@ -73,6 +75,9 @@ public:
void decomposeSortField (const std::string&, std::string&, bool&, bool&);
void debugTiming (const std::string&, const Timer&);
CurrentTask withCurrentTask (const Task *);
friend class CurrentTask;
private:
void staticInitialization ();
void createDefaultConfig ();
@@ -115,6 +120,25 @@ public:
long time_sort_us {0};
long time_render_us {0};
long time_hooks_us {0};
// the current task for DOM references, or NULL if there is no task
const Task * currentTask {NULL};
};
////////////////////////////////////////////////////////////////////////////////
// CurrentTask resets Context::currentTask to previous context task on destruction; this ensures
// that this context value is restored when exiting the scope where the context was applied.
class CurrentTask {
public:
~CurrentTask();
private:
CurrentTask(Context &context, const Task *previous);
Context &context;
const Task *previous;
friend class Context;
};
#endif

View File

@@ -239,22 +239,25 @@ bool getDOM (const std::string& name, Variant& value)
//
// This code emphasizes speed, hence 'id' and 'urgency' being evaluated first
// as special cases.
bool getDOM (const std::string& name, const Task& task, Variant& value)
//
// If task is NULL, then the contextual task will be determined from the DOM
// string, if any exists.
bool getDOM (const std::string& name, const Task* task, Variant& value)
{
// Special case, blank refs cause problems.
if (name == "")
return false;
// Quickly deal with the most common cases.
if (task.data.size () && name == "id")
if (task && name == "id")
{
value = Variant (static_cast<int> (task.id));
value = Variant (static_cast<int> (task->id));
return true;
}
if (task.data.size () && name == "urgency")
if (task && name == "urgency")
{
value = Variant (task.urgency_c ());
value = Variant (task->urgency_c ());
return true;
}
@@ -262,54 +265,55 @@ bool getDOM (const std::string& name, const Task& task, Variant& value)
auto elements = split (name, '.');
Task loaded_task;
// Use a lambda to decide whether the reference is going to be the passed
// decide whether the reference is going to be the passed
// "task" or whether it's going to be a newly loaded task (if id/uuid was
// given).
const Task& ref = [&]() -> const Task&
const Task* ref = task;
Lexer lexer (elements[0]);
std::string token;
Lexer::Type type;
// If this can be ID/UUID reference (the name contains '.'),
// lex it to figure out. Otherwise don't lex, as lexing can be slow.
if ((elements.size() > 1) and lexer.token (token, type))
{
Lexer lexer (elements[0]);
std::string token;
Lexer::Type type;
bool reloaded = false;
// If this can be ID/UUID reference (the name contains '.'),
// lex it to figure out. Otherwise don't lex, as lexing can be slow.
if ((elements.size() > 1) and lexer.token (token, type))
if (type == Lexer::Type::uuid &&
token.length () == elements[0].length ())
{
bool reloaded = false;
if (type == Lexer::Type::uuid &&
token.length () == elements[0].length ())
if (!task || token != task->get ("uuid"))
{
if (token != task.get ("uuid"))
{
Context::getContext ().tdb2.get (token, loaded_task);
if (Context::getContext ().tdb2.get (token, loaded_task))
reloaded = true;
}
// Eat elements[0]/UUID.
elements.erase (elements.begin ());
}
else if (type == Lexer::Type::number &&
token.find ('.') == std::string::npos)
{
auto id = strtol (token.c_str (), nullptr, 10);
if (id && id != task.id)
{
Context::getContext ().tdb2.get (id, loaded_task);
reloaded = true;
}
// Eat elements[0]/ID.
elements.erase (elements.begin ());
}
if (reloaded)
return loaded_task;
// Eat elements[0]/UUID.
elements.erase (elements.begin ());
}
else if (type == Lexer::Type::number &&
token.find ('.') == std::string::npos)
{
auto id = strtol (token.c_str (), nullptr, 10);
if (id && (!task || id != task->id))
{
if (Context::getContext ().tdb2.get (id, loaded_task))
reloaded = true;
}
// Eat elements[0]/ID.
elements.erase (elements.begin ());
}
return task;
if (reloaded)
ref = &loaded_task;
}
} ();
// The remainder of this method requires a contextual task, so if we do not
// have one, delegate to the two-argument getDOM
if (!ref)
return getDOM (name, value);
auto size = elements.size ();
@@ -318,31 +322,31 @@ bool getDOM (const std::string& name, const Task& task, Variant& value)
{
// Now that 'ref' is the contextual task, and any ID/UUID is chopped off the
// elements vector, DOM resolution is now simple.
if (ref.data.size () && size == 1 && canonical == "id")
if (size == 1 && canonical == "id")
{
value = Variant (static_cast<int> (ref.id));
value = Variant (static_cast<int> (ref->id));
return true;
}
if (ref.data.size () && size == 1 && canonical == "urgency")
if (size == 1 && canonical == "urgency")
{
value = Variant (ref.urgency_c ());
value = Variant (ref->urgency_c ());
return true;
}
// Special handling of status required for virtual waiting status
// implementation. Remove in 3.0.0.
if (ref.data.size () && size == 1 && canonical == "status")
if (size == 1 && canonical == "status")
{
value = Variant (ref.statusToText (ref.getStatus ()));
value = Variant (ref->statusToText (ref->getStatus ()));
return true;
}
Column* column = Context::getContext ().columns[canonical];
if (ref.data.size () && size == 1 && column)
if (size == 1 && column)
{
if (column->is_uda () && ! ref.has (canonical))
if (column->is_uda () && ! ref->has (canonical))
{
value = Variant ("");
return true;
@@ -350,7 +354,7 @@ bool getDOM (const std::string& name, const Task& task, Variant& value)
if (column->type () == "date")
{
auto numeric = ref.get_date (canonical);
auto numeric = ref->get_date (canonical);
if (numeric == 0)
value = Variant ("");
else
@@ -358,32 +362,32 @@ bool getDOM (const std::string& name, const Task& task, Variant& value)
}
else if (column->type () == "duration" || canonical == "recur")
{
auto period = ref.get (canonical);
auto period = ref->get (canonical);
Duration iso;
std::string::size_type cursor = 0;
if (iso.parse (period, cursor))
value = Variant (iso.toTime_t (), Variant::type_duration);
else
value = Variant (Duration (ref.get (canonical)).toTime_t (), Variant::type_duration);
value = Variant (Duration (ref->get (canonical)).toTime_t (), Variant::type_duration);
}
else if (column->type () == "numeric")
value = Variant (ref.get_float (canonical));
value = Variant (ref->get_float (canonical));
else
value = Variant (ref.get (canonical));
value = Variant (ref->get (canonical));
return true;
}
if (ref.data.size () && size == 2 && canonical == "tags")
if (size == 2 && canonical == "tags")
{
value = Variant (ref.hasTag (elements[1]) ? elements[1] : "");
value = Variant (ref->hasTag (elements[1]) ? elements[1] : "");
return true;
}
if (ref.data.size () && size == 2 && column && column->type () == "date")
if (size == 2 && column && column->type () == "date")
{
Datetime date (ref.get_date (canonical));
Datetime date (ref->get_date (canonical));
if (elements[1] == "year") { value = Variant (static_cast<int> (date.year ())); return true; }
else if (elements[1] == "month") { value = Variant (static_cast<int> (date.month ())); return true; }
else if (elements[1] == "day") { value = Variant (static_cast<int> (date.day ())); return true; }
@@ -396,15 +400,15 @@ bool getDOM (const std::string& name, const Task& task, Variant& value)
}
}
if (ref.data.size () && size == 2 && elements[0] == "annotations" && elements[1] == "count")
if (size == 2 && elements[0] == "annotations" && elements[1] == "count")
{
value = Variant (static_cast<int> (ref.getAnnotationCount ()));
value = Variant (static_cast<int> (ref->getAnnotationCount ()));
return true;
}
if (ref.data.size () && size == 3 && elements[0] == "annotations")
if (size == 3 && elements[0] == "annotations")
{
auto annos = ref.getAnnotations ();
auto annos = ref->getAnnotations ();
int a = strtol (elements[1].c_str (), nullptr, 10);
int count = 0;
@@ -430,9 +434,9 @@ bool getDOM (const std::string& name, const Task& task, Variant& value)
}
}
if (ref.data.size () && size == 4 && elements[0] == "annotations" && elements[2] == "entry")
if (size == 4 && elements[0] == "annotations" && elements[2] == "entry")
{
auto annos = ref.getAnnotations ();
auto annos = ref->getAnnotations ();
int a = strtol (elements[1].c_str (), nullptr, 10);
int count = 0;

View File

@@ -33,7 +33,7 @@
// 2017-04-22 Deprecated, use DOM::get.
bool getDOM (const std::string&, Variant&);
bool getDOM (const std::string&, const Task&, Variant&);
bool getDOM (const std::string&, const Task*, Variant&);
class DOM
{

View File

@@ -26,6 +26,7 @@
#include <cmake.h>
#include <Eval.h>
#include <DOM.h>
#include <map>
#include <time.h>
#include <Context.h>
@@ -34,8 +35,6 @@
#include <shared.h>
#include <format.h>
extern Task& contextTask;
////////////////////////////////////////////////////////////////////////////////
// Supported operators, borrowed from C++, particularly the precedence.
// Note: table is sorted by length of operator string, so searches match
@@ -101,6 +100,19 @@ static bool namedConstants (const std::string& name, Variant& value)
return true;
}
////////////////////////////////////////////////////////////////////////////////
// Support for evaluating DOM references (add with `e.AddSource(domSource)`)
bool domSource (const std::string& identifier, Variant& value)
{
if (getDOM (identifier, Context::getContext ().currentTask, value))
{
value.source (identifier);
return true;
}
return false;
}
////////////////////////////////////////////////////////////////////////////////
Eval::Eval ()
{
@@ -278,6 +290,8 @@ void Eval::evaluatePostfixStack (
Variant left = values.back ();
values.pop_back ();
auto contextTask = Context::getContext ().currentTask;
// Ordering these by anticipation frequency of use is a good idea.
Variant result;
if (token.first == "and") result = left && right;
@@ -299,10 +313,14 @@ void Eval::evaluatePostfixStack (
else if (token.first == "^") result = left ^ right;
else if (token.first == "%") result = left % right;
else if (token.first == "xor") result = left.operator_xor (right);
else if (token.first == "~") result = left.operator_match (right, contextTask);
else if (token.first == "!~") result = left.operator_nomatch (right, contextTask);
else if (token.first == "_hastag_") result = left.operator_hastag (right, contextTask);
else if (token.first == "_notag_") result = left.operator_notag (right, contextTask);
else if (contextTask) {
if (token.first == "~") result = left.operator_match (right, *contextTask);
else if (token.first == "!~") result = left.operator_nomatch (right, *contextTask);
else if (token.first == "_hastag_") result = left.operator_hastag (right, *contextTask);
else if (token.first == "_notag_") result = left.operator_notag (right, *contextTask);
else
throw format ("Unsupported operator '{1}'.", token.first);
}
else
throw format ("Unsupported operator '{1}'.", token.first);

View File

@@ -32,6 +32,8 @@
#include <Lexer.h>
#include <Variant.h>
bool domSource (const std::string&, Variant&);
class Eval
{
public:

View File

@@ -35,23 +35,6 @@
#include <format.h>
#include <shared.h>
////////////////////////////////////////////////////////////////////////////////
// Const iterator that can be derefenced into a Task by domSource.
static Task dummy;
Task& contextTask = dummy;
////////////////////////////////////////////////////////////////////////////////
bool domSource (const std::string& identifier, Variant& value)
{
if (getDOM (identifier, contextTask, value))
{
value.source (identifier);
return true;
}
return false;
}
////////////////////////////////////////////////////////////////////////////////
// Take an input set of tasks and filter into a subset.
void Filter::subset (const std::vector <Task>& input, std::vector <Task>& output)
@@ -79,7 +62,7 @@ void Filter::subset (const std::vector <Task>& input, std::vector <Task>& output
for (auto& task : input)
{
// Set up context for any DOM references.
contextTask = task;
auto currentTask = Context::getContext ().withCurrentTask(&task);
Variant var;
eval.evaluateCompiledExpression (var);
@@ -131,7 +114,7 @@ void Filter::subset (std::vector <Task>& output)
for (auto& task : pending)
{
// Set up context for any DOM references.
contextTask = task;
auto currentTask = Context::getContext ().withCurrentTask(&task);
Variant var;
eval.evaluateCompiledExpression (var);
@@ -150,7 +133,7 @@ void Filter::subset (std::vector <Task>& output)
for (auto& task : completed)
{
// Set up context for any DOM references.
contextTask = task;
auto currentTask = Context::getContext ().withCurrentTask(&task);
Variant var;
eval.evaluateCompiledExpression (var);

View File

@@ -32,8 +32,6 @@
#include <Task.h>
#include <Variant.h>
bool domSource (const std::string&, Variant&);
class Filter
{
public:

View File

@@ -1025,203 +1025,24 @@ void TDB2::show_diff (
Color color_red (Context::getContext ().color () ? Context::getContext ().config.get ("color.undo.before") : "");
Color color_green (Context::getContext ().color () ? Context::getContext ().config.get ("color.undo.after") : "");
auto before = prior == "" ? Task() : Task(prior);
auto after = Task(current);
if (Context::getContext ().config.get ("undo.style") == "side")
{
Table view = before.diffForUndoSide(after);
std::cout << '\n'
<< format ("The last modification was made {1}", lastChange.toString ())
<< '\n';
// Attributes are all there is, so figure the different attribute names
// between before and after.
Table view;
view.width (Context::getContext ().getWidth ());
view.intraPadding (2);
view.add ("");
view.add ("Prior Values");
view.add ("Current Values");
setHeaderUnderline (view);
Task after (current);
if (prior != "")
{
Task before (prior);
std::vector <std::string> beforeAtts;
for (auto& att : before.data)
beforeAtts.push_back (att.first);
std::vector <std::string> afterAtts;
for (auto& att : after.data)
afterAtts.push_back (att.first);
std::vector <std::string> beforeOnly;
std::vector <std::string> afterOnly;
listDiff (beforeAtts, afterAtts, beforeOnly, afterOnly);
int row;
for (auto& name : beforeOnly)
{
row = view.addRow ();
view.set (row, 0, name);
view.set (row, 1, renderAttribute (name, before.get (name)), color_red);
}
for (auto& att : before.data)
{
std::string priorValue = before.get (att.first);
std::string currentValue = after.get (att.first);
if (currentValue != "")
{
row = view.addRow ();
view.set (row, 0, att.first);
view.set (row, 1, renderAttribute (att.first, priorValue),
(priorValue != currentValue ? color_red : Color ()));
view.set (row, 2, renderAttribute (att.first, currentValue),
(priorValue != currentValue ? color_green : Color ()));
}
}
for (auto& name : afterOnly)
{
row = view.addRow ();
view.set (row, 0, name);
view.set (row, 2, renderAttribute (name, after.get (name)), color_green);
}
}
else
{
int row;
for (auto& att : after.data)
{
row = view.addRow ();
view.set (row, 0, att.first);
view.set (row, 2, renderAttribute (att.first, after.get (att.first)), color_green);
}
}
std::cout << '\n'
<< '\n'
<< '\n'
<< view.render ()
<< '\n';
}
// This style looks like this:
// --- before 2009-07-04 00:00:25.000000000 +0200
// +++ after 2009-07-04 00:00:45.000000000 +0200
//
// - name: old // att deleted
// + name:
//
// - name: old // att changed
// + name: new
//
// - name:
// + name: new // att added
//
else if (Context::getContext ().config.get ("undo.style") == "diff")
{
// Create reference tasks.
Task before;
if (prior != "")
before.parse (prior);
Task after (current);
// Generate table header.
Table view;
view.width (Context::getContext ().getWidth ());
view.intraPadding (2);
view.add ("");
view.add ("");
int row = view.addRow ();
view.set (row, 0, "--- previous state", color_red);
view.set (row, 1, "Undo will restore this state", color_red);
row = view.addRow ();
view.set (row, 0, "+++ current state ", color_green);
view.set (row, 1, format ("Change made {1}",
lastChange.toString (Context::getContext ().config.get ("dateformat"))),
color_green);
view.addRow ();
// Add rows to table showing diffs.
std::vector <std::string> all = Context::getContext ().getColumns ();
// Now factor in the annotation attributes.
for (auto& it : before.data)
if (it.first.substr (0, 11) == "annotation_")
all.push_back (it.first);
for (auto& it : after.data)
if (it.first.substr (0, 11) == "annotation_")
all.push_back (it.first);
// Now render all the attributes.
std::sort (all.begin (), all.end ());
std::string before_att;
std::string after_att;
std::string last_att;
for (auto& a : all)
{
if (a != last_att) // Skip duplicates.
{
last_att = a;
before_att = before.get (a);
after_att = after.get (a);
// Don't report different uuid.
// Show nothing if values are the unchanged.
if (a == "uuid" ||
before_att == after_att)
{
// Show nothing - no point displaying that which did not change.
// row = view.addRow ();
// view.set (row, 0, *a + ":");
// view.set (row, 1, before_att);
}
// Attribute deleted.
else if (before_att != "" && after_att == "")
{
row = view.addRow ();
view.set (row, 0, '-' + a + ':', color_red);
view.set (row, 1, before_att, color_red);
row = view.addRow ();
view.set (row, 0, '+' + a + ':', color_green);
}
// Attribute added.
else if (before_att == "" && after_att != "")
{
row = view.addRow ();
view.set (row, 0, '-' + a + ':', color_red);
row = view.addRow ();
view.set (row, 0, '+' + a + ':', color_green);
view.set (row, 1, after_att, color_green);
}
// Attribute changed.
else
{
row = view.addRow ();
view.set (row, 0, '-' + a + ':', color_red);
view.set (row, 1, before_att, color_red);
row = view.addRow ();
view.set (row, 0, '+' + a + ':', color_green);
view.set (row, 1, after_att, color_green);
}
}
}
Table view = before.diffForUndoPatch(after, lastChange);
std::cout << '\n'
<< view.render ()
<< '\n';

View File

@@ -30,6 +30,7 @@
#include <TLSClient.h>
#include <iostream>
#include <sstream>
#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
@@ -44,6 +45,7 @@
#include <shared.h>
#include <format.h>
#define HEADER_SIZE 4
#define MAX_BUF 16384
#if GNUTLS_VERSION_NUMBER < 0x030406
@@ -469,24 +471,15 @@ void TLSClient::send (const std::string& data)
packet[3] = l;
unsigned int total = 0;
unsigned int remaining = packet.length ();
while (total < packet.length ())
int status;
do
{
int status;
do
{
status = gnutls_record_send (_session, packet.c_str () + total, remaining); // All
}
while (errno == GNUTLS_E_INTERRUPTED ||
errno == GNUTLS_E_AGAIN);
if (status == -1)
break;
total += (unsigned int) status;
remaining -= (unsigned int) status;
status = gnutls_record_send (_session, packet.c_str () + total, packet.length () - total); // All
}
while ((status > 0 && (total += status) < packet.length ()) ||
status == GNUTLS_E_INTERRUPTED ||
status == GNUTLS_E_AGAIN);
if (_debug)
std::cout << "c: INFO Sending 'XXXX"
@@ -500,18 +493,22 @@ void TLSClient::recv (std::string& data)
{
data = ""; // No appending of data.
int received = 0;
int total = 0;
// Get the encoded length.
unsigned char header[4] {};
unsigned char header[HEADER_SIZE] {};
do
{
received = gnutls_record_recv (_session, header, 4); // All
received = gnutls_record_recv (_session, header + total, HEADER_SIZE - total); // All
}
while (received > 0 &&
(errno == GNUTLS_E_INTERRUPTED ||
errno == GNUTLS_E_AGAIN));
while ((received > 0 && (total += received) < HEADER_SIZE) ||
received == GNUTLS_E_INTERRUPTED ||
received == GNUTLS_E_AGAIN);
int total = received;
if (total < HEADER_SIZE) {
throw std::string ("Failed to receive header: ") +
(received < 0 ? gnutls_strerror(received) : "connection lost?");
}
// Decode the length.
unsigned long expected = (header[0]<<24) |
@@ -521,7 +518,11 @@ void TLSClient::recv (std::string& data)
if (_debug)
std::cout << "c: INFO expecting " << expected << " bytes.\n";
// TODO This would be a good place to assert 'expected < _limit'.
if (_limit && expected >= (unsigned long) _limit) {
std::ostringstream err_str;
err_str << "Expected message size " << expected << " is larger than allowed limit " << _limit;
throw err_str.str ();
}
// Arbitrary buffer size.
char buffer[MAX_BUF];
@@ -531,13 +532,18 @@ void TLSClient::recv (std::string& data)
// fits in the buffer.
do
{
int chunk_size = 0;
do
{
received = gnutls_record_recv (_session, buffer, MAX_BUF - 1); // All
received = gnutls_record_recv (_session, buffer + chunk_size, MAX_BUF - chunk_size); // All
if (received > 0) {
total += received;
chunk_size += received;
}
}
while (received > 0 &&
(errno == GNUTLS_E_INTERRUPTED ||
errno == GNUTLS_E_AGAIN));
while ((received > 0 && (unsigned long) total < expected && chunk_size < MAX_BUF) ||
received == GNUTLS_E_INTERRUPTED ||
received == GNUTLS_E_AGAIN);
// Other end closed the connection.
if (received == 0)
@@ -548,17 +554,10 @@ void TLSClient::recv (std::string& data)
}
// Something happened.
if (received < 0 && gnutls_error_is_fatal (received) == 0) // All
{
if (_debug)
std::cout << "c: WARNING " << gnutls_strerror (received) << '\n'; // All
}
else if (received < 0)
if (received < 0)
throw std::string (gnutls_strerror (received)); // All
buffer [received] = '\0';
data += buffer;
total += received;
data.append (buffer, chunk_size);
// Stop at defined limit.
if (_limit && total > _limit)

View File

@@ -60,8 +60,6 @@
#define APPROACHING_INFINITY 1000 // Close enough. This isn't rocket surgery.
extern Task& contextTask;
static const float epsilon = 0.000001;
#endif
@@ -114,6 +112,12 @@ bool Task::operator== (const Task& other)
return true;
}
////////////////////////////////////////////////////////////////////////////////
bool Task::operator!= (const Task& other)
{
return !(*this == other);
}
////////////////////////////////////////////////////////////////////////////////
Task::Task (const std::string& input)
{
@@ -363,6 +367,14 @@ Task::dateState Task::getDateState (const std::string& name) const
return dateNotDue;
}
////////////////////////////////////////////////////////////////////////////////
// An empty task is typically a "dummy", such as in DOM evaluation, which may or
// may not occur in the context of a task.
bool Task::is_empty () const
{
return data.size () == 0;
}
////////////////////////////////////////////////////////////////////////////////
// Ready means pending, not blocked and either not scheduled or scheduled before
// now.
@@ -546,9 +558,11 @@ bool Task::is_udaPresent () const
bool Task::is_orphanPresent () const
{
for (auto& att : data)
if (att.first.compare (0, 11, "annotation_", 11) != 0)
if (Context::getContext ().columns.find (att.first) == Context::getContext ().columns.end ())
return true;
if (! isAnnotationAttr (att.first) &&
! isTagAttr (att.first) &&
! isDepAttr (att.first) &&
Context::getContext ().columns.find (att.first) == Context::getContext ().columns.end ())
return true;
return false;
}
@@ -576,12 +590,14 @@ bool Task::is_overdue () const
#endif
////////////////////////////////////////////////////////////////////////////////
// Task is considered waiting if it's pending and the wait attribute is set as
// future datetime value.
// While this is not consistent with other attribute-based virtual tags, such
// as +BLOCKED, it is more backwards compatible with how +WAITING virtual tag
// behaved in the past, when waiting had a dedicated status value.
bool Task::is_waiting () const
{
// note that is_waiting can return true for tasks in an actual status other
// than pending; in this case +WAITING will be set but the status will not be
// "waiting"
if (has ("wait"))
if (has ("wait") && get ("status") == "pending")
{
Datetime now;
Datetime wait (get_date ("wait"));
@@ -761,7 +777,25 @@ void Task::parseJSON (const json::object* root_obj)
else if (i.first == "depends" && i.second->type() == json::j_string)
{
auto deps = (json::string*)i.second;
auto uuids = split (deps->_data, ',');
// Fix for issue#2689: taskserver sometimes encodes the depends
// property as a string of the format `[\"uuid\",\"uuid\"]`
// The string includes the backslash-escaped `"` characters, making
// it invalid JSON. Since we know the characters we're looking for,
// we'll just filter out everything else.
std::string deps_str = deps->_data;
if (deps_str.front () == '[' && deps_str.back () == ']') {
std::string filtered;
for (auto &c: deps_str) {
if ((c >= '0' && c <= '9') ||
(c >= 'a' && c <= 'f') ||
c == ',' || c == '-') {
filtered.push_back(c);
}
}
deps_str = filtered;
}
auto uuids = split (deps_str, ',');
for (const auto& uuid : uuids)
addDependency (uuid);
@@ -1478,7 +1512,7 @@ void Task::fixTagsAttribute ()
}
////////////////////////////////////////////////////////////////////////////////
bool Task::isTagAttr(const std::string& attr) const
bool Task::isTagAttr(const std::string& attr)
{
return attr.compare(0, 5, "tags_") == 0;
}
@@ -1512,7 +1546,7 @@ void Task::fixDependsAttribute ()
}
////////////////////////////////////////////////////////////////////////////////
bool Task::isDepAttr(const std::string& attr) const
bool Task::isDepAttr(const std::string& attr)
{
return attr.compare(0, 4, "dep_") == 0;
}
@@ -1533,7 +1567,7 @@ const std::string Task::attr2Dep (const std::string& attr) const
}
////////////////////////////////////////////////////////////////////////////////
bool Task::isAnnotationAttr(const std::string& attr) const
bool Task::isAnnotationAttr(const std::string& attr)
{
return attr.compare(0, 11, "annotation_") == 0;
}
@@ -1541,7 +1575,7 @@ bool Task::isAnnotationAttr(const std::string& attr) const
#ifdef PRODUCT_TASKWARRIOR
////////////////////////////////////////////////////////////////////////////////
// A UDA Orphan is an attribute that is not represented in context.columns.
std::vector <std::string> Task::getUDAOrphanUUIDs () const
std::vector <std::string> Task::getUDAOrphans () const
{
std::vector <std::string> orphans;
for (auto& it : data)
@@ -2253,6 +2287,10 @@ void Task::modify (modType type, bool text_required /* = false */)
{
std::string label = " MODIFICATION ";
// while reading the parse tree, consider DOM references in the context of
// this task
auto currentTask = Context::getContext ().withCurrentTask(this);
// Need this for later comparison.
auto originalStatus = getStatus ();
@@ -2272,6 +2310,19 @@ void Task::modify (modType type, bool text_required /* = false */)
value == "''" ||
value == "\"\"")
{
// Special case: Handle bulk removal of 'tags' and 'depends" virtual
// attributes
if (name == "depends")
{
for (auto dep: getDependencyUUIDs ())
removeDependency(dep);
}
else if (name == "tags")
{
for (auto tag: getTags ())
removeTag(tag);
}
// ::composeF4 will skip if the value is blank, but the presence of
// the attribute will prevent ::validate from applying defaults.
if ((has (name) && get (name) != "") ||
@@ -2400,7 +2451,8 @@ void Task::modify (modType type, bool text_required /* = false */)
#endif
////////////////////////////////////////////////////////////////////////////////
// Compare this task to another and summarize the differences for display
// Compare this task to another and summarize the differences for display, in
// the future tense ("Foo will be set to ..").
std::string Task::diff (const Task& after) const
{
// Attributes are all there is, so figure the different attribute names
@@ -2645,3 +2697,206 @@ std::string Task::diffForInfo (
}
////////////////////////////////////////////////////////////////////////////////
// Similar to diff, but formatted as a side-by-side table for an Undo preview
Table Task::diffForUndoSide (
const Task& after) const
{
// Set the colors.
Color color_red (Context::getContext ().color () ? Context::getContext ().config.get ("color.undo.before") : "");
Color color_green (Context::getContext ().color () ? Context::getContext ().config.get ("color.undo.after") : "");
// Attributes are all there is, so figure the different attribute names
// between before and after.
Table view;
view.width (Context::getContext ().getWidth ());
view.intraPadding (2);
view.add ("");
view.add ("Prior Values");
view.add ("Current Values");
setHeaderUnderline (view);
if (!is_empty ())
{
const Task &before = *this;
std::vector <std::string> beforeAtts;
for (auto& att : before.data)
beforeAtts.push_back (att.first);
std::vector <std::string> afterAtts;
for (auto& att : after.data)
afterAtts.push_back (att.first);
std::vector <std::string> beforeOnly;
std::vector <std::string> afterOnly;
listDiff (beforeAtts, afterAtts, beforeOnly, afterOnly);
int row;
for (auto& name : beforeOnly)
{
row = view.addRow ();
view.set (row, 0, name);
view.set (row, 1, renderAttribute (name, before.get (name)), color_red);
}
for (auto& att : before.data)
{
std::string priorValue = before.get (att.first);
std::string currentValue = after.get (att.first);
if (currentValue != "")
{
row = view.addRow ();
view.set (row, 0, att.first);
view.set (row, 1, renderAttribute (att.first, priorValue),
(priorValue != currentValue ? color_red : Color ()));
view.set (row, 2, renderAttribute (att.first, currentValue),
(priorValue != currentValue ? color_green : Color ()));
}
}
for (auto& name : afterOnly)
{
row = view.addRow ();
view.set (row, 0, name);
view.set (row, 2, renderAttribute (name, after.get (name)), color_green);
}
}
else
{
int row;
for (auto& att : after.data)
{
row = view.addRow ();
view.set (row, 0, att.first);
view.set (row, 2, renderAttribute (att.first, after.get (att.first)), color_green);
}
}
return view;
}
////////////////////////////////////////////////////////////////////////////////
// Similar to diff, but formatted as a diff for an Undo preview
Table Task::diffForUndoPatch (
const Task& after,
const Datetime& lastChange) const
{
// This style looks like this:
// --- before 2009-07-04 00:00:25.000000000 +0200
// +++ after 2009-07-04 00:00:45.000000000 +0200
//
// - name: old // att deleted
// + name:
//
// - name: old // att changed
// + name: new
//
// - name:
// + name: new // att added
//
// Set the colors.
Color color_red (Context::getContext ().color () ? Context::getContext ().config.get ("color.undo.before") : "");
Color color_green (Context::getContext ().color () ? Context::getContext ().config.get ("color.undo.after") : "");
const Task &before = *this;
// Generate table header.
Table view;
view.width (Context::getContext ().getWidth ());
view.intraPadding (2);
view.add ("");
view.add ("");
int row = view.addRow ();
view.set (row, 0, "--- previous state", color_red);
view.set (row, 1, "Undo will restore this state", color_red);
row = view.addRow ();
view.set (row, 0, "+++ current state ", color_green);
view.set (row, 1, format ("Change made {1}",
lastChange.toString (Context::getContext ().config.get ("dateformat"))),
color_green);
view.addRow ();
// Add rows to table showing diffs.
std::vector <std::string> all = Context::getContext ().getColumns ();
// Now factor in the annotation attributes.
for (auto& it : before.data)
if (it.first.substr (0, 11) == "annotation_")
all.push_back (it.first);
for (auto& it : after.data)
if (it.first.substr (0, 11) == "annotation_")
all.push_back (it.first);
// Now render all the attributes.
std::sort (all.begin (), all.end ());
std::string before_att;
std::string after_att;
std::string last_att;
for (auto& a : all)
{
if (a != last_att) // Skip duplicates.
{
last_att = a;
before_att = before.get (a);
after_att = after.get (a);
// Don't report different uuid.
// Show nothing if values are the unchanged.
if (a == "uuid" ||
before_att == after_att)
{
// Show nothing - no point displaying that which did not change.
// row = view.addRow ();
// view.set (row, 0, *a + ":");
// view.set (row, 1, before_att);
}
// Attribute deleted.
else if (before_att != "" && after_att == "")
{
row = view.addRow ();
view.set (row, 0, '-' + a + ':', color_red);
view.set (row, 1, before_att, color_red);
row = view.addRow ();
view.set (row, 0, '+' + a + ':', color_green);
}
// Attribute added.
else if (before_att == "" && after_att != "")
{
row = view.addRow ();
view.set (row, 0, '-' + a + ':', color_red);
row = view.addRow ();
view.set (row, 0, '+' + a + ':', color_green);
view.set (row, 1, after_att, color_green);
}
// Attribute changed.
else
{
row = view.addRow ();
view.set (row, 0, '-' + a + ':', color_red);
view.set (row, 1, before_att, color_red);
row = view.addRow ();
view.set (row, 0, '+' + a + ':', color_green);
view.set (row, 1, after_att, color_green);
}
}
}
return view;
}
////////////////////////////////////////////////////////////////////////////////

View File

@@ -33,6 +33,8 @@
#include <stdio.h>
#include <time.h>
#include <JSON.h>
#include <Table.h>
#include <Datetime.h>
class Task
{
@@ -60,6 +62,7 @@ public:
public:
Task () = default;
bool operator== (const Task&);
bool operator!= (const Task&);
Task (const std::string&);
Task (const json::object*);
@@ -74,7 +77,6 @@ public:
enum dateState {dateNotDue, dateAfterToday, dateLaterToday, dateEarlierToday, dateBeforeToday};
// Public data.
std::map <std::string, std::string> data {};
int id {0};
float urgency_value {0.0};
bool recalc_urgency {true};
@@ -100,6 +102,8 @@ public:
void set (const std::string&, long long);
void remove (const std::string&);
bool is_empty () const;
#ifdef PRODUCT_TASKWARRIOR
bool is_ready () const;
bool is_due () const;
@@ -113,6 +117,10 @@ public:
bool is_overdue () const;
bool is_udaPresent () const;
bool is_orphanPresent () const;
static bool isTagAttr (const std::string&);
static bool isDepAttr (const std::string&);
static bool isAnnotationAttr (const std::string&);
#endif
bool is_waiting () const;
@@ -150,7 +158,7 @@ public:
std::vector <Task> getBlockedTasks () const;
std::vector <Task> getDependencyTasks () const;
std::vector <std::string> getUDAOrphanUUIDs () const;
std::vector <std::string> getUDAOrphans () const;
void substitute (const std::string&, const std::string&, const std::string&);
#endif
@@ -167,6 +175,8 @@ public:
std::string diff (const Task& after) const;
std::string diffForInfo (const Task& after, const std::string& dateformat, long& last_timestamp, const long current_timestamp) const;
Table diffForUndoSide (const Task& after) const;
Table diffForUndoPatch (const Task& after, const Datetime& lastChange) const;
private:
int determineVersion (const std::string&);
@@ -176,16 +186,16 @@ private:
void validate_before (const std::string&, const std::string&);
const std::string encode (const std::string&) const;
const std::string decode (const std::string&) const;
bool isTagAttr (const std::string&) const;
const std::string tag2Attr (const std::string&) const;
const std::string attr2Tag (const std::string&) const;
bool isDepAttr (const std::string&) const;
const std::string dep2Attr (const std::string&) const;
const std::string attr2Dep (const std::string&) const;
bool isAnnotationAttr (const std::string&) const;
void fixDependsAttribute ();
void fixTagsAttribute ();
protected:
std::map <std::string, std::string> data {};
public:
float urgency_project () const;
float urgency_active () const;

View File

@@ -32,7 +32,9 @@
#include <format.h>
#include <utf8.h>
#include <main.h>
#include <util.h>
#include <stdlib.h>
#include <regex>
#define STRING_COLUMN_LABEL_DEP "Depends"
@@ -152,20 +154,59 @@ void ColumnDepends::modify (Task& task, const std::string& value)
// Apply or remove dendencies in turn.
for (auto& dep : split (value, ','))
{
bool removal = false;
if (dep[0] == '-')
{
if (dep.length () == 37)
task.removeDependency (dep.substr (1));
else
task.removeDependency (strtol (dep.substr (1).c_str (), nullptr, 10));
removal = true;
dep = dep.substr(1);
}
else
auto hyphen = dep.find ('-');
long lower, upper; // For ID ranges
std::regex valid_uuid ("[a-f0-9]{8}([a-f0-9-]{4,28})?"); // TODO: Make more precise
// UUID
if (dep.length () >= 8 && std::regex_match (dep, valid_uuid))
{
if (dep.length () == 36)
task.addDependency (dep);
else
task.addDependency (strtol (dep.c_str (), nullptr, 10));
// Full UUID, can be added directly
if (dep.length () == 36)
if (removal)
task.removeDependency (dep);
else
task.addDependency (dep);
// Short UUID, need to look up full form
else
{
Task loaded_task;
if (Context::getContext ().tdb2.get (dep, loaded_task))
if (removal)
task.removeDependency (loaded_task.get ("uuid"));
else
task.addDependency (loaded_task.get ("uuid"));
else
throw format ("Dependency could not be set - task with UUID '{1}' does not exist.", dep);
}
}
// ID range
else if (dep.find ('-') != std::string::npos &&
extractLongInteger (dep.substr (0, hyphen), lower) &&
extractLongInteger (dep.substr (hyphen + 1), upper))
{
for (long i = lower; i <= upper; i++)
if (removal)
task.removeDependency (i);
else
task.addDependency (i);
}
// Simple ID
else if (extractLongInteger (dep, lower))
if (removal)
task.removeDependency (lower);
else
task.addDependency (lower);
else
throw format ("Invalid dependency value: '{1}'", dep);
}
}

View File

@@ -36,8 +36,6 @@
#include <utf8.h>
#include <util.h>
extern Task& contextTask;
////////////////////////////////////////////////////////////////////////////////
ColumnProject::ColumnProject ()
{
@@ -121,7 +119,6 @@ void ColumnProject::modify (Task& task, const std::string& value)
{
Eval e;
e.addSource (domSource);
contextTask = task;
Variant v;
e.evaluateInfixExpression (value, v);

View File

@@ -36,8 +36,6 @@
#include <format.h>
#include <utf8.h>
extern Task& contextTask;
////////////////////////////////////////////////////////////////////////////////
ColumnRecur::ColumnRecur ()
{
@@ -108,7 +106,6 @@ void ColumnRecur::modify (Task& task, const std::string& value)
{
Eval e;
e.addSource (domSource);
contextTask = task;
e.evaluateInfixExpression (value, evaluatedValue);
}

View File

@@ -36,8 +36,6 @@
#include <utf8.h>
#include <main.h>
extern Task& contextTask;
////////////////////////////////////////////////////////////////////////////////
ColumnTags::ColumnTags ()
{
@@ -162,7 +160,6 @@ void ColumnTags::modify (Task& task, const std::string& value)
{
Eval e;
e.addSource (domSource);
contextTask = task;
Variant v;
e.evaluateInfixExpression (value, v);

View File

@@ -34,8 +34,6 @@
#include <Filter.h>
#include <format.h>
extern Task& contextTask;
////////////////////////////////////////////////////////////////////////////////
ColumnTypeDate::ColumnTypeDate ()
{
@@ -213,7 +211,6 @@ void ColumnTypeDate::modify (Task& task, const std::string& value)
{
Eval e;
e.addSource (domSource);
contextTask = task;
e.evaluateInfixExpression (value, evaluatedValue);
}

View File

@@ -32,8 +32,6 @@
#include <Filter.h>
#include <format.h>
extern Task& contextTask;
////////////////////////////////////////////////////////////////////////////////
ColumnTypeDuration::ColumnTypeDuration ()
{
@@ -55,7 +53,6 @@ void ColumnTypeDuration::modify (Task& task, const std::string& value)
{
Eval e;
e.addSource (domSource);
contextTask = task;
e.evaluateInfixExpression (value, evaluatedValue);
}

View File

@@ -32,8 +32,6 @@
#include <Filter.h>
#include <format.h>
extern Task& contextTask;
////////////////////////////////////////////////////////////////////////////////
ColumnTypeNumeric::ColumnTypeNumeric ()
{
@@ -55,7 +53,6 @@ void ColumnTypeNumeric::modify (Task& task, const std::string& value)
{
Eval e;
e.addSource (domSource);
contextTask = task;
e.evaluateInfixExpression (value, evaluatedValue);
}

View File

@@ -34,8 +34,6 @@
#define STRING_INVALID_MOD "The '{1}' attribute does not allow a value of '{2}'."
extern Task& contextTask;
////////////////////////////////////////////////////////////////////////////////
ColumnTypeString::ColumnTypeString ()
{
@@ -67,7 +65,6 @@ void ColumnTypeString::modify (Task& task, const std::string& value)
{
Eval e;
e.addSource (domSource);
contextTask = task;
Variant v;
e.evaluateInfixExpression (value, v);

View File

@@ -51,6 +51,9 @@ int CmdAdd::execute (std::string& output)
{
// Apply the command line modifications to the new task.
Task task;
// the task is empty, but DOM references can refer to earlier parts of the
// command line, e.g., `task add due:20110101 wait:due`.
task.modify (Task::modReplace, true);
Context::getContext ().tdb2.add (task);

View File

@@ -110,33 +110,43 @@ std::string CmdContext::joinWords (const std::vector <std::string>& words, unsig
// Validate the context as valid for writing and fail the write context definition
// A valid write context:
// - does not contain any operators except AND
// - does not use modifiers
// - does not contain tag exclusion
// - does not use modifiers, except for 'equals' and 'is'
//
// Returns True if the context is a valid write context. If the context is
// invalid due to a wrong modifier use, the modifier string will contain the
// first invalid modifier.
bool CmdContext::validateWriteContext (const std::vector <A2>& lexedArgs, std::string& modifier_token)
//
bool CmdContext::validateWriteContext (const std::vector <A2>& lexedArgs, std::string& reason)
{
bool contains_or = false;
bool contains_modifier = false;
for (auto &arg: lexedArgs) {
if (arg._lextype == Lexer::Type::op)
if (arg.attribute ("raw") == "or")
contains_or = true;
{
reason = "contains the 'OR' operator";
return false;
}
if (arg._lextype == Lexer::Type::pair) {
auto modifier = arg.attribute ("modifier");
if (modifier != "" && modifier != "is" && modifier != "equals")
{
contains_modifier = true;
modifier_token = arg.attribute ("raw");
break;
reason = format ("contains an attribute modifier '{1}'", arg.attribute ("raw"));
return false;
}
}
if (arg._lextype == Lexer::Type::tag) {
if (arg.attribute ("sign") == "-")
{
reason = format ("contains tag exclusion '{1}'", arg.attribute ("raw"));
return false;
}
}
}
return not contains_or and not contains_modifier;
return true;
}
////////////////////////////////////////////////////////////////////////////////
@@ -211,14 +221,13 @@ void CmdContext::defineContext (const std::vector <std::string>& words, std::str
! confirm (format ("The filter '{1}' matches 0 pending tasks. Do you wish to continue?", value)))
throw std::string ("Context definition aborted.");
std::string modifier_token = "";
bool valid_write_context = CmdContext::validateWriteContext (lexedArgs, modifier_token);
std::string reason = "";
bool valid_write_context = CmdContext::validateWriteContext (lexedArgs, reason);
if (! valid_write_context)
{
std::stringstream warning;
warning << format ("The filter '{1}' is not a valid modification string, because it contains ", value)
<< ( modifier_token.empty () ? "the OR operator." : format ("an attribute modifier ({1}).", modifier_token) )
warning << format ("The filter '{1}' is not a valid modification string, because it contains {2}.", value, reason)
<< "\nAs such, value for the write context cannot be set (context will not apply on task add / task log).\n\n"
<< format ("Please use 'task config context.{1}.write <default mods>' to set default attribute values for new tasks in this context manually.\n\n", words[1]);
out << colorizeFootnote (warning.str ());

View File

@@ -249,20 +249,20 @@ int CmdCustom::execute (std::string& output)
rc = 1;
}
// Inform user about the new release higlights if not presented yet
// Inform user about the new release highlights if not presented yet
if (Context::getContext ().config.get ("news.version") != "2.6.0")
{
std::random_device device;
std::mt19937 random_generator(device());
std::uniform_int_distribution<std::mt19937::result_type> ten_percent(1, 10);
std::uniform_int_distribution<std::mt19937::result_type> twentyfive_percent(1, 4);
std::string NEWS_NOTICE = (
"Recently upgraded to 2.6.0. "
"Please run 'task news' to read higlights about the new release."
"Please run 'task news' to read highlights about the new release."
);
// 1 in 10 chance to display the message.
if (ten_percent(random_generator) == 10)
if (twentyfive_percent(random_generator) == 4)
{
if (Context::getContext ().verbose ("footnote"))
Context::getContext ().footnote (NEWS_NOTICE);

View File

@@ -128,7 +128,7 @@ int CmdDenotate::execute (std::string&)
}
}
if (before.data != task.data)
if (before.getAnnotations () != task.getAnnotations ())
{
auto question = format ("Denotate task {1} '{2}'?",
task.identifier (true),

View File

@@ -324,7 +324,7 @@ std::string CmdEdit::formatTask (Task task, const std::string& dateformat)
}
// UDA orphans
auto orphans = task.getUDAOrphanUUIDs ();
auto orphans = task.getUDAOrphans ();
if (orphans.size ())
{
before << "# User Defined Attribute Orphans\n";

View File

@@ -64,9 +64,8 @@ int CmdGet::execute (std::string& output)
{
case Lexer::Type::dom:
{
Task t;
Variant result;
if (getDOM (arg.attribute ("raw"), t, result))
if (getDOM (arg.attribute ("raw"), NULL, result))
results.emplace_back (result);
else
results.emplace_back ("");

View File

@@ -198,7 +198,7 @@ void CmdImport::importSingleTask (json::object* obj)
if (hasGeneratedEnd)
task.set ("end", before.get ("end"));
if (before.data != task.data)
if (before != task)
{
CmdModify modHelper;
modHelper.checkConsistency (before, task);

View File

@@ -79,7 +79,7 @@ int CmdModify::execute (std::string&)
Task before (task);
task.modify (Task::modReplace);
if (before.data != task.data)
if (before != task)
{
// Abort if change introduces inconsistencies.
checkConsistency(before, task);

View File

@@ -477,7 +477,7 @@ void CmdNews::version2_6_0 (std::vector<NewsItem>& items) {
" hooks.location=$XDG_CONFIG_HOME/task/hooks/\n\n"
" Solutions in the past required symlinks or more cumbersome configuration overrides.",
" If you configure your data.location and hooks.location as above, ensure\n"
" that the XFG_DATA_HOME and XDG_CONFIG_HOME environment variables are set,\n"
" that the XDG_DATA_HOME and XDG_CONFIG_HOME environment variables are set,\n"
" otherwise they're going to expand to empty string. Alternatively you can\n"
" hardcode the desired paths on your system."
);
@@ -575,14 +575,15 @@ int CmdNews::execute (std::string& output)
std::stringstream outro;
outro << underline.colorize (bold.colorize ("Taskwarrior crowdfunding\n"));
outro << format (
"Taskwarrior has been in development for {1} years and its continued survival\n"
"Taskwarrior has been in development for {1} years but its survival\n"
"depends on your support!\n\n"
"Please consider joining our {2} fundraiser and visit crowdfunding page at:\n\n",
"Please consider joining our {2} fundraiser to help us fund maintenance\n"
"and development of new features:\n\n",
std::lround (static_cast<float>(development_time.days ()) / 365.25),
now.year ()
);
outro << bold.colorize(" https://github.com/sponsors/GothenburgBitFactory/\n\n");
outro << "Interesting perks are available for our sponsors.\nSponsorship directly translates to more development time spent on the project.\n";
outro << "Perks are available for our sponsors.\n";
std::cout << outro.str ();
@@ -615,7 +616,11 @@ int CmdNews::execute (std::string& output)
autoComplete (answer, options, matches, 1); // Hard-coded 1.
if (matches.size () == 1 && matches[0] == "yes")
#if defined (DARWIN)
system ("open 'https://github.com/sponsors/GothenburgBitFactory/'");
#else
system ("xdg-open 'https://github.com/sponsors/GothenburgBitFactory/'");
#endif
std::cout << std::endl;
}
@@ -624,7 +629,7 @@ int CmdNews::execute (std::string& output)
if (! full_summary && major_items)
Context::getContext ().footnote (format (
"Only major higlights were displayed ({1} out of {2} total).\n"
"Only major highlights were displayed ({1} out of {2} total).\n"
"If you're interested in more release highlights, run 'task news {3} minor'.",
items.size (),
total_highlights,

View File

@@ -35,6 +35,7 @@
#include <format.h>
#include <shared.h>
#include <util.h>
#include <Task.h>
////////////////////////////////////////////////////////////////////////////////
CmdUDAs::CmdUDAs ()
@@ -133,10 +134,8 @@ int CmdUDAs::execute (std::string& output)
std::map <std::string, int> orphans;
for (auto& i : filtered)
{
for (auto& att : i.data)
if (att.first.substr (0, 11) != "annotation_" &&
Context::getContext ().columns.find (att.first) == Context::getContext ().columns.end ())
orphans[att.first]++;
for (auto& att : i.getUDAOrphans ())
orphans[att]++;
}
if (orphans.size ())

View File

@@ -29,6 +29,7 @@
#include <new>
#include <cstring>
#include <Context.h>
#include <regex>
////////////////////////////////////////////////////////////////////////////////
int main (int argc, const char** argv)
@@ -64,6 +65,11 @@ int main (int argc, const char** argv)
status = -3;
}
catch (const std::regex_error& e)
{
std::cout << "regex_error caught: " << e.what() << '\n';
}
catch (...)
{
std::cerr << "Unknown error. Please report.\n";

View File

@@ -189,10 +189,9 @@ static void colorizeKeyword (Task& task, const std::string& rule, const Color& b
// first match.
else
{
for (const auto& att : task.data)
for (const auto& att : task.getAnnotations ())
{
if (! att.first.compare (0, 11, "annotation_", 11) &&
find (att.second, rule.substr (14), sensitive) != std::string::npos)
if (find (att.second, rule.substr (14), sensitive) != std::string::npos)
{
applyColor (base, c, merge);
return;

View File

@@ -25,6 +25,7 @@
////////////////////////////////////////////////////////////////////////////////
#include <cmake.h>
#include <format.h>
#include <shared.h>
// If <iostream> is included, put it after <stdio.h>, because it includes
// <stdio.h>, and therefore would ignore the _WITH_GETLINE.
@@ -309,3 +310,10 @@ void setHeaderUnderline (Table& table)
}
////////////////////////////////////////////////////////////////////////////////
// Perform strtol on a string and check if the extracted value matches.
//
bool extractLongInteger (const std::string& input, long& output)
{
output = strtol (input.c_str (), nullptr, 10);
return (format ("{1}", output) == input);
}

View File

@@ -63,6 +63,7 @@ const std::vector <std::string> extractParents (
bool nontrivial (const std::string&);
const char* optionalBlankLine ();
void setHeaderUnderline (Table&);
bool extractLongInteger (const std::string&, long&);
#endif
////////////////////////////////////////////////////////////////////////////////

1
test/.gitignore vendored
View File

@@ -34,5 +34,6 @@ variant_partial.t
variant_subtract.t
variant_xor.t
view.t
tw-2689.t
json_test

View File

@@ -16,7 +16,7 @@ include_directories (${CMAKE_SOURCE_DIR}
${CMAKE_SOURCE_DIR}/test
${TASK_INCLUDE_DIRS})
set (test_SRCS col.t dom.t eval.t lexer.t t.t tdb2.t util.t variant_add.t variant_and.t variant_cast.t variant_divide.t variant_equal.t variant_exp.t variant_gt.t variant_gte.t variant_inequal.t variant_lt.t variant_lte.t variant_match.t variant_math.t variant_modulo.t variant_multiply.t variant_nomatch.t variant_not.t variant_or.t variant_partial.t variant_subtract.t variant_xor.t view.t)
set (test_SRCS col.t dom.t eval.t lexer.t t.t tw-2689.t tdb2.t util.t variant_add.t variant_and.t variant_cast.t variant_divide.t variant_equal.t variant_exp.t variant_gt.t variant_gte.t variant_inequal.t variant_lt.t variant_lte.t variant_match.t variant_math.t variant_modulo.t variant_multiply.t variant_nomatch.t variant_not.t variant_or.t variant_partial.t variant_subtract.t variant_xor.t view.t)
add_custom_target (test ./run_all --verbose
DEPENDS ${test_SRCS} task_executable

View File

@@ -121,15 +121,15 @@ class ContextManagementTest(TestCase):
self.assertEqual(self.t.taskrc_content.count(context_line), 1)
# Assert the config does not contain write context definition
context_line = 'context.work.write=due.before:today\n'
context_line = 'context.urgent.write=due.before:today\n'
self.assertNotIn(context_line, self.t.taskrc_content)
# Assert that the write context was not set at all
self.assertNotIn('context.work.write=', self.t.taskrc_content)
self.assertNotIn('context.urgent.write=', self.t.taskrc_content)
# Assert that legacy style was not used
# Assert the config contains read context definition
context_line = 'context.work=due.before:today\n'
context_line = 'context.urgent=due.before:today\n'
self.assertNotIn(context_line, self.t.taskrc_content)
def test_context_define_invalid_for_write_due_to_operator(self):
@@ -146,15 +146,40 @@ class ContextManagementTest(TestCase):
self.assertEqual(self.t.taskrc_content.count(context_line), 1)
# Assert the config does not contain write context definition
context_line = 'context.work.write=due:today or +next\n'
context_line = 'context.urgent.write=due:today or +next\n'
self.assertNotIn(context_line, self.t.taskrc_content)
# Assert that the write context was not set at all
self.assertNotIn('context.work.write=', self.t.taskrc_content)
self.assertNotIn('context.urgent.write=', self.t.taskrc_content)
# Assert that legacy style was not used
# Assert the config contains read context definition
context_line = 'context.work=due:today or +next\n'
context_line = 'context.urgent=due:today or +next\n'
self.assertNotIn(context_line, self.t.taskrc_content)
def test_context_define_invalid_for_write_due_to_tag_exclusion(self):
"""Test definition of a context that is not a valid write context because it contains a tag exclusion."""
self.t.config("confirmation", "off")
code, out, err = self.t('context define nowork due:today -work')
self.assertIn("Context 'nowork' defined", out)
# Assert the config contains read context definition
context_line = 'context.nowork.read=due:today -work\n'
self.assertIn(context_line, self.t.taskrc_content)
# Assert that it contains the definition only once
self.assertEqual(self.t.taskrc_content.count(context_line), 1)
# Assert the config does not contain write context definition
context_line = 'context.nowork.write=due:today -work\n'
self.assertNotIn(context_line, self.t.taskrc_content)
# Assert that the write context was not set at all
self.assertNotIn('context.nowork.write=', self.t.taskrc_content)
# Assert that legacy style was not used
# Assert the config contains read context definition
context_line = 'context.nowork=due:today -work\n'
self.assertNotIn(context_line, self.t.taskrc_content)
def test_context_delete(self):
@@ -206,6 +231,16 @@ class ContextManagementTest(TestCase):
self.assertEqual(len(list(filter(contains_work, out.splitlines()))), 1)
self.assertEqual(len(list(filter(contains_home, out.splitlines()))), 1)
def test_context_list_legacy(self):
"""Test the determination of legacy context definition."""
self.t('config context.old project:Old', input='y\n')
self.t('context old')
code, out, err = self.t('context list')
# Assert that "old" context has only the read component defined
self.assertRegex(out, r'read\s+project:Old\s+yes')
self.assertRegex(out, r'write\s+yes')
def test_context_initially_empty(self):
"""Test that no context is set initially."""
self.t('context define work project:Work', input='y\ny\n')

View File

@@ -145,6 +145,22 @@ class TestDependencies(TestCase):
code, out, err = self.t("_get 1.tags.BLOCKED")
self.assertEqual("\n", out)
def test_dependency_bulk_removal(self):
"""2655: Check that one can bulk undepend a task"""
self.t("add three")
self.t("1 modify dep:2,3")
code, out, err = self.t("_get 1.tags.BLOCKED")
self.assertEqual("BLOCKED\n", out)
self.t("1 modify depends:")
code, out, err = self.t("_get 1.tags.BLOCKED")
self.assertEqual("\n", out)
code, out, err = self.t("_get 1.depends")
self.assertEqual("\n", out)
def test_chain_repair(self):
"""Check that a broken chain is repaired"""
self.t("add three")
@@ -169,7 +185,6 @@ class TestDependencies(TestCase):
self.assertNotIn("Would you like the dependency chain fixed?", out)
self.assertIn("Deleted 1 task", out)
@unittest.expectedFailure
def test_id_range_dep(self):
"""Check that an ID range can be used for deps"""
self.t("add three")
@@ -178,7 +193,7 @@ class TestDependencies(TestCase):
self.t("3 modify dep:1-2")
code, out, err = self.t("_get 1.tags.BLOCKING")
self.assertEqual("BLOCKING\n", out)
code, out, err = self.t("_get 2.tag.BLOCKING")
code, out, err = self.t("_get 2.tags.BLOCKING")
self.assertEqual("BLOCKING\n", out)
def test_id_uuid_dep(self):
@@ -196,6 +211,22 @@ class TestDependencies(TestCase):
code, out, err = self.t("3 modify dep:-1,-%s" % uuid)
self.assertIn("Modifying task 3 'three'.", out)
def test_id_uuid_short_dep(self):
"""Check that short UUIDs are usable for deps"""
# Get 2.uuid
code, out, err = self.t("_get 2.uuid")
short_uuid = out.strip().split("-")[0]
# Add a mix of IDs and UUID
code, out, err = self.t("add three dep:%s" % short_uuid)
self.assertIn("Created task 3.", out)
# Remove a mix of IЅs and UUID
code, out, err = self.t("3 modify dep:-%s" % short_uuid)
self.assertIn("Modifying task 3 'three'.", out)
class TestBug697(TestCase):
def setUp(self):
"""Executed before each test in the class"""

View File

@@ -1,5 +1,9 @@
FROM centos:8
# Fix missing repo metadata
RUN sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-Linux-*
RUN sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-Linux-*
RUN dnf update -y
RUN dnf install python3 git gcc gcc-c++ make gnutls-devel libuuid-devel glibc-langpack-en -y
RUN dnf install epel-release -y

View File

@@ -1,4 +1,4 @@
FROM fedora:31
FROM fedora:35
RUN dnf update -y
RUN dnf install python3 git gcc gcc-c++ cmake make gnutls-devel libuuid-devel libfaketime glibc-langpack-en -y

27
test/docker/ubuntu1604 Normal file
View File

@@ -0,0 +1,27 @@
FROM ubuntu:16.04
RUN apt-get update
RUN apt-get install -y build-essential cmake git uuid-dev libgnutls28-dev faketime locales python3
# Setup language environment
RUN locale-gen en_US.UTF-8
ENV LC_ALL en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US.UTF-8
# Setup taskwarrior
ADD . /root/code/
WORKDIR /root/code/
RUN git clean -dfx
RUN git submodule init
RUN git submodule update
RUN cmake -DCMAKE_BUILD_TYPE=debug .
RUN make -j2
RUN make install
RUN task --version
# Setup tests
WORKDIR /root/code/test/
RUN make
CMD ["bash", "-c", "./run_all -v ; cat all.log | grep 'not ok' ; ./problems"]

27
test/docker/ubuntu2110 Normal file
View File

@@ -0,0 +1,27 @@
FROM ubuntu:21.10
RUN apt-get update
RUN DEBIAN_FRONTEND="noninteractive" apt-get install -y build-essential cmake git uuid-dev libgnutls28-dev faketime locales python3
# Setup language environment
RUN locale-gen en_US.UTF-8
ENV LC_ALL en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US.UTF-8
# Setup taskwarrior
ADD . /root/code/
WORKDIR /root/code/
RUN git clean -dfx
RUN git submodule init
RUN git submodule update
RUN cmake -DCMAKE_BUILD_TYPE=debug .
RUN make -j8
RUN make install
RUN task --version
# Setup tests
WORKDIR /root/code/test/
RUN make -j8
CMD ["bash", "-c", "./run_all -v ; cat all.log | grep 'not ok' ; ./problems"]

View File

@@ -28,6 +28,7 @@
import sys
import os
import tempfile
import unittest
# Ensure python finds the local simpletap module
sys.path.append(os.path.dirname(os.path.abspath(__file__)))
@@ -117,6 +118,53 @@ class TestIDMisParse(TestCase):
self.assertNotIn("three", out)
class TestIDRangeParsing(TestCase):
def setUp(self):
"""Executed before each test in the class"""
self.t = Task()
def generate_tasks(self, n):
"""Generates n tasks for testing purposes"""
with tempfile.NamedTemporaryFile(mode='w') as f:
f.write('\n'.join([f'{{"description": "test task {i+1}"}}' for i in range(n)]))
f.flush()
code, out, err = self.t(f'import {f.name}')
def test_single_digit_range(self):
"""Test that parsing single digit ID range works"""
self.generate_tasks(20)
code, out, err = self.t("4-6 count")
self.assertEqual("3", out.strip())
def test_double_digit_range(self):
"""Test that parsing double digit ID range works"""
self.generate_tasks(30)
code, out, err = self.t("14-26 count")
self.assertEqual("13", out.strip())
def test_triple_digit_range(self):
"""Test that parsing triple digit ID range works"""
self.generate_tasks(150)
code, out, err = self.t("110-128 count")
self.assertEqual("19", out.strip())
def test_quadruple_digit_range(self):
"""Test that parsing four digit ID range works"""
self.generate_tasks(1200)
# Full range
code, out, err = self.t("1100-1189 count")
self.assertEqual("90", out.strip())
# Partially existing range, 1200 is the last ID
code, out, err = self.t("1100-1289 count")
self.assertEqual("101", out.strip())
# Also if the range resembles time
code, out, err = self.t("1100-1140 count")
self.assertEqual("41", out.strip())
if __name__ == "__main__":
from simpletap import TAPTestRunner
unittest.main(testRunner=TAPTestRunner())

View File

@@ -500,17 +500,9 @@ class TestBug1900(TestCase):
def test_project_eval(self):
"""1900: Project name can contain dashes"""
self.t("add foo project:due-b")
self.t("add foo project:doo-bee")
code, out, err = self.t("_get 1.project")
self.assertEqual("due-b\n", out)
self.t("add foo project:scheduled-home")
code, out, err = self.t("_get 2.project")
self.assertEqual("scheduled-home\n", out)
self.t("add foo project:entry-work")
code, out, err = self.t("_get 3.project")
self.assertEqual("entry-work\n", out)
self.assertEqual("doo-bee\n", out)
class TestBug1904(TestCase):

View File

@@ -126,7 +126,8 @@ class TestRecurrenceWeekdays(TestCase):
# The due dates should be Friday and Monday, three days apart,
# having skipped the weekend.
# Note: On daylight savings in the fall, this '3' becomes '2.9583'.
self.assertTrue(int(monday.strip()) - int(friday.strip()) >= 2)
# Note: when monday is next year, friday+2 > 365
self.assertTrue(int(monday.strip()) >= (int(friday.strip()) + 2) % 365)
class TestRecurrenceUntil(TestCase):

View File

@@ -187,7 +187,7 @@ TODO Task::decode
test.is (task.get ("three"), "four", "three=four");
// Task::set
task.data.clear ();
task = Task();
task.set ("name", "value");
test.is (task.composeF4 (), "[name:\"value\"]", "Task::set");
@@ -211,7 +211,7 @@ TODO Task::decode
test.is (task.composeF4 (), "[name:\"value\"]", "Task::remove");
// Task::all
test.is (task.data.size (), (size_t)1, "Task::all size");
test.is (task.all ().size (), (size_t)1, "Task::all size");
////////////////////////////////////////////////////////////////////////////////

View File

@@ -36,13 +36,10 @@ from basetest import Task, TestCase
class TestTags(TestCase):
@classmethod
def setUpClass(cls):
"""Executed once before any test in the class"""
cls.t = Task()
def setUp(self):
"""Executed before each test in the class"""
self.t = Task()
def split_tags(self, tags):
return sorted(tags.strip().split(','))
@@ -81,6 +78,19 @@ class TestTags(TestCase):
code, out, err = self.t("1 modify -missing")
self.assertIn("Modified 0 tasks", out)
def test_tag_bulk_removal(self):
"""2655: Test bulk removal of tags"""
self.t("add +one This +two is a test +three")
code, out, err = self.t("_get 1.tags")
self.assertEqual(
sorted(["one", "two", "three"]),
self.split_tags(out))
# Remove all tags in bulk
self.t("1 modify tags:")
code, out, err = self.t("_get 1.tags")
self.assertEqual("\n", out)
class TestVirtualTags(TestCase):
@classmethod

View File

@@ -0,0 +1,27 @@
-----BEGIN CERTIFICATE-----
MIIErDCCAxSgAwIBAgIUImT6dvD09I4yGowOKIyYCFwCU/IwDQYJKoZIhvcNAQEL
BQAwdDEVMBMGA1UEAxMMbG9jYWxob3N0IENBMR4wHAYDVQQKDBVHw7Z0ZWJvcmcg
Qml0IEZhY3RvcnkxEjAQBgNVBAcMCUfDtnRlYm9yZzEaMBgGA1UECAwRVsOkc3Ry
YSBHw7Z0YWxhbmQxCzAJBgNVBAYTAlNFMB4XDTE5MDMwMzE1MDAzOVoXDTIwMDMw
MjE1MDAzOVowNDESMBAGA1UEAxMJbG9jYWxob3N0MR4wHAYDVQQKDBVHw7Z0ZWJv
cmcgQml0IEZhY3RvcnkwggGiMA0GCSqGSIb3DQEBAQUAA4IBjwAwggGKAoIBgQDm
SHBv3zILItaJrG+3y7dWgvsX6X3FzLVXOrhFOBNbsrHSsktt20yHZhofoelkgtlc
kBsft5GUYGEBZuJIIFcOvpbXXTz/cYge8WhpcFo64APNc7zxykaTeIHMmEqjxqtO
efyOmuEyWya2XbCA4aZ6emyirkem952wBJNYLIWoy53YQ79dFvH2SOWKPlXCa1B/
ih7b9qYZE2XHoLQSbLCJqDWoQTxmOe13/1aKnJIuIy/igGsM7ygmphG4kzvyfbiA
o+Nd50USVeeeF8P+X2YZfXFKmbzJTg4q6UUB4vqn4XegW065eIyN1Xw3Z/l8CiP0
G27iuk/ZfRuz00+d9oTG5OtvyCMcc/kDI4Db1Xu9C5z9UpF5IIM85Ky91YxMMqPu
ChQQoDXJ7mdtC7zRvn6t0erMVbpaqyXxKll/ybPFAZYIgV7jtSPPJDAcTsCZQLRc
VcggScYSiWkRgW+DKsECczo++6577q++cyRBtENPOXUZ6J74eKBHizYda0chVzcC
AwEAAaN2MHQwDAYDVR0TAQH/BAIwADATBgNVHSUEDDAKBggrBgEFBQcDAjAPBgNV
HQ8BAf8EBQMDB6AAMB0GA1UdDgQWBBQuQdj0wAQOzML5AQ13xsb4E8Vh9DAfBgNV
HSMEGDAWgBSmHbkkwFmCruE7I7TSI0SlD1hLiDANBgkqhkiG9w0BAQsFAAOCAYEA
CD77JzLXB0YbgJrrkotw0I8rmrb8mw0tHkDGH70UyG6VhEt3vaYcYioxs3TIo23U
dhOTApGdHzjrZePa0y2Kh7YtnPLAUml6hHTATE1D7Hufdtamd56URgBrEylKkpKl
6UnwHWzlkdRWzPRo+RD9RMBzTUMiooZaP9zzzYQNEfCmMTlHqztOLPNfFR6kFLr5
Xnc04EV/hvkByoBmo9/i4qAa3AW4y6cUHYpxVS9nBF2h364aDIIA0mn9hEewRJBq
3odng4d+e9v9b+G1ExQXM3en39REo/b73P2VATZyMxmq5gxL1OmbOa13A+S2D0Og
OkqNq6vzRhTxLbkqc0fjKv2TUFrnYCsCROvrMF+TAN0mG4NcfgeeziBTmHJq0D3I
LNTRMU/BoMYG3wGu0BUak83a9JhwViR3o0iFnctuMbD2Mz6QOawgWz8BuTcwIur6
USeERs3+G2XX499wWswGgWK5JGZ1skD1PiRsZfuaCMJHBiWolv4/G+My5IYg6B8a
-----END CERTIFICATE-----

182
test/test_certs/api.key.pem Normal file
View File

@@ -0,0 +1,182 @@
Public Key Info:
Public Key Algorithm: RSA
Key Security Level: High (3072 bits)
modulus:
00:e6:48:70:6f:df:32:0b:22:d6:89:ac:6f:b7:cb:b7
56:82:fb:17:e9:7d:c5:cc:b5:57:3a:b8:45:38:13:5b
b2:b1:d2:b2:4b:6d:db:4c:87:66:1a:1f:a1:e9:64:82
d9:5c:90:1b:1f:b7:91:94:60:61:01:66:e2:48:20:57
0e:be:96:d7:5d:3c:ff:71:88:1e:f1:68:69:70:5a:3a
e0:03:cd:73:bc:f1:ca:46:93:78:81:cc:98:4a:a3:c6
ab:4e:79:fc:8e:9a:e1:32:5b:26:b6:5d:b0:80:e1:a6
7a:7a:6c:a2:ae:47:a6:f7:9d:b0:04:93:58:2c:85:a8
cb:9d:d8:43:bf:5d:16:f1:f6:48:e5:8a:3e:55:c2:6b
50:7f:8a:1e:db:f6:a6:19:13:65:c7:a0:b4:12:6c:b0
89:a8:35:a8:41:3c:66:39:ed:77:ff:56:8a:9c:92:2e
23:2f:e2:80:6b:0c:ef:28:26:a6:11:b8:93:3b:f2:7d
b8:80:a3:e3:5d:e7:45:12:55:e7:9e:17:c3:fe:5f:66
19:7d:71:4a:99:bc:c9:4e:0e:2a:e9:45:01:e2:fa:a7
e1:77:a0:5b:4e:b9:78:8c:8d:d5:7c:37:67:f9:7c:0a
23:f4:1b:6e:e2:ba:4f:d9:7d:1b:b3:d3:4f:9d:f6:84
c6:e4:eb:6f:c8:23:1c:73:f9:03:23:80:db:d5:7b:bd
0b:9c:fd:52:91:79:20:83:3c:e4:ac:bd:d5:8c:4c:32
a3:ee:0a:14:10:a0:35:c9:ee:67:6d:0b:bc:d1:be:7e
ad:d1:ea:cc:55:ba:5a:ab:25:f1:2a:59:7f:c9:b3:c5
01:96:08:81:5e:e3:b5:23:cf:24:30:1c:4e:c0:99:40
b4:5c:55:c8:20:49:c6:12:89:69:11:81:6f:83:2a:c1
02:73:3a:3e:fb:ae:7b:ee:af:be:73:24:41:b4:43:4f
39:75:19:e8:9e:f8:78:a0:47:8b:36:1d:6b:47:21:57
37:
public exponent:
01:00:01:
private exponent:
00:8b:e2:40:fa:93:f8:10:2f:af:66:9d:ea:97:19:16
5b:64:e1:26:1b:5d:9d:43:c6:7c:20:5d:43:1e:d7:13
82:ae:e6:30:0c:05:c5:8a:ed:4c:a6:5d:c4:ba:c3:a5
80:67:eb:d9:ae:20:92:3c:31:77:7b:a4:85:9c:0e:99
13:89:ce:93:30:3e:17:65:5d:ac:7e:34:50:a8:41:07
36:80:d8:d2:8f:59:c8:e7:aa:39:2f:8f:9a:8a:ec:85
88:15:f9:9f:e2:f8:4e:07:8a:bb:2f:58:26:19:83:f8
de:b9:73:38:36:e9:ab:91:0a:a6:9b:80:ed:b4:cd:d4
45:2b:b2:ed:24:57:65:d2:c1:2a:72:d4:d1:1c:c3:26
f1:15:28:4f:aa:8a:5f:47:28:33:51:5a:5b:48:3d:e1
d7:1c:e8:cb:36:25:7c:6b:7f:c6:be:c2:51:1c:de:e7
4b:d4:90:a0:35:66:fb:f7:c5:d2:67:3d:59:a2:b6:a0
8a:c6:03:8b:db:3a:39:32:28:21:ba:11:3b:a3:77:90
59:0d:72:81:01:ad:5f:66:92:b5:6c:61:d2:8c:60:eb
e5:62:8d:5c:71:72:99:7c:12:b8:1c:c6:ba:ee:64:17
41:04:b6:d2:59:f0:1a:0f:74:ca:d5:19:1e:98:f4:61
75:c3:e1:50:27:af:fa:48:87:3d:c9:11:aa:70:3e:56
64:a1:dc:42:d9:16:a6:d2:14:98:48:cd:ad:d2:09:33
00:10:5f:3c:69:36:81:96:75:44:f8:56:95:d2:e5:76
85:41:85:8d:f1:64:14:05:6b:f7:2a:26:6a:d9:f0:b9
d0:de:d6:3d:7e:7c:6c:2c:26:49:22:5e:2a:04:21:4f
c9:d7:3c:a1:1b:7b:d1:27:1d:80:38:25:57:7f:a2:99
46:d7:60:56:e6:5d:50:71:36:b6:af:a6:5b:d0:92:d8
19:0e:86:4b:3b:34:cf:cd:ea:e5:35:e4:4e:65:e3:20
91:
prime1:
00:f7:07:aa:be:24:f1:2f:26:ea:0e:45:86:b0:45:05
df:b8:59:d6:3b:40:5c:dd:c8:bf:18:3e:76:74:e8:31
35:ca:b0:d4:63:df:4d:4c:d5:0c:46:6e:31:71:3c:17
5e:45:4e:5c:a1:96:4f:69:5e:92:bd:e8:09:27:85:50
e3:29:1d:bb:8e:f9:2c:41:af:0f:c8:e0:d3:70:6a:d4
b9:67:43:08:e4:4a:c9:12:f6:d2:7e:7d:bc:69:52:ba
48:96:0a:7e:42:e7:6e:82:e8:0c:6c:1b:a5:01:f0:36
2c:ae:a4:2f:d8:62:ef:ab:1c:47:3a:98:79:40:68:dd
de:6a:b4:8c:53:03:09:78:11:27:36:6f:e4:2b:fb:f4
4d:bf:13:30:37:1f:51:fd:2f:84:d9:b9:62:ea:91:a8
e8:72:9d:78:14:bd:5a:9e:1f:06:12:70:19:bd:3b:80
b2:5c:33:8b:d6:5b:9c:2f:f9:12:46:55:4a:5a:10:bc
f5:
prime2:
00:ee:a5:18:9e:e5:9a:59:d4:d9:0c:42:4c:cf:a1:d7
ca:8f:b5:45:24:59:f9:83:1f:f4:f2:82:01:50:3c:e0
ae:bf:17:39:09:cd:5a:71:dd:ab:9e:b6:d6:1e:47:dc
34:eb:28:c0:4c:77:e5:05:5d:e3:0a:57:bf:65:1f:f8
29:68:08:45:ee:da:01:bc:57:c6:35:a7:2c:82:62:64
2a:cd:46:eb:54:eb:27:e2:eb:d5:d3:d3:04:ef:05:a1
4c:63:ec:d4:23:6f:60:02:71:a8:c3:ab:a5:2f:26:4e
ea:e1:a3:f5:e4:d2:59:19:c9:26:18:c5:4d:45:1e:61
1d:53:7c:6a:83:d2:18:40:dd:10:af:e8:24:09:1a:06
9b:f1:51:33:8e:13:e0:ce:18:b3:f0:8b:f3:9d:12:b3
e7:88:01:a1:c1:38:0d:c9:c6:0e:49:99:37:2f:be:60
e3:37:9d:c6:a8:cb:4b:c5:c0:49:2a:5d:fb:f2:fb:e7
fb:
coefficient:
22:52:c4:c2:c3:dd:30:13:54:c7:95:54:b2:cb:24:b5
0c:88:f4:22:a7:6a:13:b3:17:5f:0b:b2:8c:4f:2c:e6
d3:b6:ca:cd:e6:70:e4:37:5d:65:16:50:ae:b8:cc:bf
80:81:3d:e5:5c:0e:6d:ec:f9:4e:f5:49:00:fd:63:28
2a:ab:03:92:ae:b6:a6:97:ed:f0:97:25:55:06:3f:15
be:cf:70:22:bd:af:f8:2c:3f:ce:d5:e5:e6:5f:94:d7
d2:0a:fb:99:d7:ad:ab:d1:3a:b8:fb:6c:b0:47:1c:60
81:b1:8c:5e:df:25:8b:93:82:8c:28:52:99:5e:e7:e7
f8:fc:30:48:bd:43:82:9e:39:2b:7b:14:6b:fb:1b:8a
7d:f1:1e:06:01:ca:7d:59:54:79:00:fa:76:bd:a9:a1
02:ad:c4:7e:0b:56:c2:37:6b:7d:20:5f:53:ef:46:88
cf:24:e2:4c:25:fc:98:49:40:38:10:19:6f:3c:18:4c
exp1:
00:8b:1e:3a:3e:13:37:f0:c2:0d:96:33:f9:82:53:9c
d7:3d:4e:fa:a3:2b:c0:20:f6:e9:07:92:45:cb:d8:e7
bd:cf:84:7e:58:30:6d:ac:13:5f:72:5a:a4:65:8c:dd
ec:2d:43:d0:4f:00:03:80:e7:cd:e4:3d:44:ca:88:fd
e0:b0:4b:1a:51:8e:6a:2a:23:98:d4:1c:29:77:69:f2
9a:e7:58:8d:2d:64:20:91:19:87:b9:cc:bd:ca:e2:d8
1e:00:c1:b0:11:a5:9c:4b:04:bb:da:36:47:5b:2c:18
96:59:54:05:cd:eb:09:e6:67:6a:85:c9:50:9f:c1:6f
11:cf:2e:16:c8:b9:31:1f:f9:29:08:33:43:60:b1:e8
07:d0:cf:d1:9b:79:7c:07:06:37:df:15:d4:6b:1d:d4
ed:f3:7e:53:1d:fa:f5:89:8f:17:30:53:09:6b:d4:92
c9:df:ba:f7:c9:a4:95:f5:3e:63:d8:50:38:2b:38:b9
f1:
exp2:
00:ed:06:45:41:ec:c2:35:5e:d6:84:fa:84:d7:e4:e3
33:69:30:9d:8f:d1:5d:a5:02:e4:82:c8:e5:0d:10:aa
08:65:fb:66:c7:79:92:cf:6d:5f:bb:af:d5:53:16:04
7c:fa:e3:ea:bb:08:8a:0b:9e:88:96:09:39:2b:f3:68
c3:97:74:40:21:4f:9e:51:b6:cc:43:15:db:7b:54:c6
30:4c:da:97:7a:2c:65:dd:58:67:74:90:2e:62:48:b1
3f:f2:2f:93:33:ee:b6:e9:36:82:6c:75:db:06:cd:81
ac:80:98:1c:ee:3c:8e:0a:b2:62:88:4f:ce:c3:4b:bd
21:27:7e:77:3c:9e:3b:40:91:50:b5:a6:57:c4:42:79
36:01:a4:a9:14:00:62:53:d0:ed:47:89:79:59:14:ee
62:94:0f:2a:dd:82:13:0f:c9:0a:ff:c6:91:ad:75:e5
3d:48:4c:08:b8:35:d2:f8:82:57:29:21:57:d0:aa:aa
69:
Public Key PIN:
pin-sha256:SSdvX3918szw/veSWFuQJD3lGynf9mFLiTxpZPj/Jz4=
Public Key ID:
sha256:49276f5f7f75f2ccf0fef792585b90243de51b29dff6614b893c6964f8ff273e
sha1:2e41d8f4c0040eccc2f9010d77c6c6f813c561f4
-----BEGIN RSA PRIVATE KEY-----
MIIG5QIBAAKCAYEA5khwb98yCyLWiaxvt8u3VoL7F+l9xcy1Vzq4RTgTW7Kx0rJL
bdtMh2YaH6HpZILZXJAbH7eRlGBhAWbiSCBXDr6W1108/3GIHvFoaXBaOuADzXO8
8cpGk3iBzJhKo8arTnn8jprhMlsmtl2wgOGmenpsoq5HpvedsASTWCyFqMud2EO/
XRbx9kjlij5VwmtQf4oe2/amGRNlx6C0Emywiag1qEE8Zjntd/9WipySLiMv4oBr
DO8oJqYRuJM78n24gKPjXedFElXnnhfD/l9mGX1xSpm8yU4OKulFAeL6p+F3oFtO
uXiMjdV8N2f5fAoj9Btu4rpP2X0bs9NPnfaExuTrb8gjHHP5AyOA29V7vQuc/VKR
eSCDPOSsvdWMTDKj7goUEKA1ye5nbQu80b5+rdHqzFW6Wqsl8SpZf8mzxQGWCIFe
47UjzyQwHE7AmUC0XFXIIEnGEolpEYFvgyrBAnM6Pvuue+6vvnMkQbRDTzl1Geie
+HigR4s2HWtHIVc3AgMBAAECggGBAIviQPqT+BAvr2ad6pcZFltk4SYbXZ1Dxnwg
XUMe1xOCruYwDAXFiu1Mpl3EusOlgGfr2a4gkjwxd3ukhZwOmROJzpMwPhdlXax+
NFCoQQc2gNjSj1nI56o5L4+aiuyFiBX5n+L4TgeKuy9YJhmD+N65czg26auRCqab
gO20zdRFK7LtJFdl0sEqctTRHMMm8RUoT6qKX0coM1FaW0g94dcc6Ms2JXxrf8a+
wlEc3udL1JCgNWb798XSZz1ZoragisYDi9s6OTIoIboRO6N3kFkNcoEBrV9mkrVs
YdKMYOvlYo1ccXKZfBK4HMa67mQXQQS20lnwGg90ytUZHpj0YXXD4VAnr/pIhz3J
EapwPlZkodxC2Ram0hSYSM2t0gkzABBfPGk2gZZ1RPhWldLldoVBhY3xZBQFa/cq
JmrZ8LnQ3tY9fnxsLCZJIl4qBCFPydc8oRt70ScdgDglV3+imUbXYFbmXVBxNrav
plvQktgZDoZLOzTPzerlNeROZeMgkQKBwQD3B6q+JPEvJuoORYawRQXfuFnWO0Bc
3ci/GD52dOgxNcqw1GPfTUzVDEZuMXE8F15FTlyhlk9pXpK96AknhVDjKR27jvks
Qa8PyODTcGrUuWdDCORKyRL20n59vGlSukiWCn5C526C6AxsG6UB8DYsrqQv2GLv
qxxHOph5QGjd3mq0jFMDCXgRJzZv5Cv79E2/EzA3H1H9L4TZuWLqkajocp14FL1a
nh8GEnAZvTuAslwzi9ZbnC/5EkZVSloQvPUCgcEA7qUYnuWaWdTZDEJMz6HXyo+1
RSRZ+YMf9PKCAVA84K6/FzkJzVpx3auettYeR9w06yjATHflBV3jCle/ZR/4KWgI
Re7aAbxXxjWnLIJiZCrNRutU6yfi69XT0wTvBaFMY+zUI29gAnGow6ulLyZO6uGj
9eTSWRnJJhjFTUUeYR1TfGqD0hhA3RCv6CQJGgab8VEzjhPgzhiz8IvznRKz54gB
ocE4DcnGDkmZNy++YOM3ncaoy0vFwEkqXfvy++f7AoHBAIseOj4TN/DCDZYz+YJT
nNc9TvqjK8Ag9ukHkkXL2Oe9z4R+WDBtrBNfclqkZYzd7C1D0E8AA4DnzeQ9RMqI
/eCwSxpRjmoqI5jUHCl3afKa51iNLWQgkRmHucy9yuLYHgDBsBGlnEsEu9o2R1ss
GJZZVAXN6wnmZ2qFyVCfwW8Rzy4WyLkxH/kpCDNDYLHoB9DP0Zt5fAcGN98V1Gsd
1O3zflMd+vWJjxcwUwlr1JLJ37r3yaSV9T5j2FA4Kzi58QKBwQDtBkVB7MI1XtaE
+oTX5OMzaTCdj9FdpQLkgsjlDRCqCGX7Zsd5ks9tX7uv1VMWBHz64+q7CIoLnoiW
CTkr82jDl3RAIU+eUbbMQxXbe1TGMEzal3osZd1YZ3SQLmJIsT/yL5Mz7rbpNoJs
ddsGzYGsgJgc7jyOCrJiiE/Ow0u9ISd+dzyeO0CRULWmV8RCeTYBpKkUAGJT0O1H
iXlZFO5ilA8q3YITD8kK/8aRrXXlPUhMCLg10viCVykhV9CqqmkCgcAiUsTCw90w
E1THlVSyyyS1DIj0IqdqE7MXXwuyjE8s5tO2ys3mcOQ3XWUWUK64zL+AgT3lXA5t
7PlO9UkA/WMoKqsDkq62ppft8JclVQY/Fb7PcCK9r/gsP87V5eZflNfSCvuZ162r
0Tq4+2ywRxxggbGMXt8li5OCjChSmV7n5/j8MEi9Q4KeOSt7FGv7G4p98R4GAcp9
WVR5APp2vamhAq3EfgtWwjdrfSBfU+9GiM8k4kwl/JhJQDgQGW88GEw=
-----END RSA PRIVATE KEY-----

0
test/tw-1837.t Executable file → Normal file
View File

89
test/tw-2689.t.cpp Normal file
View File

@@ -0,0 +1,89 @@
////////////////////////////////////////////////////////////////////////////////
//
// Copyright 2006 - 2021, Tomas Babej, Paul Beckingham, Federico Hernandez.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// https://www.opensource.org/licenses/mit-license.php
//
////////////////////////////////////////////////////////////////////////////////
#include <iostream>
#include <cmake.h>
#include <stdlib.h>
#include <main.h>
#include <test.h>
////////////////////////////////////////////////////////////////////////////////
int main (int, char**)
{
UnitTest test (12);
// Ensure environment has no influence.
unsetenv ("TASKDATA");
unsetenv ("TASKRC");
// Inform Task about the attributes in the JSON below
Task::attributes["depends"] = "string";
Task::attributes["uuid"] = "string";
// depends in [..] string from a taskserver (issue#2689)
auto sample = "{"
"\"depends\":\"[\\\"92a40a34-37f3-4785-8ca1-ff89cfbfd105\\\",\\\"e08e35fa-e42b-4de0-acc4-518fca8f6365\\\"]\","
"\"uuid\":\"00000000-0000-0000-0000-000000000000\""
"}";
auto json = Task (sample);
auto value = json.get ("uuid");
test.is (value, "00000000-0000-0000-0000-000000000000", "json [..] uuid");
value = json.get ("depends");
test.is (value, "92a40a34-37f3-4785-8ca1-ff89cfbfd105,e08e35fa-e42b-4de0-acc4-518fca8f6365", "json [..] depends");
test.ok (json.has ("dep_92a40a34-37f3-4785-8ca1-ff89cfbfd105"), "json [..] dep attr");
test.ok (json.has ("dep_e08e35fa-e42b-4de0-acc4-518fca8f6365"), "json [..] dep attr");
// depends in comma-delimited string from a taskserver (deprecated format)
sample = "{"
"\"depends\":\"92a40a34-37f3-4785-8ca1-ff89cfbfd105,e08e35fa-e42b-4de0-acc4-518fca8f6365\","
"\"uuid\":\"00000000-0000-0000-0000-000000000000\""
"}";
json = Task (sample);
value = json.get ("uuid");
test.is (value, "00000000-0000-0000-0000-000000000000", "json comma-separated uuid");
value = json.get ("depends");
test.is (value, "92a40a34-37f3-4785-8ca1-ff89cfbfd105,e08e35fa-e42b-4de0-acc4-518fca8f6365", "json comma-separated depends");
test.ok (json.has ("dep_92a40a34-37f3-4785-8ca1-ff89cfbfd105"), "json comma-separated dep attr");
test.ok (json.has ("dep_e08e35fa-e42b-4de0-acc4-518fca8f6365"), "json comma-separated dep attr");
// depends in a JSON array from a taskserver
sample = "{"
"\"depends\":[\"92a40a34-37f3-4785-8ca1-ff89cfbfd105\",\"e08e35fa-e42b-4de0-acc4-518fca8f6365\"],"
"\"uuid\":\"00000000-0000-0000-0000-000000000000\""
"}";
json = Task (sample);
value = json.get ("uuid");
test.is (value, "00000000-0000-0000-0000-000000000000", "json array uuid");
value = json.get ("depends");
test.is (value, "92a40a34-37f3-4785-8ca1-ff89cfbfd105,e08e35fa-e42b-4de0-acc4-518fca8f6365", "json array depends");
test.ok (json.has ("dep_92a40a34-37f3-4785-8ca1-ff89cfbfd105"), "json array dep attr");
test.ok (json.has ("dep_e08e35fa-e42b-4de0-acc4-518fca8f6365"), "json array dep attr");
return 0;
}
////////////////////////////////////////////////////////////////////////////////

View File

@@ -314,7 +314,7 @@ class Test1447(TestCase):
self.t = Task()
def test_filter_uda(self):
"""1447: Verify ability to filter on empty UDA"""
"""1447: Verify ability to filter on empty UDA that resembles named date"""
self.t.config('uda.sep.type', 'string')
self.t('add one')
self.t('add two sep:foo')

View File

@@ -82,6 +82,24 @@ class TestUDAOrphans(TestCase):
code, out, err = self.t("_get 1.description")
self.assertIn("one extra:foo", out)
def test_orphan_identification(self):
"""Verify that orphans are identified by +ORPHAN tag and udas command"""
# Create one task with legitimate orphan attribute and others without
self.t("rc.uda.extra.type:string rc.uda.extra.label:Extra add one extra:foo")
self.t("add two no attributes")
self.t("add three +test ")
self.t("add four +test depends:3")
self.t("4 annotate annotation content")
# Only the first task should be identified as orphan
code, out, err = self.t("+ORPHAN ids")
self.assertEqual("1", out.strip())
# Only the first task should be identified as orphan
code, out, err = self.t("udas")
self.assertRegex(out, r'extra\s+1\s+1 Orphan UDA')
if __name__ == "__main__":
from simpletap import TAPTestRunner

View File

@@ -58,7 +58,7 @@ int main (int, char**)
Task rightAgain (right);
std::string output = left.diff (right);
t.ok (left.data != right.data, "Detected changes");
t.ok (!(left == right), "Detected changes");
t.ok (output.find ("Zero will be changed from '0' to '00'") != std::string::npos, "Detected change zero:0 -> zero:00");
t.ok (output.find ("One will be deleted") != std::string::npos, "Detected deletion one:1 ->");
t.ok (output.find ("Two") == std::string::npos, "Detected no change two:2 -> two:2");

View File

@@ -77,11 +77,6 @@ class TestVersion(TestCase):
self.assertIn("MIT license", out)
self.assertIn("https://taskwarrior.org", out)
def slurp_git(self):
git_cmd = ("git", "rev-parse", "--short", "--verify", "HEAD")
_, hash, _ = run_cmd_wait(git_cmd)
return hash.rstrip("\n")
def test_under_version(self):
"""_version and diagnostics output expected version and syntax"""
code, out, err = self.t("_version")
@@ -94,8 +89,7 @@ class TestVersion(TestCase):
if os.path.exists("../.git"):
if 2 >= len(version) > 0:
git = version[1]
git_expected = "({0})".format(self.slurp_git())
self.assertEqual(git_expected, git)
self.assertRegex(git, r'\([a-f0-9]*\)'))
else:
raise ValueError("Unexpected output from _version '{0}'".format(
out))

View File

@@ -87,14 +87,18 @@ class Test1486(TestCase):
def test_waiting(self):
"""1486: Verify waiting report shows waiting tasks"""
self.t.config('uda.sep.type', 'string')
self.t('add regular')
self.t('add waited wait:later')
self.t('add waited and pending wait:later')
self.t('add waited but deleted wait:later')
self.t('add waited but done wait:later')
self.t('rc.confirmation=off 3 delete')
self.t('4 done')
code, out, err = self.t('waiting')
self.assertEqual(0, code, "Exit code was non-zero ({0})".format(code))
self.assertIn('waited', out)
self.assertIn('waited and pending', out)
self.assertNotIn('waited but deleted', out)
self.assertNotIn('waited but done', out)
self.assertNotIn('regular', out)