tasku 0.4.0 → 0.4.1
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +97 -0
- data/lib/tasku/cli.rb +25 -1
- data/lib/tasku/tui/mado_list.rb +14 -2
- data/lib/tasku/version.rb +1 -1
- metadata +9 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 206dc71e9498feb028e4c8b05fc3de8a23d6073b1da9db0988ef0acea3fc5f5d
|
|
4
|
+
data.tar.gz: 58dacb2562825ff61794649652c617b3ea7a4a619804a32c56067ff5ef2fd1ef
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 719c9a295c5868d5dbeb152e35cacde49d5be9f2ad229e2818a20d3eeaecf6ae86c461ea27e2d921c5b15ecbb48f0180f3e4c4ddc56d020dd36baaf5d901fb3e
|
|
7
|
+
data.tar.gz: 3c09b8f6970813d4a73d0772c2a92530d9e5958ad22f9fdd52c77a4f6fdc0a1b132af902ee59ba75060b25227695b48f7b22cf30541990cc763a4de41d5216c0
|
data/CHANGELOG.md
ADDED
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to Tasku are documented here.
|
|
4
|
+
|
|
5
|
+
## [0.4.1] - 2026-09-29
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
- **Cloud sync: project colours now sync down** — `tasku cloud sync` applied only the tasks from the server's response and ignored its `projects`, so colours set on another machine never arrived. They are now created or updated locally, and the sync summary reports how many changed. In Mado this also restores project colours and workspaces on a freshly synced machine
|
|
9
|
+
|
|
10
|
+
## [0.4.0] - 2026-09-23
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
- **Tasku Cloud sync** — two-way sync with `tasku cloud sync`; authenticate with `tasku cloud login <token>`, check status with `tasku cloud status`, and revoke with `tasku cloud logout`
|
|
14
|
+
- **`tasku config open`** — opens the config file in `$EDITOR` pre-seeded with all available keys and their defaults
|
|
15
|
+
- **Numeric range preferences** — config keys that accept a numeric range (e.g. column minimum widths) now show their valid range in `tasku config list`
|
|
16
|
+
- **`--code` flag** on `add` and `edit` — attach a short code to a task (e.g. `MDO-42`)
|
|
17
|
+
- **`tasku sql`** — run a raw SQL `SELECT` query against the local database
|
|
18
|
+
- **Category filtering** — `tasku list --category` and category column in list output
|
|
19
|
+
- **Column visibility preferences** — `col_project`, `col_category`, `col_priority`, `col_status`, `col_due` can each be toggled `on`/`off` via `tasku config set`
|
|
20
|
+
- **Column minimum width preferences** — `col_name_min`, `col_priority_min`, `col_status_min`, `col_due_min` for fine-tuning layout
|
|
21
|
+
- **`tasku config open`** — open the config JSON in `$EDITOR` (pre-seeded with defaults)
|
|
22
|
+
- **UUID field** on tasks for stable cross-device identity during cloud sync
|
|
23
|
+
|
|
24
|
+
### Fixed
|
|
25
|
+
- **Mado: status filter preserved after add/edit/delete** — `MadoList` now receives the full `list_cmd` (including `--status`, `--today`, `--overdue`, etc.) and passes it to `exec` on return, so the active view is restored correctly after an interactive command
|
|
26
|
+
- **Mado: project filter preserved after add/edit/delete** — the inline-exec protocol (`\x02`) now replaces the MadoList process via `exec` instead of nesting it in a `system()` call, so the new MadoList inherits the correct `@list_cmd` and filter is preserved when navigating back from an interactive command
|
|
27
|
+
- **Mado: project filter lost on workspace switch** — the open-panel flag is now tracked correctly for sidebar-positioned Tasku (not just the top-bar overlay), so switching workspace reliably refreshes the task list with the new project filter
|
|
28
|
+
- **Mado: terminal left in raw mode after inline exec** — `$stdin.cooked!` is now called before `exec` when handling a `\x02tasku list` command, preventing the shell from inheriting raw-mode terminal attributes
|
|
29
|
+
- **Due date column truncation** — `DUE_COL_MIN_WIDTH` raised to 17 to accommodate the longest possible due cell (`"Mmm DD (NNNd ago)"`)
|
|
30
|
+
- **MadoList row overflow** — row prefix accounting corrected to 6 characters (`" [>] "`), matching the actual rendered prefix; was previously 4, causing rows to exceed terminal width and wrap
|
|
31
|
+
- **Name truncation** — task names that exceed available space are now truncated with `…`; names that fit are never truncated, fixing cases where the due-date column wrapped to the next line
|
|
32
|
+
- **Column auto-drop on narrow terminals** — optional columns (project → category → priority → status) are dropped one at a time until at least 15 characters are available for task names, rather than wrapping or clipping
|
|
33
|
+
|
|
34
|
+
### Changed
|
|
35
|
+
- `tasku list` output uses a consistent `│`-separated column layout with a header row
|
|
36
|
+
- `tasku config set` validates values via `ArgumentError` rather than a plain string comparison, supporting range constraints
|
|
37
|
+
- `tasku stats` includes a "By Project" section sorted by task count
|
|
38
|
+
- Sort defaults to `id` (ascending) when no `--sort` flag is given
|
|
39
|
+
- `id` added as an explicit `--sort` option
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## [0.3.9] - 2026-09-04
|
|
44
|
+
|
|
45
|
+
### Added
|
|
46
|
+
- **Mado TUI list mode** — `tasku list` launches an interactive cursor-driven list when `MADO=1` is set in the environment, designed for embedding in the Mado terminal multiplexer sidebar
|
|
47
|
+
- Arrow-key navigation, selected task ID written to `TASKU_SEL_FILE` for Mado button integration
|
|
48
|
+
- Inline-exec protocol (`\x02`) for receiving filter and display commands from Mado without shell round-trips
|
|
49
|
+
- `build_mado_rows` and `ansi_ljust` helpers exposed on `Output::Terminal` for Mado's renderer
|
|
50
|
+
|
|
51
|
+
---
|
|
52
|
+
|
|
53
|
+
## [0.3.1] - 2026-08-29
|
|
54
|
+
|
|
55
|
+
### Fixed
|
|
56
|
+
- Terminal width was capped at 80 columns regardless of actual PTY size, severely truncating the name column in wider terminals — now uses the real terminal width
|
|
57
|
+
|
|
58
|
+
### Changed
|
|
59
|
+
- `tasku list` sorts by `id` by default
|
|
60
|
+
- `exit_on_failure?` enabled on the CLI so bad subcommands exit with a non-zero status
|
|
61
|
+
|
|
62
|
+
---
|
|
63
|
+
|
|
64
|
+
## [0.3.0] - 2026-07-24
|
|
65
|
+
|
|
66
|
+
### Added
|
|
67
|
+
- **Project colours** — `tasku colour PROJECT #HEX` stores a hex colour per project; project names are tinted throughout `list`, `show`, and `stats`
|
|
68
|
+
- **Colour bar** — three-segment bar in `tasku list` showing project, priority, and status at a glance (toggle each segment with `tasku config set bar_project on/off` etc.)
|
|
69
|
+
- **User preferences** — `tasku config list` / `tasku config set KEY VALUE` / `tasku config get KEY`, backed by `~/.tasku/config.json`
|
|
70
|
+
- `list_spacing` preference (`compact` / `spacious`)
|
|
71
|
+
- **"By Project" section** in `tasku stats` sorted by task count
|
|
72
|
+
- Logo restored on `tasku help` and bare `tasku` invocation
|
|
73
|
+
|
|
74
|
+
---
|
|
75
|
+
|
|
76
|
+
## [0.2.0] - 2026-07-01
|
|
77
|
+
|
|
78
|
+
### Added
|
|
79
|
+
- `tasku projects` — list all projects with task counts and colour swatches
|
|
80
|
+
- `tasku categories` — list all categories
|
|
81
|
+
- `tasku done ID` — shorthand to mark a task done
|
|
82
|
+
- `--overdue`, `--today`, `--tomorrow` filter flags on `tasku list`
|
|
83
|
+
- `--sort` and `--order` flags on `tasku list`
|
|
84
|
+
- `--priority`, `--status`, `--tags` filter flags on `tasku list`
|
|
85
|
+
- `--force` / `-f` flag on `tasku delete` to skip confirmation
|
|
86
|
+
|
|
87
|
+
---
|
|
88
|
+
|
|
89
|
+
## [0.1.0] - 2026-06-29
|
|
90
|
+
|
|
91
|
+
Initial release.
|
|
92
|
+
|
|
93
|
+
- `tasku add`, `tasku list`, `tasku show`, `tasku edit`, `tasku delete`
|
|
94
|
+
- SQLite-backed storage at `~/.tasku/tasks.db`
|
|
95
|
+
- Task fields: name, description, project, category, priority, status, start date, due date, tags, estimated hours
|
|
96
|
+
- `tasku stats` — task breakdown by priority and status
|
|
97
|
+
- Interactive add/edit with `-i` flag (TTY::Prompt)
|
data/lib/tasku/cli.rb
CHANGED
|
@@ -261,6 +261,21 @@ module Tasku
|
|
|
261
261
|
end
|
|
262
262
|
end
|
|
263
263
|
|
|
264
|
+
# Local projects were pushed above, so the server's list already reflects
|
|
265
|
+
# them — adopt it wholesale so colours set on other machines come down.
|
|
266
|
+
projects_pulled = 0
|
|
267
|
+
(body["projects"] || []).each do |sp|
|
|
268
|
+
name = sp["name"].to_s.strip
|
|
269
|
+
colour = sp["colour"].to_s.strip
|
|
270
|
+
next if name.empty? || colour !~ /\A#[0-9A-Fa-f]{6}\z/
|
|
271
|
+
|
|
272
|
+
proj = Tasku::Project.find_or_create(name: name)
|
|
273
|
+
next if proj.colour == colour
|
|
274
|
+
|
|
275
|
+
proj.update(colour: colour)
|
|
276
|
+
projects_pulled += 1
|
|
277
|
+
end
|
|
278
|
+
|
|
264
279
|
Tasku::Config.last_synced_at = synced_at ? Time.parse(synced_at).utc : Time.now.utc
|
|
265
280
|
|
|
266
281
|
puts ""
|
|
@@ -268,6 +283,7 @@ module Tasku
|
|
|
268
283
|
puts " #{pastel.bold(local_tasks.count.to_s)} #{local_tasks.count == 1 ? "task" : "tasks"} pushed to cloud."
|
|
269
284
|
puts " #{pastel.bold(created.to_s)} #{created == 1 ? "task" : "tasks"} pulled from cloud." if created > 0
|
|
270
285
|
puts " #{pastel.bold(updated.to_s)} #{updated == 1 ? "task" : "tasks"} updated from cloud." if updated > 0
|
|
286
|
+
puts " #{pastel.bold(projects_pulled.to_s)} #{projects_pulled == 1 ? "project colour" : "project colours"} updated from cloud." if projects_pulled > 0
|
|
271
287
|
if conflicts > 0
|
|
272
288
|
puts " #{pastel.yellow("⚠")} #{conflicts} #{conflicts == 1 ? "conflict" : "conflicts"} — visit #{pastel.bold(url)} to resolve."
|
|
273
289
|
end
|
|
@@ -470,7 +486,15 @@ module Tasku
|
|
|
470
486
|
"col_due_min" => Config.get("col_due_min")
|
|
471
487
|
}
|
|
472
488
|
if ENV["MADO"] == "1"
|
|
473
|
-
|
|
489
|
+
list_cmd = "tasku list"
|
|
490
|
+
list_cmd += " --status #{Shellwords.shellescape(options[:status])}" if options[:status]
|
|
491
|
+
list_cmd += " --priority #{Shellwords.shellescape(options[:priority])}" if options[:priority]
|
|
492
|
+
list_cmd += " --project #{Shellwords.shellescape(options[:project])}" if options[:project]
|
|
493
|
+
list_cmd += " --category #{Shellwords.shellescape(options[:category])}" if options[:category]
|
|
494
|
+
list_cmd += " --today" if options[:today]
|
|
495
|
+
list_cmd += " --tomorrow" if options[:tomorrow]
|
|
496
|
+
list_cmd += " --overdue" if options[:overdue]
|
|
497
|
+
Tasku::TUI::MadoList.new(tasks, colour_map: Project.colour_map, bar: bar, cols_cfg: cols_cfg, project: options[:project], list_cmd: list_cmd).run
|
|
474
498
|
else
|
|
475
499
|
terminal.render_list(tasks, colour_map: Project.colour_map, spacing: Config.get("list_spacing"), bar: bar, cols_cfg: cols_cfg)
|
|
476
500
|
end
|
data/lib/tasku/tui/mado_list.rb
CHANGED
|
@@ -14,14 +14,14 @@ module Tasku
|
|
|
14
14
|
class MadoList
|
|
15
15
|
HINT = " ↑↓ navigate a add e/↵ edit d delete s stats q quit"
|
|
16
16
|
|
|
17
|
-
def initialize(tasks, colour_map: {}, bar: {}, cols_cfg: {}, project: nil)
|
|
17
|
+
def initialize(tasks, colour_map: {}, bar: {}, cols_cfg: {}, project: nil, list_cmd: nil)
|
|
18
18
|
@tasks = tasks
|
|
19
19
|
@cursor = 0
|
|
20
20
|
@pastel = Pastel.new
|
|
21
21
|
@sel_file = ENV["TASKU_SEL_FILE"]
|
|
22
22
|
@running = true
|
|
23
23
|
@inline_cmd = nil
|
|
24
|
-
@list_cmd = project ? "tasku list --project #{Shellwords.shellescape(project)}" : "tasku list"
|
|
24
|
+
@list_cmd = list_cmd || (project ? "tasku list --project #{Shellwords.shellescape(project)}" : "tasku list")
|
|
25
25
|
|
|
26
26
|
# Pre-render row content once so key-press redraws are cheap.
|
|
27
27
|
table = Output::Terminal.new.build_mado_rows(tasks, colour_map, bar, cols_cfg)
|
|
@@ -164,6 +164,18 @@ module Tasku
|
|
|
164
164
|
MadoLog.log("inline_exec cmd=#{cmd.inspect}")
|
|
165
165
|
if cmd == "SQL"
|
|
166
166
|
run_sql
|
|
167
|
+
elsif cmd.start_with?("tasku list")
|
|
168
|
+
# exec directly so the new MadoList initialises with the correct
|
|
169
|
+
# @list_cmd (project filter, status filter, etc.). Using
|
|
170
|
+
# run_command would nest a subprocess and then re-exec @list_cmd
|
|
171
|
+
# (no filter) when the subprocess exits — losing the filter.
|
|
172
|
+
# Must restore terminal + cooked mode before exec so the new
|
|
173
|
+
# process doesn't inherit raw-mode terminal attributes.
|
|
174
|
+
@running = false
|
|
175
|
+
restore_terminal
|
|
176
|
+
$stdin.cooked!
|
|
177
|
+
MadoLog.log("inline_exec tasku list → exec #{cmd.inspect}")
|
|
178
|
+
exec(cmd)
|
|
167
179
|
else
|
|
168
180
|
run_command(cmd)
|
|
169
181
|
end
|
data/lib/tasku/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: tasku
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.4.
|
|
4
|
+
version: 0.4.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Tom Dringer
|
|
8
|
+
autorequire:
|
|
8
9
|
bindir: exe
|
|
9
10
|
cert_chain: []
|
|
10
|
-
date:
|
|
11
|
+
date: 2026-09-29 00:00:00.000000000 Z
|
|
11
12
|
dependencies:
|
|
12
13
|
- !ruby/object:Gem::Dependency
|
|
13
14
|
name: thor
|
|
@@ -81,11 +82,13 @@ dependencies:
|
|
|
81
82
|
version: '1.6'
|
|
82
83
|
description: Tasku is a terminal-based task manager with colour-coded priorities,
|
|
83
84
|
status tracking, SQLite persistence, and a beautiful CLI interface.
|
|
85
|
+
email:
|
|
84
86
|
executables:
|
|
85
87
|
- tasku
|
|
86
88
|
extensions: []
|
|
87
89
|
extra_rdoc_files: []
|
|
88
90
|
files:
|
|
91
|
+
- CHANGELOG.md
|
|
89
92
|
- exe/tasku
|
|
90
93
|
- lib/tasku.rb
|
|
91
94
|
- lib/tasku/cli.rb
|
|
@@ -103,7 +106,8 @@ licenses:
|
|
|
103
106
|
metadata:
|
|
104
107
|
homepage_uri: https://github.com/tomdringer/tasku
|
|
105
108
|
source_code_uri: https://github.com/tomdringer/tasku
|
|
106
|
-
changelog_uri: https://github.com/tomdringer/tasku/
|
|
109
|
+
changelog_uri: https://github.com/tomdringer/tasku/blob/main/CHANGELOG.md
|
|
110
|
+
post_install_message:
|
|
107
111
|
rdoc_options: []
|
|
108
112
|
require_paths:
|
|
109
113
|
- lib
|
|
@@ -118,7 +122,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
118
122
|
- !ruby/object:Gem::Version
|
|
119
123
|
version: '0'
|
|
120
124
|
requirements: []
|
|
121
|
-
rubygems_version:
|
|
125
|
+
rubygems_version: 3.5.3
|
|
126
|
+
signing_key:
|
|
122
127
|
specification_version: 4
|
|
123
128
|
summary: タスクリスト — a beautiful terminal task manager
|
|
124
129
|
test_files: []
|