Documentation
¶
Overview ¶
Package scan reads blog post directories, parses frontmatter, and returns sorted post metadata.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExtractSummary ¶
ExtractSummary finds the first non-empty paragraph after a heading line.
Parameters:
- body: Post body text after frontmatter
Returns:
- string: First paragraph text, or empty if none found
func ParsePost ¶
func ParsePost(path, filename string) (core.BlogPost, core.PostStatus)
ParsePost reads a single blog post file and extracts metadata.
Parameters:
- path: Absolute path to the blog post file
- filename: Base filename of the blog post
Returns:
- BlogPost: Parsed blog post metadata
- PostStatus: Whether the post was included, skipped, or warned
func ScanBlogPosts ¶
ScanBlogPosts reads blog posts from blogDir, parses metadata, and returns them sorted by date descending.
Parameters:
- blogDir: Path to the blog posts directory
Returns:
- []BlogPost: Parsed blog posts sorted by date descending
- FeedReport: Report of skipped and warned entries
- error: Non-nil if directory access fails
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.