Fix index page for new sites

This commit is contained in:
adnano 2021-05-17 12:55:15 -04:00
parent 5bfc0f7d77
commit 4b23a11d0b

View file

@ -137,8 +137,8 @@ func newSite(name string) {
config, _ := builtin.ReadFile("config.toml") config, _ := builtin.ReadFile("config.toml")
os.WriteFile(path.Join(name, "config.toml"), config, 0644) os.WriteFile(path.Join(name, "config.toml"), config, 0644)
index := []byte("# Hello, world!\n") index := []byte("---\ntitle: Hello, world!\n---\n")
os.WriteFile(path.Join(name, "content/index.gmi"), index, 0644) os.WriteFile(path.Join(name, "content/_index.gmi"), index, 0644)
templates := []string{"atom.xml", "index.gmi", "page.gmi"} templates := []string{"atom.xml", "index.gmi", "page.gmi"}
for _, template := range templates { for _, template := range templates {