Gitodo CLI
基于 Git 的本地 TODO 管理工具,所有数据存放在 ~/.gitodo 并由 Git 记录历史。
安装
- 使用 uv(推荐):
uv pip install . - 或使用 pip:
pip install .
默认数据目录
~/.gitodo/(启动或命令首次运行时自动创建并git init)- 主要文件:
TODO.md、archive/、resources/、.storage.lock、gitodo.toml
配置(可选)
~/.gitodo/gitodo.toml(如不存在会自动生成)示例:
debug = false
log_level = "INFO"
repo_path = "~/.gitodo"
auto_commit = true
commit_message_template = "gitodo {action}: {summary}"
plain_output = false
show_pins_default = true
show_preview_default = false
常用命令
(所有命令默认作用于 ~/.gitodo,如需自定义目录可设置环境变量 GITODO_REPO_PATH 或 --config 指定)
- 初始化:
gitodo init - 查看状态:
gitodo status - 切换/创建分支:
gitodo checkout <branch>;查看分支:gitodo branch - 固定说明(pin):
gitodo pin "分支长期说明"(写入 TODO.md 顶部 PINS 块,支持--tags/#tag--context/@ctx--priority/!P1,遵循自动提交策略) - 追加任务:
gitodo add "写方案" [--done] [--tags #tag ...] [--context @home] [--priority !P1] [--resource resources/x.png] [--commit|--no-commit]- 快捷追加(等价 add):
gitodo "写方案"
- 快捷追加(等价 add):
- 完成任务:
gitodo done <id或序号> [--status todo|done|all] [--commit|--no-commit] - 列出任务:
gitodo list [--limit N] [--status todo|done|all] [--with-id] [--no-id] [--with-pin|--no-pin] [--preview|--no-preview]- 默认
limit=7,展示最新 N 条任务(倒序);PINS 块默认展示,可用--no-pin或配置show_pins_default=false关闭;原文预览默认关闭,可用--preview或配置show_preview_default=true开启
- 默认
- 查看差异:
gitodo diff [path] [--cached] - 归档完成项:
gitodo archive [--date YYYY-MM-DD | --since ... --until ...] [--dry-run] [--commit|--no-commit] [-m msg] - 手动提交:
gitodo commit [-m msg] - 输出模式:默认使用简化 Rich 样式,纯文本回退由配置
plain_output控制(不再提供命令行开关);主要输出遵循轻量 Table/Markdown,无大面积 Panel。
任务行格式(TODO.md)
- 每日块:
## YYYY-MM-DD - 任务行:
- [ ] HH:MM 描述 #tag @ctx !P1 (id:xxxx) +res:resources/file[ ]/[x]/[-]/[?]表示 待办/完成/取消/阻塞- 完成时自动追加
@done(YYYY-MM-DD HH:MM)
归档规则
archive将已完成/取消的任务移至archive/YYYY/MM/DD/TODO.md,并复制引用的resources/。--dry-run仅预览,不落盘;自动去重同一行。
自动提交
- 默认开启,提交信息模板
gitodo {action}: {summary};可通过--no-commit或配置auto_commit=false关闭。
Metadata
Release files for gitodo 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| gitodo-0.1.3.tar.gz | 24.0 kB | Without provenance | Details for gitodo-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| gitodo-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for gitodo-0.1.3-py3-none-any.whl |
Total release size: 48.5 kB
Release files / gitodo-0.1.3.tar.gz
| Download URL | gitodo-0.1.3.tar.gz |
|---|---|
| Size | 24.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
21205cd5d147f421895a57ee0cfe7a5915ada3964bfe1060e59004a806004593
|
|
BLAKE2b-256 checksum How to use checksums |
3862218ff1c0efa3396301047d628309b0b61b2f9dfe4e4ce7485c7e4fae25cd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.11
|
Release files / gitodo-0.1.3-py3-none-any.whl
| Download URL | gitodo-0.1.3-py3-none-any.whl |
|---|---|
| Size | 24.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7c24e8428a0c7cc30454a32e9384dec314beb60e74c1f3f9875874505401c08a
|
|
BLAKE2b-256 checksum How to use checksums |
5eca428e8ddc5e4ee3015076beb8e168e164a2c6ccf508aeab8072ad3a68ad30
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.11
|
Security for gitodo 0.1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.