diff options
author | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2018-10-20 17:38:49 +0200 |
---|---|---|
committer | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2018-10-22 20:46:14 +0200 |
commit | eb038cfa0a8ada29dfcba1204ec5c432da9ed7e0 (patch) | |
tree | 9ed33e3517e49ef16f349b70b328feff47ee60d3 /commands/new_site.go | |
parent | 129c27ee6e9fed98dbfebeaa272fd52757b475b2 (diff) |
Convert the rest to new page parser code paths
And remove some now unused code.
See #5324
Diffstat (limited to 'commands/new_site.go')
-rw-r--r-- | commands/new_site.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/commands/new_site.go b/commands/new_site.go index 2233157ed..114ee82f6 100644 --- a/commands/new_site.go +++ b/commands/new_site.go @@ -19,6 +19,8 @@ import ( "path/filepath" "strings" + "github.com/gohugoio/hugo/parser/metadecoders" + _errors "github.com/pkg/errors" "github.com/gohugoio/hugo/create" @@ -131,10 +133,9 @@ func createConfig(fs *hugofs.Fs, inpath string, kind string) (err error) { "title": "My New Hugo Site", "languageCode": "en-us", } - kind = parser.FormatSanitize(kind) var buf bytes.Buffer - err = parser.InterfaceToConfig(in, parser.FormatToLeadRune(kind), &buf) + err = parser.InterfaceToConfig(in, metadecoders.FormatFromString(kind), &buf) if err != nil { return err } |