converting-notion-to-docusaurus-blog
Skill219 starsChanged 24 days agoApache-2.0View on GitHub
Use when converting a Notion markdown export to a Docusaurus blog post for the dbt docs site, or when given a path to a Notion export folder/file.
We split this skill into the rules it gives an agent
6 rules. About 0 are common, 4 are distinctive, and 2 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.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 29
Remove the metadata block (Status, Owner, Created time) from output
- Very specific: line 33
Search website/blog/authors.yml for a matching name from the Owner field.
- Distinctive: line 57
Date: Default to today + 2 days (YYYY-MM-DD)
- Distinctive: line 63
Slug guidelines: Keep 2-4 words, include primary keywords, drop "introducing", "a", "the", "how to".
- Very specific: line 67
Tag selection: Check website/blog/categories.yml for available tags and their descriptions.
- Distinctive: line 90
Run a spellcheck on the content and fix any typos or spelling errors.
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 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
Converting Notion Exports to Docusaurus Blog Posts
Overview
Automates conversion of Notion markdown exports into properly formatted Docusaurus blog posts for docs.getdbt.com. Handles frontmatter generation, image processing, content cleanup, and file organization.
When to Use
- User provides a path to a Notion markdown export
- User mentions converting Notion content to a blog post
- User has exported content from Notion for the dbt developer blog
Workflow
1. Read Notion Export
Parse the markdown file and locate the accompanying image folder (same name as the .md file, without the hash suffix).
2. Extract Metadata
From the Notion export, extract:
- Title: The H1 heading
- Owner: Maps to author lookup
- Remove the metadata block (Status, Owner, Created time) from output
3. Look Up Author
Search website/blog/authors.yml for a matching name from the Owner field.
If not found, prompt user:
Author "[Name]" not found in authors.yml.
How would you like to proceed?
1. Enter details now (name, title, photo URL, LinkedIn)
2. Scaffold empty entry to fill in manually laterOption 2 creates:
firstname_lastname:
name: Full Name
title: "" # TODO
image_url: /img/blog/authors/firstname-lastname.png # TODO
socials:
linkedin: "" # TODO
page: true4. Prompt for Confirmations
- Date: Default to today + 2 days (YYYY-MM-DD)
- Slug: Suggest SEO-optimized version (short, keywords only, drop filler words)
- Description: Find a compelling sentence from within the article that captures the key value or insight - not just the opening line
- Tag: Select the most appropriate tag based on content (see Tag Selection below)
- End of content: Confirm where the publishable content ends (remove trailing internal notes)
Slug guidelines: Keep 2-4 words, include primary keywords, drop "introducing", "a", "the", "how to".
- "Introducing dbt agent skills" →
dbt-agent-skills - "Getting Started with git Branching Strategies" →
git-branching-strategies-dbt
Tag selection: Check website/blog/categories.yml for available tags and their descriptions. Select the most appropriate tag based on the post content. Fall back to analytics craft only if no other tag fits.
5. Process Images
For each image in the Notion export folder:
- Analyze the image to generate a semantic filename (e.g.,
skills-mcp-diagram.pngnot74cb2aed-fe53-481b-89d0-eefd0054e0c2.png) - Generate alt text for accessibility
- Copy to
website/static/img/blog/YYYY-MM-DD-slug/
6. Copy Original File
Copy the Notion markdown file to website/blog/YYYY-MM-DD-slug.md first. This establishes the baseline for git diffs.
7. Commit the Raw Baseline
Stage the new blog file and any copied images and create a commit (e.g. chore: import raw Notion export for <slug>) before making any edits. This anchors the baseline in git history so that all subsequent transformations appear as a single, reviewable diff against the import commit.
8. Apply Transformations as Edits
Apply transformation rules (see below) as individual edits to the copied file. This makes changes visible in git diff, allowing review of exactly what was modified.
9. Spellcheck Pass
Run a spellcheck on the content and fix any typos or spelling errors. Be careful to preserve technical terms, product names (dbt, MetricFlow, BigQuery), and intentional stylistic choices.
10. Report Results
Summarize: files created, images processed, spelling corrections made, any TODO items (e.g., incomplete author entry).
Transformation Rules
Frontmatter
Generate YAML frontmatter:
---
title: "Title from H1"
description: "A compelling sentence from the article that captures the key value or insight"
slug: seo-optimized-slug
authors: [author_slug]
tags: [appropriate-tag]
hide_table_of_contents: false
date: YYYY-MM-DD
is_featured: true
---Images
| Notion | Docusaurus |
 | <Lightbox src="/img/blog/YYYY-MM-DD-slug/semantic-name.png" width="85%" alt="generated alt text" /> |
| Image with caption on next line | Merge caption into title attribute |
Content Cleanup
| Pattern | Action |
| H1 title | Remove (comes from frontmatter) |
| Status/Owner/Created time block | Remove |
| Trailing sections after conclusion | Remove (internal notes) |
Code blocks with language markdown | Change to bash if shell commands |
Notion callouts (> **Note**) | Convert to :::note admonitions |
URL-encoded paths (%20) | Decode |
asterisks for emphasis (*emphasised* content) | Replace with underscores (_emphasised_ content) |
Internal Notion links (notion.so, notion.site) | Flag for review - replace with public resource links |
Absolute docs site links (https://docs.getdbt.com/...) | Convert to relative paths (/docs/..., /reference/...) |
Truncate Marker
Insert <!-- truncate --> after the introduction (1-3 paragraphs, ~150-300 words) and before the first ## heading.
Quick Reference
Notion Export:
my-post abc123.md
my-post abc123/
image.png
image 1.png
Step 1 - Copy original + images, then commit:
website/blog/YYYY-MM-DD-slug.md (raw Notion content)
website/static/img/blog/YYYY-MM-DD-slug/
semantic-name.png
another-semantic-name.png
→ git commit (baseline import)
Step 2 - Apply edits (diffable against baseline commit):
website/blog/YYYY-MM-DD-slug.md (transformed)In this repository12 other files it gives its agents.
- AGENTS.mdAGENTS.md
- add-availability-badgeSkill
- cavecrewSkill
- caveman-commitSkill
- caveman-compressSkill
- caveman-helpSkill
- caveman-reviewSkill
- cavemanSkill
- caveman-statsSkill
- create-docs-skeletonSkill
- docs-issue-triageSkill
- product-term-renameSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
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.

