1 Commits

Author SHA1 Message Date
Yihui Xie
b11ef1e4b2 enable Google Analytics 2018-03-21 10:39:16 -05:00
4 changed files with 4 additions and 10 deletions

View File

@@ -2,12 +2,11 @@ baseurl = "/"
languageCode = "en-us" languageCode = "en-us"
title = "A minimal Hugo website" title = "A minimal Hugo website"
theme = "hugo-xmin" theme = "hugo-xmin"
googleAnalytics = "" googleAnalytics = "UA-1988641-2"
disqusShortname = "" disqusShortname = ""
ignoreFiles = ["\\.Rmd$", "\\.Rmarkdown$", "_files$", "_cache$"] ignoreFiles = ["\\.Rmd$", "\\.Rmarkdown$", "_files$", "_cache$"]
preserveTaxonomyNames = true preserveTaxonomyNames = true
footnotereturnlinkcontents = "↩" footnotereturnlinkcontents = "↩"
paginate = 1
[permalinks] [permalinks]
post = "/post/:year/:month/:day/:slug/" post = "/post/:year/:month/:day/:slug/"

View File

@@ -2,3 +2,5 @@
<script async src="//cdn.bootcss.com/mathjax/2.7.1/MathJax.js?config=TeX-MML-AM_CHTML"></script> <script async src="//cdn.bootcss.com/mathjax/2.7.1/MathJax.js?config=TeX-MML-AM_CHTML"></script>
<script async src="//yihui.name/js/center-img.js"></script> <script async src="//yihui.name/js/center-img.js"></script>
{{ template "_internal/google_analytics.html" . }}

View File

@@ -7,14 +7,12 @@
{{ .Content }} {{ .Content }}
<ul> <ul>
{{ $paginator := .Paginate (where .Data.Pages "Section" "!=" "") }} {{ range (where .Data.Pages "Section" "!=" "") }}
{{ range $paginator.Pages }}
<li> <li>
<span class="date">{{ .Date.Format "2006/01/02" }}</span> <span class="date">{{ .Date.Format "2006/01/02" }}</span>
<a href="{{ .URL }}">{{ .Title }}</a> <a href="{{ .URL }}">{{ .Title }}</a>
</li> </li>
{{ end }} {{ end }}
</ul> </ul>
{{ template "_internal/pagination.html" . }}
{{ partial "footer.html" . }} {{ partial "footer.html" . }}

View File

@@ -22,11 +22,6 @@ hr {
color: #ddd; color: #ddd;
} }
/* pagination */
.pagination { text-align: center; }
.pagination li { display: inline; }
.pagination a { padding: 0 .2em; }
/* code */ /* code */
pre { pre {
border: 1px solid #ddd; border: 1px solid #ddd;