From df30a5e482341da79b341ca41c06e24f5acb8755 Mon Sep 17 00:00:00 2001 From: Adnan Maolood Date: Tue, 20 Apr 2021 16:16:12 -0400 Subject: [PATCH] Remove default 'gemini' task --- config.go | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/config.go b/config.go index 23ff532..1e63810 100644 --- a/config.go +++ b/config.go @@ -49,21 +49,6 @@ func (t Task) Format(p *Page) (string, []byte) { return path, []byte(p.Content) } -// DefaultConfig returns the default configuration. -func DefaultConfig() *Config { - c := new(Config) - c.Feeds = make(map[string]string) - c.Tasks = make(map[string]*Task) - c.Tasks["gemini"] = &Task{ - InputExt: ".gmi", - OutputExt: ".gmi", - TemplateExt: ".gmi", - StaticDir: "static", - OutputDir: "public", - } - return c -} - // LoadConfig loads the configuration from the provided path. func LoadConfig(path string) (*Config, error) { f, err := os.Open(path) @@ -72,7 +57,7 @@ func LoadConfig(path string) (*Config, error) { } defer f.Close() - c := DefaultConfig() + c := &Config{} if _, err := toml.DecodeReader(f, c); err != nil { return nil, err }