Joel's notes 6037 notes About these notes

My personal website export process

Planted December 2025

Up: § My personal website

The export process copies content from my Obsidian vault to an intermediate export directory, applying privacy rules and transforming content for web publishing.

Folder Structure

Source: /Users/joel/Obsidian Vaults/Notes
Destination: /Users/joel/Code/digital-garden-python-export

Content Types and Mappings

Content Type Vault Source Path(s) Export Destination
notes topic/evergreen notes/
spaces spaces/ spaces/
clippings clippings/articles, clippings/books, clippings/quotes, clippings/poems, clippings/ai chats clippings/
articles website/articles website/articles
newsletters website/newsletters website/newsletters
pages website/pages website/pages
posts website/posts website/posts

Algorithm

  1. Process each content type - iterate through configured vault paths
  2. Check privacy rules for each markdown file:
    • Default: public, except for clippings/ai chats and spaces directories
    • garden_private: in frontmatter → exclude from export
    • garden_public: in frontmatter → include in export (overrides directory default)
  3. Process assets - find image references in content:
    • Obsidian-style: <img class="" src="/cdn-cgi/imagedelivery/8UsJNwl0JNE30EmncpA2bw/assets/image.jpg/public" alt="">
    • Standard markdown: <img class="" src="/cdn-cgi/imagedelivery/8UsJNwl0JNE30EmncpA2bw/assets/image.jpg/public" alt="alt">
    • Copy referenced assets from vault's assets/ folder to export's assets/ folder
  4. Transform image syntax - convert to Eleventy shortcode format:
    • <img class="" src="/cdn-cgi/imagedelivery/8UsJNwl0JNE30EmncpA2bw/assets/image.jpg/public" alt=""><img class="" src="/cdn-cgi/imagedelivery/8UsJNwl0JNE30EmncpA2bw/assets/image.jpg/public" alt="">
  5. Flatten structure - files are exported using just their filename (no subdirectory hierarchy preserved)
  6. Sync changes - track new, modified, and deleted files; only write changed content
  7. Output summary - report counts of new, modified, deleted files and copied assets

Privacy Logic

The get_directory_public_default() function determines default visibility:

  • clippings/ai chats → private by default
  • spaces → private by default
  • All other directories → public by default

Frontmatter properties override the default.