From f1890fc7b5fe1094445ce8b83c2d2f15258fceec Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Wed, 12 Aug 2026 11:42:14 +0200 Subject: 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. --- README.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'README.md') 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 "" --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 +mailctl rules dry-run [] # 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`. -- cgit v1.2.3