aboutsummaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-08-12 11:42:14 +0200
committerDanilo M. <danix@danix.xyz>2026-08-12 11:42:14 +0200
commitf1890fc7b5fe1094445ce8b83c2d2f15258fceec (patch)
tree6caf922da23b5a17ee758402b5687fe0a305750c /README.md
parentf2feb50773b945aafed896b7d75e66035315aa5b (diff)
downloadmailctl-f1890fc7b5fe1094445ce8b83c2d2f15258fceec.tar.gz
mailctl-f1890fc7b5fe1094445ce8b83c2d2f15258fceec.zip
feat(rules): read-only rules list and show
Editing stays out of this tool: a rule edit affects every future sync and its gate is not designed yet. qtmaildir has the editor. The install step now copies mailrules.py beside mailctl.py. The import resolves from the script's own directory, so copying only mailctl.py would break every command, not just the new ones.
Diffstat (limited to 'README.md')
-rw-r--r--README.md9
1 files changed, 8 insertions, 1 deletions
diff --git a/README.md b/README.md
index c33a5f2..8067f83 100644
--- a/README.md
+++ b/README.md
@@ -23,10 +23,14 @@ An agent given raw `notmuch`/`mbsync` access can do anything, including mangle t
No installer, just copy files into place:
```bash
-cp mailctl.py ~/bin/ # executable
+cp mailctl.py mailrules.py ~/bin/ # executable, plus the module it imports
cp -r mail-organize ~/.claude/skills/ # Claude Code skill, in its own dir
```
+`mailrules.py` is copied beside `mailctl.py`, not instead of it: `mailctl rules`
+imports it, and Python resolves that import from the directory the script lives
+in. Copying only `mailctl.py` leaves every command failing at startup.
+
The skill invokes the tool at `~/bin/mailctl.py`; keep that path.
## Configuration
@@ -69,6 +73,9 @@ mailctl tag "<query>" --account NAME [--add TAG]... [--remove TAG]...
[--apply] [--confirm-destructive]
mailctl draft --account NAME --to ADDR --subject TEXT
[--cc ADDR] [--body TEXT | --body-file PATH]
+mailctl rules list [--enabled-only] # shared tagging rules, read-only
+mailctl rules show <id>
+mailctl rules dry-run [<id>] # what each rule matches now
```
Reads default to global scope (all accounts) when `--account` is omitted. `tag` refuses to run without either `--account NAME` or `--all-accounts`.