Publish Blog Skill
Publishes blog posts to both GitHub Pages and Dev.to with proper formatting.
Usage
bash
# With explicit topic /publish-blog "Iron Condor Backtesting Results" # Auto-generate from recent context /publish-blog
What It Does
- •
Generates a blog post with proper structure:
- •What prompt/task was given
- •What was accomplished
- •Tech stack used
- •Why the approach worked
- •
Saves to GitHub Pages (
docs/_posts/) with Jekyll frontmatter - •
Publishes to Dev.to if
DEVTO_API_KEYis available - •
Commits and pushes to GitHub
Blog Post Structure
markdown
--- layout: post title: "Your Title Here" date: YYYY-MM-DD HH:MM:SS categories: [engineering, trading, ai] tags: [relevant, tags, here] --- # Title ## The Challenge What problem were we solving? ## The Approach How did we solve it? ## Tech Stack What tools and technologies were used? ## Results What was accomplished? ## Lessons Learned What did we learn? --- _Auto-generated by AI Trading System_
Jekyll Frontmatter Fields
| Field | Description | Example |
|---|---|---|
layout | Always "post" | post |
title | Post title (quoted) | "Day 90: System Complete" |
date | ISO timestamp | 2026-01-28 15:30:00 |
categories | Post categories | [engineering, lessons-learned] |
tags | Searchable tags | [iron-condors, phil-town, python] |
Dev.to Integration
The skill checks for DEVTO_API_KEY environment variable:
- •
If set: Posts to Dev.to with:
- •Title from Jekyll frontmatter
- •Tags:
trading,ai,machinelearning,python - •Series: "AI Trading Daily Reports"
- •Canonical URL pointing to GitHub Pages
- •
If not set: Skips Dev.to, only publishes to GitHub Pages
Execution Steps
When invoked, the skill:
- •
Gather Context
- •Check recent git commits
- •Check current branch changes
- •Read recent conversation context
- •
Generate Content
- •Create title from topic or context
- •Structure post with standard sections
- •Include code snippets where relevant
- •
Save to GitHub Pages
bash# Filename format: YYYY-MM-DD-slug-title.md docs/_posts/2026-01-28-iron-condor-backtesting.md
- •
Publish to Dev.to (if API key available)
pythonrequests.post( "https://dev.to/api/articles", headers={"api-key": DEVTO_API_KEY}, json={"article": {...}} ) - •
Commit and Push
bashgit add docs/_posts/ git commit -m "feat(blog): Publish: <title>" git push
Environment Variables
| Variable | Required | Purpose |
|---|---|---|
DEVTO_API_KEY | No | Dev.to API key for cross-posting |
GITHUB_TOKEN | Yes* | For pushing commits (*uses existing auth) |
Example Output
code
============================================ BLOG POST PUBLISHED ============================================ Title: Iron Condor Backtesting Results GitHub Pages: docs/_posts/2026-01-28-iron-condor-backtesting.md Dev.to: https://dev.to/igorganapolsky/iron-condor-backtesting-xxx Commit: abc1234 ============================================
Related Files
- •
scripts/generate_daily_blog_post.py- Daily automated posts - •
.github/workflows/daily-blog-post.yml- CI/CD for blog - •
docs/_posts/- All blog post files
Category Guidelines
| Category | When to Use |
|---|---|
engineering | Code changes, architecture |
trading | Strategy, trade analysis |
lessons-learned | Post-mortems, insights |
ai | LLM/RAG improvements |
strategy | Trading strategy updates |
Tag Suggestions
Common tags for this project:
- •
iron-condors,options,spy - •
claude-ai,vertex-ai,rag - •
phil-town,risk-management - •
python,github-actions - •
alpaca,paper-trading
Workflow
code
User: /publish-blog "New circuit breaker implementation"
|
v
[1. Gather context from git/conversation]
|
v
[2. Generate structured blog post]
|
v
[3. Save to docs/_posts/YYYY-MM-DD-slug.md]
|
v
[4. POST to Dev.to API (if key exists)]
|
v
[5. git add + commit + push]
|
v
Output: URLs to both platforms