emailEmail is an Agent Skill for apps & automation published in the Mic92/dotfiles repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.
Read flagged emails from Maildir (mblaze) and draft replies via n8n-hooks.
QUICK START
How to use this skill
Bring this guide into your coding agent with a prompt tailored to the tool you use.
- Open your project in Codex.
- Copy and paste the prompt below.
- Review files and risks before approving any action.
Prompt to paste
Inspect the Agent Skill at https://github.com/Mic92/dotfiles/blob/HEAD/machines/eve/modules/opencrow/skills/email/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/email, but wait for my approval before writing files or running scripts.
Copying this prompt does not install or run the skill. Review third-party files before use.
Email Access
Flagged emails live in /var/mail/flagged/ (read-only Maildir). Use mblaze:
# List messages
mscan /var/mail/flagged/{cur,new}/
# Show a message (renders MIME)
mshow /var/mail/flagged/cur/<filename>
# Extract headers
mhdr -h From -h Subject -h Date /var/mail/flagged/cur/<filename>
# List/extract MIME parts
mshow -t <file> # list parts
mshow -x <file> # extract attachments
# Search by header
mpick -t 'from =~ "someone"' /var/mail/flagged/{cur,new}/
# Thread and list
mthread /var/mail/flagged/{cur,new}/ | mscan
Drafting Emails
Use n8n-hooks to store drafts in IMAP for review before sending:
# Basic draft (plain text auto-wrapped in <pre> for HTML)
n8n-hooks store-draft --to "[email protected]" --subject "Hi" --body-plain "Hello"
# All options
n8n-hooks store-draft \
--to "[email protected]" --cc "[email protected]" --bcc "[email protected]" \
--from "[email protected]" \
--subject "Re: Thread" \
--body-plain "text" --body-html "<p>text</p>" \
--in-reply-to "<msgid@host>" --references "<msgid@host>" \
--attach file.pdf
# Body from stdin
echo "body" | n8n-hooks store-draft --to "[email protected]" --subject "Hi" --body-plain -