whatnext 3.2__tar.gz → 3.3.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (123) hide show
  1. {whatnext-3.2 → whatnext-3.3.1}/CHANGELOG.md +19 -0
  2. {whatnext-3.2 → whatnext-3.3.1}/PKG-INFO +1 -1
  3. {whatnext-3.2 → whatnext-3.3.1}/docs/next.md +6 -0
  4. {whatnext-3.2 → whatnext-3.3.1}/tasks/next.md +2 -2
  5. {whatnext-3.2 → whatnext-3.3.1}/tasks/summaries.md +1 -0
  6. {whatnext-3.2 → whatnext-3.3.1}/tests/colour.bats +49 -0
  7. {whatnext-3.2 → whatnext-3.3.1}/tests/headerless/annotation.md +1 -0
  8. {whatnext-3.2 → whatnext-3.3.1}/tests/list.bats +1 -0
  9. whatnext-3.3.1/tests/next/wide.md +5 -0
  10. whatnext-3.3.1/tests/next/wrapped.md +4 -0
  11. {whatnext-3.2 → whatnext-3.3.1}/tests/next.bats +332 -54
  12. {whatnext-3.2 → whatnext-3.3.1}/tests/test_file.py +57 -0
  13. {whatnext-3.2 → whatnext-3.3.1}/whatnext/models.py +12 -2
  14. {whatnext-3.2 → whatnext-3.3.1}/whatnext/next.py +150 -67
  15. {whatnext-3.2 → whatnext-3.3.1}/whatnext/summary.py +10 -13
  16. {whatnext-3.2 → whatnext-3.3.1}/whatnext/whatnext.py +0 -1
  17. {whatnext-3.2 → whatnext-3.3.1}/.flake8 +0 -0
  18. {whatnext-3.2 → whatnext-3.3.1}/.github/dependabot.yml +0 -0
  19. {whatnext-3.2 → whatnext-3.3.1}/.github/workflows/publish.yml +0 -0
  20. {whatnext-3.2 → whatnext-3.3.1}/.github/workflows/tests.yml +0 -0
  21. {whatnext-3.2 → whatnext-3.3.1}/.gitignore +0 -0
  22. {whatnext-3.2 → whatnext-3.3.1}/.whatnext +0 -0
  23. {whatnext-3.2 → whatnext-3.3.1}/LICENCE +0 -0
  24. {whatnext-3.2 → whatnext-3.3.1}/LICENSE +0 -0
  25. {whatnext-3.2 → whatnext-3.3.1}/Makefile +0 -0
  26. {whatnext-3.2 → whatnext-3.3.1}/README.md +0 -0
  27. {whatnext-3.2 → whatnext-3.3.1}/archive/done/tasks.md +0 -0
  28. {whatnext-3.2 → whatnext-3.3.1}/docs/annotations.md +0 -0
  29. {whatnext-3.2 → whatnext-3.3.1}/docs/basics.md +0 -0
  30. {whatnext-3.2 → whatnext-3.3.1}/docs/deadlines.md +0 -0
  31. {whatnext-3.2 → whatnext-3.3.1}/docs/deferring.md +0 -0
  32. {whatnext-3.2 → whatnext-3.3.1}/docs/exclusions.md +0 -0
  33. {whatnext-3.2 → whatnext-3.3.1}/docs/index.md +0 -0
  34. {whatnext-3.2 → whatnext-3.3.1}/docs/installation.md +0 -0
  35. {whatnext-3.2 → whatnext-3.3.1}/docs/prioritisation.md +0 -0
  36. {whatnext-3.2 → whatnext-3.3.1}/docs/sequential.md +0 -0
  37. {whatnext-3.2 → whatnext-3.3.1}/docs/usage.md +0 -0
  38. {whatnext-3.2 → whatnext-3.3.1}/example/archived/projects/tangerine.md +0 -0
  39. {whatnext-3.2 → whatnext-3.3.1}/example/projects/curtain.md +0 -0
  40. {whatnext-3.2 → whatnext-3.3.1}/example/projects/fountain.md +0 -0
  41. {whatnext-3.2 → whatnext-3.3.1}/example/projects/harvest.md +0 -0
  42. {whatnext-3.2 → whatnext-3.3.1}/example/projects/obelisk.md +0 -0
  43. {whatnext-3.2 → whatnext-3.3.1}/example/projects/tinsel.md +0 -0
  44. {whatnext-3.2 → whatnext-3.3.1}/example/tasks.md +0 -0
  45. {whatnext-3.2 → whatnext-3.3.1}/example/template.md +0 -0
  46. {whatnext-3.2 → whatnext-3.3.1}/pyproject.toml +0 -0
  47. {whatnext-3.2 → whatnext-3.3.1}/scripts/update-usage-examples.py +0 -0
  48. {whatnext-3.2 → whatnext-3.3.1}/tasks/deferring.md +0 -0
  49. {whatnext-3.2 → whatnext-3.3.1}/tasks/documentation.md +0 -0
  50. {whatnext-3.2 → whatnext-3.3.1}/tasks/ignoring.md +0 -0
  51. {whatnext-3.2 → whatnext-3.3.1}/tasks/listing.md +0 -0
  52. {whatnext-3.2 → whatnext-3.3.1}/tasks/test_refactor.md +0 -0
  53. {whatnext-3.2 → whatnext-3.3.1}/tasks/version_0.1.md +0 -0
  54. {whatnext-3.2 → whatnext-3.3.1}/tasks/version_0.2.md +0 -0
  55. {whatnext-3.2 → whatnext-3.3.1}/tasks/version_0.3.md +0 -0
  56. {whatnext-3.2 → whatnext-3.3.1}/tasks/version_0.4.md +0 -0
  57. {whatnext-3.2 → whatnext-3.3.1}/tasks/version_0.5.md +0 -0
  58. {whatnext-3.2 → whatnext-3.3.1}/tasks/version_1.0.md +0 -0
  59. {whatnext-3.2 → whatnext-3.3.1}/tasks/version_1.1.md +0 -0
  60. {whatnext-3.2 → whatnext-3.3.1}/tasks/version_1.2.md +0 -0
  61. {whatnext-3.2 → whatnext-3.3.1}/tasks/version_1.3.md +0 -0
  62. {whatnext-3.2 → whatnext-3.3.1}/tasks.md +0 -0
  63. {whatnext-3.2 → whatnext-3.3.1}/tests/config/.whatnext +0 -0
  64. {whatnext-3.2 → whatnext-3.3.1}/tests/config/.whatnext.alt +0 -0
  65. {whatnext-3.2 → whatnext-3.3.1}/tests/config/apples.md +0 -0
  66. {whatnext-3.2 → whatnext-3.3.1}/tests/config/oranges.md +0 -0
  67. {whatnext-3.2 → whatnext-3.3.1}/tests/config-external +0 -0
  68. {whatnext-3.2 → whatnext-3.3.1}/tests/config.bats +0 -0
  69. {whatnext-3.2 → whatnext-3.3.1}/tests/deadline.bats +0 -0
  70. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/bare-after.md +0 -0
  71. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/circular-a.md +0 -0
  72. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/circular-b.md +0 -0
  73. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/deferred.md +0 -0
  74. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/duplicate-warnings.md +0 -0
  75. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/missing-dep.md +0 -0
  76. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/needs-absolute.md +0 -0
  77. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/needs-subdir.md +0 -0
  78. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/phase-misplaced.md +0 -0
  79. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/phases-empty.md +0 -0
  80. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/phases-partial.md +0 -0
  81. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/phases-queue.md +0 -0
  82. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/phases.md +0 -0
  83. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/regular.md +0 -0
  84. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/root-target.md +0 -0
  85. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/samename.md +0 -0
  86. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/subdir/needs-parent.md +0 -0
  87. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/subdir/needs-sibling.md +0 -0
  88. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/subdir/samename.md +0 -0
  89. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring/subdir/target.md +0 -0
  90. {whatnext-3.2 → whatnext-3.3.1}/tests/deferring.bats +0 -0
  91. {whatnext-3.2 → whatnext-3.3.1}/tests/edit.bats +0 -0
  92. {whatnext-3.2 → whatnext-3.3.1}/tests/headerless/deadline.md +0 -0
  93. {whatnext-3.2 → whatnext-3.3.1}/tests/housekeeping.bats +0 -0
  94. {whatnext-3.2 → whatnext-3.3.1}/tests/invalid.md +0 -0
  95. {whatnext-3.2 → whatnext-3.3.1}/tests/matching.bats +0 -0
  96. {whatnext-3.2 → whatnext-3.3.1}/tests/next/alternate.md +0 -0
  97. {whatnext-3.2 → whatnext-3.3.1}/tests/next/append-after.md +0 -0
  98. {whatnext-3.2 → whatnext-3.3.1}/tests/next/append.md +0 -0
  99. {whatnext-3.2 → whatnext-3.3.1}/tests/next/empty.md +0 -0
  100. {whatnext-3.2 → whatnext-3.3.1}/tests/next/insert.md +0 -0
  101. {whatnext-3.2 → whatnext-3.3.1}/tests/next/projects/alpha/tasks/things.md +0 -0
  102. {whatnext-3.2 → whatnext-3.3.1}/tests/next/projects/alpha/tasks.md +0 -0
  103. {whatnext-3.2 → whatnext-3.3.1}/tests/next/projects/beta/things.md +0 -0
  104. {whatnext-3.2 → whatnext-3.3.1}/tests/next/something.txt +0 -0
  105. {whatnext-3.2 → whatnext-3.3.1}/tests/next/tasks.md +0 -0
  106. {whatnext-3.2 → whatnext-3.3.1}/tests/notnext.bats +0 -0
  107. {whatnext-3.2 → whatnext-3.3.1}/tests/queue/all-complete.md +0 -0
  108. {whatnext-3.2 → whatnext-3.3.1}/tests/queue/blocked.md +0 -0
  109. {whatnext-3.2 → whatnext-3.3.1}/tests/queue/in-progress.md +0 -0
  110. {whatnext-3.2 → whatnext-3.3.1}/tests/queue/normal.md +0 -0
  111. {whatnext-3.2 → whatnext-3.3.1}/tests/queue/prioritised.md +0 -0
  112. {whatnext-3.2 → whatnext-3.3.1}/tests/queue.bats +0 -0
  113. {whatnext-3.2 → whatnext-3.3.1}/tests/summary.bats +0 -0
  114. {whatnext-3.2 → whatnext-3.3.1}/tests/test_defer.py +0 -0
  115. {whatnext-3.2 → whatnext-3.3.1}/tests/test_edit.py +0 -0
  116. {whatnext-3.2 → whatnext-3.3.1}/tests/test_limit.py +0 -0
  117. {whatnext-3.2 → whatnext-3.3.1}/tests/test_output.py +0 -0
  118. {whatnext-3.2 → whatnext-3.3.1}/tests/test_summary.py +0 -0
  119. {whatnext-3.2 → whatnext-3.3.1}/tests/test_task.py +0 -0
  120. {whatnext-3.2 → whatnext-3.3.1}/tests/usage.bats +0 -0
  121. {whatnext-3.2 → whatnext-3.3.1}/tests/version.bats +0 -0
  122. {whatnext-3.2 → whatnext-3.3.1}/whatnext/__init__.py +0 -0
  123. {whatnext-3.2 → whatnext-3.3.1}/whatnext/guide.txt +0 -0
