新規ポストを作成するためにhugo new
を実行
$ hugo new post/newpost.md
ERROR 2017/05/13 14:15:04 Error processing archetype file /Users/d_ojima/Documents/hugotest/themes/sometheme/archetypes/default.md: Unable to Cast <nil> to map[string]interface{}
Error: Unable to Cast <nil> to map[string]interface{}
archetypeがなんちゃらとかで怒られる。
原因
/themes/<なにかしらのテーマ>/archetypes
にarchetypeが定義されていないのが原因のようです。
今回使用していたテーマではarchetypeが定義されていませんでした...
本来は次のように投稿タイプごとのarchetypeが定義されている必要があります。
archetypes
├── default.md
├── page.md
└── post.md
解決方法
archetypeを定義すればオッケーです。
/themes/<なにかしらのテーマ>/archetypes
以下にdefault.mdを作成しました。
default.md
date = ""
description = ""
tags = ["", ""]
title = ""