diff --git a/README.md b/README.md index cbc534e..a3d08a0 100644 --- a/README.md +++ b/README.md @@ -36,12 +36,7 @@ The theme doesn't require any advanced configuration. Use `config.toml.example` To auto generate information of git commit, add following line to your `deploy.sh` ```bash -gsed -i "/localcommithash/c \\\tlocalcommithash = \"$(git rev-parse HEAD)\"" config.toml -gsed -i "/localcommitdate/c \\\tlocalcommitdate = \"$(git log --pretty=format:"%cd" $(git rev-parse HEAD) -1)\"" config.toml -gsed -i "/localcommitcomment/c \\\tlocalcommitcomment = \"$(git log --pretty=format:"%s" $(git rev-parse HEAD) -1)\"" config.toml -cd public -gsed -i "/binarycommitdate/c \\\tbinarycommitdate = \"$(git log --pretty=format:"%cd" $(git rev-parse HEAD) -1)\"" ../config.toml -cd .. +To be updated... ``` ## Known issues diff --git a/config.toml.example b/config.toml.example index e9c4a81..09f3782 100644 --- a/config.toml.example +++ b/config.toml.example @@ -1,8 +1,12 @@ baseURL = "/" theme = "ztyblog" title = "Welcome" +description = "" copyright = "CC BY-NC 4.0" + +paginate = 10 +rssLimit = 25 languageCode = "zh-CN" hasCJKLanguage = true pygmentsCodeFences = true @@ -10,21 +14,32 @@ pygmentsCodefencesGuessSyntax = false pygmentsStyle = "colorful" enableRobotsTXT = true enableGitInfo = true -Paginate = 10 assetDir = ["/assets", "/themes/ztyblog/assets"] + +[author] + name = "name" + email = "email" + + [params] - author = "" - description = "" - copyright = "" - dateformFull = "2006-01-02 15:04 CST" - updatelisturl = "" - mail = "" - iconfontURL = "//at.alicdn.com/t/font_1559566_z93lvlj24ja.css" - localcommithash = "" - localcommitdate = "" - localcommitcomment = "" - binarycommitdate = "" + [params.links] + homeImage = "" + updateList = "" + iconFont = "//at.alicdn.com/t/font_1559566_z93lvlj24ja.css" + + [params.dateforms] + date = "2006-01-02" + short = "1月2日" + long = "2006-01-02 15:04" + full = "2006-01-02 15:04 CST" + + [params.commit] + commitHash = "" + commitDate = "" + commitMessage = "" + binaryVersion = "" + [[params.social]] identifier = "github" name = "Github" @@ -35,6 +50,7 @@ assetDir = ["/assets", "/themes/ztyblog/assets"] name = "email" icon = "icon-email" url = "" + [params.pagination] class = "pagination justify-content-center" showFirst = true @@ -46,35 +62,36 @@ assetDir = ["/assets", "/themes/ztyblog/assets"] firstIndicator = '' lastIndicator = '' + [menus] - [[menu.main]] + [[menus.main]] identifier = "blog" name = "blog" url = "/blog/" pre = "icon-blog" post = "博客" weight = 1 - [[menu.main]] + [[menus.main]] identifier = "notes" name = "notes" url = "/notes/" pre = "icon-Notes" post = "笔记" weight = 2 - [[menu.main]] + [[menus.main]] identifier = "about" name = "about" url = "/about/" pre = "icon-aboutus" post = "关于我" weight = 3 - [[menu.second]] + [[menus.second]] identifier = "bangumi" name = "bangumi" url = "/bangumi/" pre = "icon-bilibili-line" post = "追番列表" - [[menu.second]] + [[menus.second]] identifier = "friends" name = "friends" url = "/friends/" diff --git a/layouts/index.html b/layouts/index.html index 756d64e..4374362 100644 --- a/layouts/index.html +++ b/layouts/index.html @@ -2,7 +2,7 @@ - + @@ -14,7 +14,7 @@ - 欢迎访问{{.Site.Author.name}}的博客 + 欢迎访问{{ .Site.Author.name }}的博客 diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index f4e6fe9..0a67cc9 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -5,7 +5,7 @@ - {{ .Site.Params.Copyright -}} + {{ .Site.Copyright }} @@ -23,21 +23,21 @@ - {{ substr .Site.Params.Contentcommithash 0 8 }} + {{ substr .Site.Params.commit.hash 0 8 }}
- 欢迎访问{{.Site.Author.name}}的博客 + 欢迎访问{{ .Site.Author.name }}的博客