@@ -1,6 +1,25 @@
1
1
  # Changelog
2
2
 
3
3
 
4
+ ## [v3.4] - 2026-04-17
5
+
6
+ **Fixes:** Empty tasks (`- [ ]\n`) no longer cause a stacktrace.
7
+
8
+
9
+ ## [v3.3] - 2026-04-13
10
+
11
+ **Added:**
12
+ - `next` reads from stdin when no task text is provided, allowing piping of
13
+ multiple tasks (one per line) into a file.
14
+ - `next` wraps the text of added tasks, to a default of 80 chars, which can be
15
+ overriden in the config `wrap_width` setting, or `WHATNEXT_WRAP_WIDTH`. If
16
+ the file has any existing lines longer than that, the file takes precedence
17
+ and the text is instead wrapped to match that longer width.
18
+ - `next --config {file}` specifies a non-default location config file,
19
+ or set `WHATNEXT_CONFIG`.
20
+ - Summary totals line is now shown in yellow as a differentiator.
21
+
22
+
4
23
  ## [v3.2] - 2026-04-09
5
24
 
6
25
  **Added:**
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: whatnext
3
- Version: 3.2
3
+ Version: 3.3.1
4
4
  Summary: A lister of tasks found in Markdown files
5
5
  Project-URL: Homepage, https://github.com/norm/whatnext
