This commit adds a work flow aroung GoReleaser to get the Hugo release process automated and more uniform:
* It can be run fully automated or in two steps to allow for manual edits of the relase notes.
* It supports both patch and full releases.
* It fetches author, issue, repo info. etc. for the release notes from GitHub.
* The file names produced are mainly the same as before, but we no use tar.gz as archive for all Unix versions.
* There isn't a fully automated CI setup in place yet, but the release tag is marked in the commit message with "[ci deploy]"
Fixes#3358
For pages with translations, add links with hreflang attributes to the
default sitemap template. This helps Google to show the correct
language page in its search results. The syntax used is based on
Google's example at [1].
Also update the sitemap template docs to reflect the changes in the
default template.
[1]
https://support.google.com/webmasters/answer/2620865?hl=en&topic=2370587&ctx=topicFixes#2569
This commit also adds a new command, docshelper, with some utility funcs that adds a JSON datafiles to /docs/data that would be a pain to create and maintain by hand.
Fixes#3242
Livefyre.com is down.
Livefyre was integrated into Adobe's offering.
The product is now called Adobe Experience Manager Livefyre.
Wikipedia points to web.livefyre.com which redirects to the link I provided in the commit.
This page was a real chore chore on the POC. In the event that a new doc site won't be approved by v20, this will at least clean up the broken links I found during my audit. I would like to eventually create this as a [data file](https://github.com/spf13/hugo/pull/2508#commitcomment-18705617) since md tables get unwieldy pretty quickly.
Add vendoring and make targets. Require Go 1.8+ and remove mention of
GOPATH (just assume $HOME/go).
Due to time contraints, the contributing tutorial was only slightly
updated to make obvious corrections.
Fixes#3153
Previously this was left empty, but it is very handy to have a list
of term pages for a given taxonomy. This list can now be paginated
like other page lists. It makes it possible to render summary
content from each terms index page for instance. It also makes it
possible to sort the term pages in the same way that other page
lists can be sorted. An RSS feed is now generated for
KindTaxonomyTerm pages as well.
This also fixes a bug in HugoSites.createMissingPages. Previously
it would only check for existing KindTaxonomyTerm pages if the
taxonomy had any terms defined. So for a taxonomy with no terms
but a taxonomy terms page it would generate a second empty terms
page.
Added article from gettingthingstech.com.
I also cleaned up some poorly-aligned entries near the top of markdown table
(though it doesn't affect the HTML output either way).
This fixes the behavior of .Truncated that was introduced with commit
bef496b97e which was later broken. The
desired behavior is that .Truncated would evaluate to false when there
was nothing after the user defined summary marker.
This also adds a simple unit test to ensure that this feature isn't
broken again. The check for content after the user defined summary
marker is done on the raw content instead of the working copy because
some of the markup renderers add elements after the marker, making it
difficult to determine if there is actually any content.
The behavior (evaluating to false when there is no content, just
summary) is also now documented.
The Param method currently assumes that its argument is a single,
distinct, top-level key to look up in the Params map. This enhances the
Param method; it will now also attempt to see if the key can be
interpreted as a nested chain of keys to look up in Params.
Fixes#2598
Add a new rssLimit site configuration option with default of 15. Prior
to this fix, you could create your own RSS feed to override the default
limit of 15, but we still had a hardcoded limit of 50 items set in
`hugolib.renderRSS()`.
With this option in place, the `range first 15 .Data.Pages` logic is no
longer hardcoded into the embedded RSS template.
Because the size of the slice passed to the template is now limited to
rssLimit instead of 50, this commit is a breaking change for sites
with a custom RSS template that expects more than 15 items.
Fixes#3035
Aerobatic.io migrated their Bitbucket hosting plugin and no longer provide
a free tier with a custom domain. This tutorial covers setting up Firebase
to host a Hugo site that was previously hosted on Aerobatic.
I've written a DokuWiki to hugo conversion tool in python to migrate my blog content to Hugo. I hope others will also benefit from it. Feel free to take a look and give some feedback.
This commit adds a truncate template function for safely truncating text without
breaking words. The truncate function is HTML aware, so if the input text is a
template.HTML it will be truncated without leaving broken or unclosed HTML tags.
{{ "this is a very long text" | truncate 10 " ..." }}
{{ "With [Markdown](/markdown) inside." | markdownify | truncate 10 }}
HugoPhotoSwipe is a command line tool to create and manage PhotoSwipe galleries with Hugo. It resizes images for responsive layouts in PhotoSwipe and generates the Markdown necessary for Hugo to create the gallery. I think this can be a useful tool for Hugo users.
The tutorial for installing on windows didn't mention the exact name of the
hugo executable in windows which is generally hugo_<hugo-version>_windows_<arch>.exe.
The tutorial mentioned the windows executable's name as hugo.exe, which
can be confusing sometimes. So extra information has been added to
rename the executable to hugo.exe which would be easy to use.
Fixes#2656
Add imageConfig function which calls image.DecodeConfig and returns the height, width and color mode of the image. (#2677)
This allows for more advanced image shortcodes and templates such as those required by AMP.
layouts/shortcodes/amp-img.html
```
{{ $src := .Get "src" }}
{{ $config := imageConfig (printf "/static/%s" $src) }}
<amp-img src="{{$src}}"
height="{{$config.Height}}"
width="{{$config.Width}}"
layout="responsive">
</amp-img>
```
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
- removed comma on line 16 to avoid confusion between clauses
- added period to line 24 for consistency
- clarified "read on" on line 30 to follow style above it while
also verbally writing what the author seems to intend
- removed "You probably know what to do." on line 30 due to wordiness
that could lead to confusion and a drag in reading speed
- changed preposition into intended infinitive for syntactical clarity
- removed "easily" as it doesn't describe anything technical and is
confusing (which is why the author may have used a preposition)
All config variables starts with low-case and uses camelCase.
If there is abbreviation at the beginning of the name, the whole
abbreviation will be written in low-case.
If there is abbreviation at the end of the name, the
whole abbreviation will be written in upper-case.
For example, rssURI.
This change adds a canonical alias.html template that is used for page
redirects, and passes the page as data to the template under .Page
Fixes#2533Closes#2576
Organize CSS and Javascript files into directories, separating vendor
source code from home-grown.
Separate new properties and selectors in Bootstrap CSS (already edited
for Hugo) from:
1. Original property values; and
2. Changed property values.
For the home page:
1. Clarify the English text;
2. Add some element names to classes in CSS selectors (to speed loading);
3. Document the Owl Carousel and Highlight.js versions;
4. Add Owl Carousel's license;
5. Restore HTML comments to browser source views;
6. Make the beginning GitHub button transparent on focus (like the others);
7. For the final, colored Twitter and Github buttons:
a. Remove the dotted box on focus; and
b. Color them green on active.
8. To increase (layout/) source readability:
a. Place `class` attributes before `href` attributes;
b. In `class` attributes, place more-specific class names before
less-specific; and
c. Comment the beginnings and ends of Bootstrap rows.
9. To increase understandability during development:
a. Document the meaning of CSS file, `HPstyles` by renaming it to
`home-page-style`;
b. Move inline styling to CSS stylesheets;
c. Separate @media queries to a file;
d. Separate the inline Owl Carousel custom Javascript to a file;
e. Use regular Owl Carousel CSS files instead of minified ones; and
f. Rename the wide, landscape desk background image filename from
`desk-long` to `desk-wide`.
There were some breaking changes etc. that is too late to fix for 0.17.
Let us think this through and add proper author support for Hugo 0.18.
Fixes#2464
Revert "docs: Add documentation for author profiles"
This reverts commit b6673e5309.
Revert "Add First Class Author Support"
This reverts commit cf978c0649.
* Fall back to default language on missing translation file
* Add a i18n-warnings build flag
* If that flag is set, print a parseable and greppable string on missing translation strings
See #2303
The current "rendering language" is needed outside of Site. This commit moves the Language type to the helpers package, and then used to get correct correct language configuration in the markdownify template func.
This commit also adds two new template funcs: relLangURL and absLangURL.
See #2309
And in the same go adjusted some minor parts of the language API:
Add LanguagePrefix alias to Node and rename the Multilingual config section to Languages.
See #2309
Implements:
* support to render:
* content/post/whatever.en.md to /en/2015/12/22/whatever/index.html
* content/post/whatever.fr.md to /fr/2015/12/22/whatever/index.html
* gets enabled when `Multilingual:` is specified in config.
* support having language switchers in templates, that know
where the translated page is (with .Page.Translations)
(when you're on /en/about/, you can have a "Francais" link pointing to
/fr/a-propos/)
* all translations are in the `.Page.Translations` map, including the current one.
* easily tweak themes to support Multilingual mode
* renders in a single swift, no need for two config files.
Adds a couple of variables useful for multilingual sites
Adds documentation (content/multilingual.md)
Added language prefixing for all URL generation/permalinking see in the
code base.
Implements i18n. Leverages the great github.com/nicksnyder/go-i18n lib.. thanks Nick.
* Adds "i18n" and "T" template functions..