Add --version and typed delete for all kinds #5
Loading…
Reference in a new issue
No description provided.
Delete branch "version-and-delete"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Adds
things --versionand makesthings deletework for projects, headings, areas, and tags.Based on
mainafter #3 (e27328c). Commits:acf5dec—-V/--versionprintsthings <version> (<short commit>[-dirty]), e.g.things 0.1.0 (c436138), so you can tell which build is installed. The commit comes from a smallbuild.rs; builds outside a git checkout print just the version and don't fail.8c64bcb— typeddelete: A kind name used as a selector is read as the kind: delete a task titled "task" withthings delete task taskor its UUID. Typed forms only match items of that kind that aren't already in Trash. Shell completion suggests the right kind for each form.c436138— README, SKILL.md, and the protocol doc ("Trash and deletion").Wire behavior
Matched to what Things 3 for Mac writes, as observed in a real account's sync history:
tr: trueon that item only. Contents staytr: falseand are hidden by their container.restoresetstr: falseon the container.ardrops the area, and open projects in the area move to Trash. If the area still has open projects or to-dos, the CLI refuses unless--forceis given.tg, and child tags move up a level (pn).purgeof a project or heading, andpurge trash, now also delete the items inside a trashed project or heading in the same commit, as the app does. Previously they were left orphaned.Inferred, not observed:
Verification
cargo fmt --check,cargo clippy --all-targets -- -D warnings,make test: cleancargo test: 145 passed (up from 136), 1 ignored (live)--yesrefusal, the non-empty area refusal, and restoring a trashed project.c43613866bto3f805cba3d