6
6
  Project-URL: Repository, https://github.com/norm/whatnext
@@ -63,3 +63,9 @@ Once the file is chosen, the file is checked for Markdown headings.
63
63
 
64
64
  If you would prefer the task is always added at the end of the file,
65
65
  set `$WHATNEXT_APPEND_ONLY` to a value, or use `next -a`.
66
+
67
+
68
+ ## The task text
69
+
70
+ The task text is all remaining arguments as a string. If no arguments remain,
71
+ `next` reads from stdin, with multiple lines making multiple tasks.
@@ -3,7 +3,7 @@
3
3
  - [X] next should add to tasks.md in cwd before home
4
4
  - [ ] next should have -e too, to edit task files
5
5
  - [X] show diff when adding task with next
6
- - [ ] next reads stdin to add multiple tasks at once?
7
- - [ ] wrap text to a maximum width when adding to the task file;
6
+ - [X] next reads stdin to add multiple tasks at once
7
+ - [X] wrap text to a maximum width when adding to the task file;
8
8
  .whatnext config and env var
9
9
  - [ ] directive in a file to tell `next` where to put new tasks
@@ -1,3 +1,4 @@
1
1
  Improvements to `--summary` output.
2
2
 
3
3
  - [X] show total %age progression across project, not just column totals
