feat: implement draft stream filtering for feeds and search#297
Merged
rochacbruno merged 3 commits intomainfrom Jul 20, 2025
Merged
feat: implement draft stream filtering for feeds and search#297rochacbruno merged 3 commits intomainfrom
rochacbruno merged 3 commits intomainfrom
Conversation
- Filter out content with stream "draft" from RSS feed generation - Filter out content with stream "draft" from JSON feed generation - Filter out content with stream "draft" from search index generation - Content with stream "draft" will no longer appear in feeds or be searchable - Draft content pages are still generated but excluded from discovery Closes #296 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
…ntation - Prevent generation of draft.rss and draft.json files entirely - Draft stream feeds are no longer created even when empty - Add comprehensive documentation on using draft posts - Documentation explains draft behavior, use cases, and publishing workflow 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Exclude draft stream from RSS and JSON feed link generation - Prevents broken links to non-existent draft.rss and draft.json files - Other streams continue to show feed links normally - Draft stream page itself still shows links but files don't exist (404) 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
stream: draftfrom RSS feeds, JSON feeds, and search indexdraft.rssanddraft.jsonfiles entirelyChanges Made
Core Filtering (
src/feed.rs)generate_rss()to filter out draft content usingis_none_or()generate_json()to filter out draft content usingis_none_or()Search Index Filtering (
src/site.rs)generate_search_index()to exclude draft content from both posts and pageshandle_stream_pages()to skip feed generation for "draft" streamTemplate Updates (
example/templates/base.html)Documentation (
example/content/2024-07-20-draft-posts-guide.md)Test Plan
stream: draftindex.rss,index.json,search_index.jsondraft.rssanddraft.jsonfiles are not generatedBehavior
✅ What Works
draft.html) lists all draft posts❌ What's Excluded
draft.rssordraft.jsonfiles createdCloses #296
🤖 Generated with Claude Code