sendmail
Skill0 starsChanged 18 days agoMITView on GitHub
Prepare a draft email in Microsoft Outlook on macOS via osascript. Invoked as /sendmail with an email address followed by either literal body text or an assignment describing what the mail should say; the subject is derived from the body. Opens the draft in Outlook for review — it never sends.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- ferocknew/claude_code_public_skillstheir own version, first seen Jul 26, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- ferocknew/claude_code_public_skills★ 9same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository14 other files it gives its agents.
- ambitiousSkill
- attributionSkill
- ggSkill
- grill-meSkill
- guide-meSkill
- htmlSkill
- jfdiSkill
- local-urlSkill
- flushcacheSkill
- scan-secretsSkill
- scpushSkill
- social-previewSkill
- stern-code-reviewSkill
- strunkSkill
The file
We split this skill into the rules it gives an agent
9 rules. About 0 are common, 4 are distinctive, and 5 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 39
Write the body yourself, drawing on the current conversation context.
- Distinctive: line 41
When it is ambiguous, treat it as a literal body — under-writing is recoverable in the draft, over-writing is not.
- Distinctive: line 47
Only facts established in the conversation or given in the arguments.
- Very specific: line 58
If the literal body is one short line, the subject may restate it (Today it is Thursday).
- Very specific: line 60
If the user's arguments explicitly name a subject (subject: X, or --subject X), use that verbatim instead.
- Very specific: line 80
Write the AppleScript to a file in the session scratchpad directory (fall back to "$TMPDIR") and run it with osascript.
- Very specific: line 104
Keep open msg and activate.
- Very specific: line 115
If osascript errors, show the error verbatim and stop.
- Distinctive: line 124
Do not attach files, add cc/bcc recipients, or set flags unless the user asked in the arguments.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Sendmail — prepare an Outlook draft
Compose an outgoing message in Microsoft Outlook (macOS) and open it for the user to review. Never send.
Invocation contract
Arguments provided: $ARGUMENTS
The arguments must contain at least one email address. Parse as follows:
- Recipients — every token matching an email address (
local@domain.tld), in order of appearance. The first one or more addresses areTo:recipients. - Remainder — everything left after removing the addresses. This is the body spec.
- No address found → stop. Say only:
Need an email address.Do not run osascript, do not guess a recipient. - No remainder → ask the user once what the mail should say. Do not invent a body.
Body spec: literal or assignment
Decide which of the two the remainder is:
- Literal body — a finished message the user wants sent verbatim
(e.g.
'Today it is Thursday'). Use it as-is; do not embellish, do not add paragraphs the user did not write. - Assignment — an instruction about what to write
(e.g.
'ask Kim for the Q3 numbers','summarize what we just fixed'). Write the body yourself, drawing on the current conversation context.
When it is ambiguous, treat it as a literal body — under-writing is recoverable in the draft, over-writing is not.
Assignment-written bodies:
- Short. A greeting, one to three short paragraphs, a sign-off.
- Only facts established in the conversation or given in the arguments. No invented numbers, dates, names, links, or commitments.
- Sign off with the user's first name from
git config user.nameif that returns a value; otherwise no sign-off.
Subject
Derive it — the user does not pass one. Rules:
- Short noun phrase, ~3-8 words, specific to this mail's content. No trailing
period, no
Re:, no[skill]-style prefixes. - If the literal body is one short line, the subject may restate it
(
Today it is Thursday). - If the user's arguments explicitly name a subject (
subject: X, or--subject X), use that verbatim instead.
Escaping — do this before building the script
content is HTML, and both subject and content are AppleScript string
literals. In that order, per field:
\→\\"→\"- In
contentonly: each newline →<br>, and a blank line →<br><br>. A literal newline inside an AppleScript string is a syntax error. - Non-ASCII characters → HTML entities in
content(é→é,—→—). Keepsubjectplain ASCII; transliterate if needed. - In
contentonly: escape HTML-significant characters the user typed as text —&→&,<→<,>→>— unless the user clearly intended HTML markup.
Script
Write the AppleScript to a file in the session scratchpad directory (fall back
to "$TMPDIR") and run it with osascript. Do not pipe a heredoc through the
shell — the shell adds a second layer of quoting to get wrong.
cat > "$SCRATCH/sendmail.scpt" <<'EOF'
tell application "Microsoft Outlook"
set msg to make new outgoing message with properties {subject:"SUBJECT", content:"BODY_HTML"}
tell msg
make new recipient at end of to recipients ¬
with properties {email address:{name:"ADDRESS", address:"ADDRESS"}}
end tell
open msg
activate
end tell
EOF
osascript "$SCRATCH/sendmail.scpt"- Replace
SUBJECT,BODY_HTML,ADDRESSwith the escaped values. Setnameto the address itself unless the user supplied a display name ("Kim" <kim@example.com>→name:"Kim"). - Multiple recipients: repeat the whole
make new recipient ... endblock, one per address, inside the sametell msg. - Keep
open msgandactivate. Never emitsend msg— not even when the arguments say "send it". Preparing a reviewable draft is the whole contract of this skill; if the user wants it sent, they click Send. ¬is the AppleScript line-continuation character. Keep it, or put thewith propertiesclause on one line.
After running
Report in at most two lines: the recipients, and the subject used. Do not reprint the body — it is on screen in Outlook.
If osascript errors, show the error verbatim and stop. Common causes: Outlook
not running (it launches on activate, but a cold start can time out — retry
once), or the terminal lacking Automation permission for Outlook in System
Settings → Privacy & Security → Automation.
Guardrails
- One draft per invocation. No loops over a recipient list, no bcc-style fan-out.
- Do not attach files, add cc/bcc recipients, or set flags unless the user asked in the arguments.
- Content leaves the machine the moment the user clicks Send: keep secrets, credentials, and tokens out of the body, and say so instead of including them if the conversation context contains any.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