4
+ - [X] show total %age in a different colour
@@ -30,6 +30,31 @@ EOF
30
30
  [ $status -eq 0 ]
31
31
  }
32
32
 
33
+ @test "force colour output in summary" {
34
+ cd example
35
+
36
+ b=$'\033[34m'
37
+ r=$'\033[0m'
38
+ COLUMNS=40 \
39
+ WHATNEXT_TODAY=2025-01-01 \
40
+ run --separate-stderr \
41
+ whatnext \
42
+ --color \
43
+ --summary \
44
+ --open \
45
+ tasks.md
46
+
47
+ expected_output=$(sed -e 's/^ //' <<EOF
48
+ O
49
+ ${b}█████████████████████████${r} 3 tasks.md
50
+
51
+ █ Open
52
+ EOF
53
+ )
54
+ diff -u <(echo "$expected_output") <(echo "$output")
55
+ [ $status -eq 0 ]
56
+ }
57
+
33
58
  @test "disable colour output" {
34
59
  WHATNEXT_TODAY=2025-12-25 \
35
60
  WHATNEXT_COLOR=1 \
@@ -58,3 +83,27 @@ EOF
58
83
  diff -u <(echo "$expected_output") <(echo "$output")
59
84
  [ $status -eq 0 ]
60
85
  }
86
+
87
+ @test "disable colour output in summary" {
88
+ cd example
89
+
90
+ COLUMNS=40 \
91
+ WHATNEXT_TODAY=2025-01-01 \
92
+ WHATNEXT_COLOR=1 \
93
+ run --separate-stderr \
94
+ whatnext \
95
+ --no-color \
96
+ --summary \
97
+ --open \
98
+ tasks.md
99
+
100
+ expected_output=$(sed -e 's/^ //' <<" EOF"
101
+ O
102
+ █████████████████████████ 3 tasks.md
103
+
104
+ █ Open
105
+ EOF
106
+ )
107
+ diff -u <(echo "$expected_output") <(echo "$output")
108
+ [ $status -eq 0 ]
109
+ }
@@ -3,3 +3,4 @@ This annotation should appear even without a heading.
3
3
  ```
4
4
 
5
5
  - [ ] a task without heading
6
+ - [ ]
@@ -687,6 +687,7 @@ function setup {
687
687
  ../tests/headerless/annotation.md:
688
688
  This annotation should appear even without a heading.
689
689
  - [ ] a task without heading
690
+ - [ ]
690
691
  EOF
691
692
  )
692
693
  diff -u <(echo "$expected_output") <(echo "$output")
@@ -0,0 +1,5 @@
1
+ This line of context is deliberately written to be extraordinarily long, much longer than any task line in this file, to prove the script measures task width not arbitrary line width.
2
+
3
+ - [ ] short task
4
+ - [ ] another short task
5
+ - [ ] This is an existing task that is deliberately written to be wider than eighty characters on a single line
@@ -0,0 +1,4 @@
1
+ # Tasks @after tasks.md
2
+
3
+ - [ ] the continuation line is deliberately longer than the first line in
4
+ order to confirm that width detection occurs across the entire task not just the first line