Versions in this module Expand all Collapse all v0 v0.0.1 Aug 19, 2024 Changes in this version + const DefaultFrontMatterDate + const DefaultFrontMatterDraft + const DefaultFrontMatterSlug + const DefaultFrontMatterTitle + const DefaultRawShortcodeEnd + const DefaultRawShortcodeStart + const DefaultTemplate + const GhostPostStatusDraft + const QUERY_POSTS_FIELDS + type Config struct + ForbidEmptyPosts bool + FrontMatter FrontMatterConfig + GhostURL string + LinkReplacements map[string]string + MySQLConnectionString string + OutputPath string + PostStatuses map[string]bool + PostTypes map[string]bool + PostVisibilities map[string]bool + PublishDrafts bool + RawShortcodeEnd string + RawShortcodeStart string + ReplaceLinks bool + SetUnpublishedToNow bool + Template string + func LoadConfig(f string) (Config, error) + func (c *Config) ApplyDefaults() + func (c *Config) GetGhostPost(rows *sql.Rows) (GhostPost, error) + func (c *Config) IsValid(p GhostPost) bool + func (c *Config) Process() + func (c *Config) ProcessGhostPost(post GhostPost) (GhostPost, error) + func (c *Config) ProcessHTML(s string) (string, error) + func (c *Config) RenderAll(p []GhostPost) error + func (c *Config) RenderOne(p GhostPost) (int, string, error) + func (c *Config) RenderString(post GhostPost) (string, error) + func (conf *Config) ParseTemplate() error + type FrontMatterConfig struct + Date string + Draft string + Slug string + Title string + func (f *FrontMatterConfig) ApplyDefaults() + type GhostPost struct + CanonicalUrl sql.NullString + CodeinjectionFoot sql.NullString + CodeinjectionHead sql.NullString + CommentID sql.NullString + CreatedAt time.Time + CreatedBy string + CustomExcerpt sql.NullString + CustomTemplate sql.NullString + EmailRecipientFilter string + FeatureImage sql.NullString + Featured bool + HTML sql.NullString + ID string + IsDraft bool + Lexical sql.NullString + Locale sql.NullString + Mobiledoc sql.NullString + NewsletterId sql.NullString + Plaintext sql.NullString + PublishedAt time.Time + PublishedBy sql.NullString + ShowTitleAndFeatureImage bool + Slug string + SqlCreatedAt string + SqlPublishedAt sql.NullString + SqlUpdatedAt sql.NullString + Status string + Title string + Type string + UUID string + UpdatedAt time.Time + UpdatedBy sql.NullString + Visibility string + type PostTemplate struct + FrontMatterConfig FrontMatterConfig + Post GhostPost + PostDate string + PostHTML string + RawShortcodeEnd string + RawShortcodeStart string