mirror of
https://github.com/gohugoio/hugo.git
synced 2024-12-29 12:12:22 +00:00
e8380e612f
This commit adds a `GitInfo` object to `Page` if `EnableGitInfo` is set. It then also sets `Lastmod` for the given `Page` to the author date provided by Git. The Git integrations should be fairly performant, but it adds "some time" to the build, somewhat depending on the Git history size. If you want, you can run without during development and turn it on when deploying to the live server: `hugo --enableGitInfo`. Fixes #2102
54 lines
2 KiB
HTML
54 lines
2 KiB
HTML
<div class="row">
|
|
<div class="footer-panel">
|
|
<p>Last revision: {{ .Lastmod.Format "January 2, 2006" }}{{ if .IsPage }}<em>{{ with .GitInfo }}| {{ .Subject }} | {{ .AbbreviatedHash }}{{end }}</em>{{ end }}
|
|
<span style="float: right;">Hugo v{{ .Hugo.Version }} documentation</span>
|
|
</p>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</section>
|
|
|
|
</div>
|
|
|
|
<div class="col-md-1">
|
|
{{ if .IsPage }}
|
|
{{ with .GetParam "next" }}
|
|
<a class="navigation next" href="{{.}}">
|
|
<i class="fa fa-angle-right"> </i>
|
|
</a>
|
|
{{ end }}
|
|
{{ end }}
|
|
</div>
|
|
</div>
|
|
<!-- page start-->
|
|
</section>
|
|
</section>
|
|
<!--main content end-->
|
|
</section>
|
|
<!-- container section end -->
|
|
|
|
<!-- javascripts -->
|
|
<script type="text/javascript" src="/vendor/jquery/js/jquery-2.1.4.min.js"></script>
|
|
<script type="text/javascript" src="/vendor/flesler/js/jquery.scrollTo.min.js"></script>
|
|
<script type="text/javascript" src="/vendor/twitter/js/bootstrap.min.js"></script>
|
|
<!--custom script for all page-->
|
|
<script type="text/javascript" src="/vendor/highlightjs/js/highlight.pack.js"></script>
|
|
<script>hljs.initHighlightingOnLoad();</script>
|
|
<script src="/js/scripts.js"></script>
|
|
<!-- Algolia search -->
|
|
<script type="text/javascript" src="https://cdn.jsdelivr.net/docsearch.js/1/docsearch.min.js"></script>
|
|
<script type="text/javascript">
|
|
docsearch({
|
|
apiKey: '167e7998590aebda7f9fedcf86bc4a55',
|
|
indexName: 'hugodocs',
|
|
inputSelector: '#search-input',
|
|
algoliaOptions: {
|
|
hitsPerPage: 5
|
|
}
|
|
});
|
|
</script>
|
|
<!-- Google Analytics -->
|
|
{{ template "partials/analytics.html" . }}
|
|
</body>
|
|
</html>
|