From apple-notes-pack
Handles Apple Notes HTML format, checklists, Markdown conversion, and attachments using TypeScript converters and osascript Bash scripts.
How this skill is triggered — by the user, by Claude, or both
Slash command
/apple-notes-pack:apple-notes-data-handlingThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Apple Notes stores content as HTML internally. Understanding the data format is essential for import/export operations.
Apple Notes stores content as HTML internally. Understanding the data format is essential for import/export operations.
<!-- Apple Notes uses a subset of HTML -->
<div><h1>Title</h1></div>
<div><br></div>
<div>Paragraph text here.</div>
<div><br></div>
<div><b>Bold text</b> and <i>italic text</i></div>
<div><br></div>
<div><ul><li>List item 1</li><li>List item 2</li></ul></div>
<!-- Checklists use a custom attribute -->
<div><ul class="com-apple-note-checklist">
<li class="done">Completed item</li>
<li>Incomplete item</li>
</ul></div>
// src/data/html-to-markdown.ts
function notesHtmlToMarkdown(html: string): string {
return html
.replace(/<h1>(.*?)<\/h1>/g, "# $1")
.replace(/<h2>(.*?)<\/h2>/g, "## $1")
.replace(/<h3>(.*?)<\/h3>/g, "### $1")
.replace(/<b>(.*?)<\/b>/g, "**$1**")
.replace(/<strong>(.*?)<\/strong>/g, "**$1**")
.replace(/<i>(.*?)<\/i>/g, "*$1*")
.replace(/<em>(.*?)<\/em>/g, "*$1*")
.replace(/<li class="done">(.*?)<\/li>/g, "- [x] $1")
.replace(/<li>(.*?)<\/li>/g, "- $1")
.replace(/<br\s*\/?>/g, "\n")
.replace(/<div>/g, "").replace(/<\/div>/g, "\n")
.replace(/<[^>]*>/g, "")
.replace(/\n{3,}/g, "\n\n")
.trim();
}
function markdownToNotesHtml(md: string): string {
return md
.replace(/^# (.+)$/gm, "<h1>$1</h1>")
.replace(/^## (.+)$/gm, "<h2>$1</h2>")
.replace(/\*\*(.+?)\*\*/g, "<b>$1</b>")
.replace(/\*(.+?)\*/g, "<i>$1</i>")
.replace(/^- \[x\] (.+)$/gm, "<li class=\"done\">$1</li>")
.replace(/^- (.+)$/gm, "<li>$1</li>")
.replace(/\n/g, "<br>");
}
# List notes with attachments
osascript -l JavaScript -e "
const Notes = Application(\"Notes\");
Notes.defaultAccount.notes()
.filter(n => n.attachments().length > 0)
.map(n => \`\${n.name()}: \${n.attachments().length} attachments\`)
.join(\"\\n\");
"
npx claudepluginhub jeremylongshore/claude-code-plugins-plus-skills --plugin apple-notes-packExports Apple Notes to Markdown, JSON, HTML files, and SQLite databases using macOS osascript and bash. Converts internal HTML to Markdown for backups, app exports, or searchable archives.
CRUD operations for Apple Notes: list, read, create, and delete notes with HTML formatting. Persists thoughts and data across Claude Code sessions.
Automates Apple Notes via JXA. Use when asked to "create notes programmatically", "automate Notes app", "JXA notes scripting", or "organize notes with automation". Covers accounts/folders/notes, HTML bodies, queries, moves, and Objective-C/UI fallbacks for Notes.app automation on macOS.