Commit graph

4103 commits

Author SHA1 Message Date
Bjørn Erik Pedersen
b6798ee867
Bump some deprecations 2018-03-20 21:13:44 +01:00
Bjørn Erik Pedersen
84f4b731d2
Merge commit '0a23baa6a90901f772c234107c4f12c16c76f4aa' 2018-03-20 21:11:45 +01:00
Bjørn Erik Pedersen
0a23baa6a9 Squashed 'docs/' changes from 211a3c613..3068989b9
3068989b9 Merge commit '7ae9cf2ccb3eecc1ff50f686925249d01cf37c6c'
7ae9cf2cc Squashed 'themes/gohugoioTheme/' changes from d7a475e7..a1768ebb
b55157fae Revert "Anchorify headings up to h4"
b63dd5566 Anchorify headings up to h4
edfe36a19 Test out trac as highlighter style
98dc8d269 Update multilingual.md
a6e4d92c0 Update multilingual.md
86a90edf9 Fix typo 'If will' to 'It will' line 41
6b626fac6 Add a tip for testing custom 404.html on hugo server
6bfc17cfc Update few links to now point to gohugoio organization repos
f66bad971 Remove unintended alias
3bc56e9ec Fix shortcode name in example: image -> img
251142388 Fix broken link
27245af6a Fix the minimum required git version for GH Pages flow
aefc87b4d Fix link in Forestry showcase
489ec5ea0 Squashed 'themes/gohugoioTheme/' changes from 6f3a8bf5..d7a475e7
308a616fd Merge commit '489ec5ea03799fa092d891838c1655e60b34f337'
a80859814 Adjust showcase description

git-subtree-dir: docs
git-subtree-split: 3068989b9c601146e8e6be8c4e8e2b2c679e5230
2018-03-20 21:11:45 +01:00
Bjørn Erik Pedersen
61f6e9f63b
tpl/transform: Add a comments test for Remarshal
See #4521
2018-03-20 18:23:32 +01:00
Bjørn Erik Pedersen
904a3d9ddf
Update Chroma to get Go template support
Fixes #4515
2018-03-19 09:19:47 +01:00
Bjørn Erik Pedersen
f0052b6d0f
commands: Recover from error in server
Issue introduced some days ago.

Fixes #4516
2018-03-18 12:54:06 +01:00
Bjørn Erik Pedersen
da88015776
Spring test cleaning, take 2 2018-03-18 09:54:32 +01:00
Bjørn Erik Pedersen
debd3663dd hugolib: Test cleaning #1 2018-03-17 18:59:07 +01:00
Bjørn Erik Pedersen
af67ad8af1 hugolib: Trim some now superflous tests
These were written as a development aid in some kind of structural change at some point.

They served their purpose then, but these are tests covered elsewhere and is deleted to reduce maintainance.

The reported test covrage is not reduced because of this.
2018-03-17 18:59:07 +01:00
cmal
e46ab29bd2 hugolib: Add Reset method to delete key from Scratch 2018-03-17 00:13:23 +01:00
Bjørn Erik Pedersen
10fef32de6
releaser: Adjust the "thank you" section 2018-03-16 20:56:28 +01:00
Bjørn Erik Pedersen
70005364a2
docs: Add docs for lang.Merge
See https://github.com/gohugoio/hugo/issues/4463
2018-03-16 10:10:01 +01:00
Bjørn Erik Pedersen
ffaec4ca8c
Add a way to merge pages by language
As an example:

```html
{{ $pages := .Site.RegularPages | lang.Merge $frSite.RegularPages | lang.Merge $enSite.RegularPages }}
```

Will "fill in the gaps" in the current site with, from left to right, content from the French site, and lastly the English.

Fixes #4463
2018-03-16 10:10:01 +01:00
Bjørn Erik Pedersen
3886fc1fef Squashed 'docs/' changes from 4e7e1815b..211a3c613
211a3c613 Prepare the forestry.io article for release
23995d6b4 Add forestry.io to showcase
3f177c94e Fix some typos (found by codespell)
dc26e0a5a Clarify the default for site config files and multiple config files
c87c9c62e Review and update the Site config documentation for consistency
a29edc50c Fix the default value of rssLimit site config
83f3c46b0 Minor style fix
4f860d1a2 Typo capitalization fixes
7851345c8 Add docs about comments within templates
d129b4a28 Make the recommendation to use partial over template consistent
6cd260a41 Update index.md
a2787e1a4 Add Let’s Encrypt showcase
7e664f69e Update configuration.md
8002120f1 Update multilingual.md
702b46a62 Add documentation for the disableLanguages setting
cb3d395de Fix content type reference
d33226924 Update Page Kinds documentation
8203f649d Fix misformed markdown link
19e99c957 Add Section definition

git-subtree-dir: docs
git-subtree-split: 211a3c6136c69f49baeae6cd35e5a8853cddf710
2018-03-16 09:44:54 +01:00
Bjørn Erik Pedersen
91fb8f1b59
Merge commit '3886fc1fef6ac19d58b9ba1bb642d0c6c9a54031' 2018-03-16 09:44:54 +01:00
Bjørn Erik Pedersen
ac12d51e7e
create: Remove archetype title/date warning
Closes #4504
2018-03-15 08:52:20 +01:00
Bjørn Erik Pedersen
3fbc75534d
resource: Fix path duplication/flattening in processed images
Fixes #4502
Closes #4501
2018-03-14 17:04:14 +01:00
Bjørn Erik Pedersen
e427ba4268
hugolib: Remove superflous debug file 2018-03-12 23:36:20 +01:00
Bjørn Erik Pedersen
79dd7cb31a
hugolib: Simplify Prev/Next 2018-03-12 22:13:25 +01:00
Bjørn Erik Pedersen
0dbf79c2f8
docs: Add docs on the new front matter configuration
See #4495
2018-03-11 22:51:11 +01:00
Bjørn Erik Pedersen
f12ad7d56a
hugolib: Adjust GitInfo author date test
Now that we have a commit to assert against.

See #4495
2018-03-11 21:32:15 +01:00
Bjørn Erik Pedersen
ce6e4310fe
Refactor the GitInfo into the date handlers
Fixes #4495
2018-03-11 21:32:05 +01:00
Bjørn Erik Pedersen
95d62004a0
Merge commit 'c0290655825e7bb36e13fb39f89d85b392cf1adc' 2018-03-11 20:40:26 +01:00
Bjørn Erik Pedersen
c029065582 Squashed 'docs/' changes from 715741f73..4e7e1815b
4e7e1815b Fix some typos
d23d8f5c4 Remove 'fundamentals' category from function pages
52fa65e15 Mention Chroma as the preferred syntax highlighter
64ca535db Merge commit '8762aee8afe30bec6f1fbc9560749983dc44d60b'
8762aee8a Squashed 'themes/gohugoioTheme/' changes from 396b859f..6f3a8bf5
03f0673a9 Move the gopher to the theme
320e268cd Spelling
e45b640f7 More layout lookup work
fe0ad9d9d Sync the YAML config menu example with TOML's
b9505fc70 Remove template reference to ordinal numbers
0fa2532d3 Remove deprecated Hugoidx, add native hugo solution
2152b907c Fix a link in the last commit
47614f416 Manually specifying heading anchors in Markdown content
9d6770d2a Release notes 0.37.1
e1eed8b27 Remove some unused images
e960046f5 releaser: Prepare repository for 0.38-DEV
4fa83a4ee releaser: Add release notes to /docs for release of 0.37.1
46c879995 releaser: Bump versions for release of 0.37.1
fb3ac5a3e releaser: Prepare repository for 0.38-DEV
4870c8e7b Update archetypes.md
232c0b578 Merge commit '2b18014fd0aa99e9f1a5610ba875101351a90de3'
2b18014fd Squashed 'themes/gohugoioTheme/' changes from fe71e360..396b859f
62567e9aa Add some "writing guidelines"
7cfd530d2 Revise the archetype docs
5d4c3c03c Update data-templates.md
e5fee3099 Update page-bundles.md
ca7f03c8d Update page-bundles.md
2a7fdc269 Fix typo 'vailable' to 'available' line 53
999b75201 LastMod should be Lastmod?
099f46ca5 Fix spacing in content-management/types.md
6bcdc58ef Word choice improvements
20e8a21f6 update rss linking docs
7ef44d262 Add some missing configuration entries
f1c7aa568 Sort config list
5cb8ceade Create a proper definition list for the configuration settings
25dffe4ac Send custom dimensions in GA
55df01a34 Fix broken gtag
6c8772aad Add site to GA config
e63acb894 Remove conflicting release note for 0.35
f30083a23 Add branch to GA config
99caedb96 Set the small-multiples to draft
4a33c70ab Polish the Small Multiples showcase
7b2f1ea2e Add small multiples showcase
e78e96bae Add new sponsor
c42943041 updated to new Forestry logo
e07eda273 Add OS env to faq
414f0dbc6 Release Hugo 0.37
85f0cc324 Merge branch 'temp37'
1e6da9497 Rebuild images
75e97adfc releaser: Add release notes to /docs for release of 0.37
50b887cb0 releaser: Bump versions for release of 0.37
7acf73ba3 Merge commit '900b5f6cfe5a377ef369d26cd700201be4cf6b06'
819d02c30 Merge commit '374d184e6747678364fd61f5faf328ec9205eb6b'
c7eacf018 Fix typos in development contribution doc

git-subtree-dir: docs
git-subtree-split: 4e7e1815b742659dec1c8f59a1896a3396c7b6e9
2018-03-11 20:39:20 +01:00
Bjørn Erik Pedersen
68bf1511f2
hugolib: Extract date and slug from filename
This commit makes it possible to extract the date from the content filename. Also, the filenames in these cases will make for very poor permalinks, so we will also use the remaining part as the page `slug` if that value is not set in front matter.

This should make it easier to move content from Jekyll to Hugo.

To enable, put this in your `config.toml`:

```toml
[frontmatter]
date  = [":filename", ":default"]
```

This commit is also a spring cleaning of how the different dates are configured in Hugo. Hugo will check for dates following the configuration from left to right, starting with `:filename` etc.

So, if you want to use the `file modification time`, this can be a good configuration:

 ```toml
[frontmatter]
date = [ "date",":fileModTime", ":default"]
lastmod = ["lastmod" ,":fileModTime", ":default"]
```

The current `:default` values for the different dates are

```toml
[frontmatter]
date = ["date","publishDate", "lastmod"]
lastmod = ["lastmod", "date","publishDate"]
publishDate = ["publishDate", "date"]
expiryDate = ["expiryDate"]
```

The above will now be the same as:

```toml
[frontmatter]
date = [":default"]
lastmod = [":default"]
publishDate = [":default"]
expiryDate = [":default"]
```

Note:

* We have some built-in aliases to the above: lastmod => modified, publishDate => pubdate, published and expiryDate => unpublishdate.
* If you want a new configuration for, say, `date`, you can provide only that line, and the rest will be preserved.
* All the keywords to the right that does not start with a ":" maps to front matter parameters, and can be any date param (e.g. `myCustomDateParam`).
* The keywords to the left are the **4 predefined dates in Hugo**, i.e. they are constant values.
* The current "special date handlers" are `:fileModTime` and `:filename`. We will soon add `:git` to that list.

Fixes #285
Closes #3310
Closes #3762
Closes #4340
2018-03-11 18:26:18 +01:00
Bjørn Erik Pedersen
f8dc47eeff Allow partial redefinition of the ouputs config
Fixes #4487
2018-03-10 16:57:25 +01:00
Bjørn Erik Pedersen
ae3fa349de
output: Fix build
See #4484
2018-03-09 17:28:20 +01:00
Bjørn Erik Pedersen
64cec07293
outputs: Adjust the layout examples 2018-03-09 13:26:28 +01:00
hugoreleaser
9ac6206584 releaser: Prepare repository for 0.38-DEV
[ci skip]
2018-03-07 17:58:48 +00:00
hugoreleaser
f414966b94 releaser: Add release notes to /docs for release of 0.37.1
[ci skip]
2018-03-07 17:56:23 +00:00
hugoreleaser
c29a2ed2f5 releaser: Bump versions for release of 0.37.1
[ci skip]
2018-03-07 17:56:23 +00:00
Bjørn Erik Pedersen
dfb6484a41
Release 0.37.1 2018-03-07 18:52:14 +01:00
hugoreleaser
8a02968393 releaser: Add release notes draft for 0.37.1
Rename to *-ready.md to continue. [ci skip]
2018-03-07 17:45:56 +00:00
Bjørn Erik Pedersen
e7fda289b1
Remove defaultLayout config
Not in use.
2018-03-01 17:19:49 +01:00
Bjørn Erik Pedersen
50a03a5acc
commands: Do not print build total when --quiet is set
Fixes #4456
2018-02-27 21:04:39 +01:00
Bjørn Erik Pedersen
ba94abbf5d
resource: Fix SVG and similar resource handling
The validation of if we could process the image (resize etc.) was moved up in Hugo 0.37, which meant SVG and other "non-processable" images would fail.

This commit fixes that by creating a regular resource for these image formats. They will not have `.Resize` or any of the other image methods.

Fixes #4455
2018-02-27 18:29:15 +01:00
Bjørn Erik Pedersen
55fb0eac20
releaser: Remove suplerflous release notes slug 2018-02-27 10:33:35 +01:00
hugoreleaser
06e5ee6526 releaser: Prepare repository for 0.38-DEV
[ci skip]
2018-02-27 09:17:53 +00:00
hugoreleaser
956a2dce8d releaser: Add release notes to /docs for release of 0.37
[ci skip]
2018-02-27 09:15:23 +00:00
hugoreleaser
1f1c562b9c releaser: Bump versions for release of 0.37
[ci skip]
2018-02-27 09:15:23 +00:00
Bjørn Erik Pedersen
3e1a6ebc11
Release 0.37 2018-02-27 10:06:15 +01:00
hugoreleaser
8915cb83f4 releaser: Add release notes draft for 0.37
Rename to *-ready.md to continue. [ci skip]
2018-02-27 08:43:18 +00:00
Bjørn Erik Pedersen
900b5f6cfe Squashed 'docs/' changes from 1dc05a16b..715741f73
715741f73 Add Netlify config for a split testin branch
4917f0636 Mention that math add/sub/mul/div functions can do float math too
31632beeb Document .Site.Params.mainSections
3416ba80d Update sectionvars.md
295ccb463 Update sections.md
15b5a0342 Fix duplicated paragraph
eb13db670 Fix text highlight
fa46cafdf Get 1password-support ready
979bb5698 Add 1password support showcase
ceb94d1e1 Fix readDir function links

git-subtree-dir: docs
git-subtree-split: 715741f7393cec2a9b34254bda6e815e9391a632
2018-02-27 09:36:36 +01:00
Bjørn Erik Pedersen
57637d89ec
Merge commit '900b5f6cfe5a377ef369d26cd700201be4cf6b06' 2018-02-27 09:36:36 +01:00
Bjørn Erik Pedersen
13ea1e7c35 resource: Use Floyd-Steinberg dithering for PNGs
Fixes #4453
2018-02-26 19:44:36 +01:00
Bjørn Erik Pedersen
9f740b37cf
hugolib: Fix paginator URL for sections with URL in front matter
Fixes #4415
2018-02-26 17:45:51 +01:00
Bjørn Erik Pedersen
e39797fa72
hugolib: Avoid scanning entire site to find the home
See #4447
2018-02-25 10:50:44 +01:00
Vas Sudanagunta
00868081f6 Fix bug in Site.assembleSections method
Site.assembleSections logic assumes that the the home page would always be the first in the Site's list of pages. This is not in fact guaranteed to be true. When it is not, the method can fail to set the parent for some or all root-level pages. 

Fixes #4447
2018-02-25 10:34:24 +01:00
Bjørn Erik Pedersen
e9750d831f
hugolib: Continue GitInfo lookup on error
The current logic stops looking after the first failure to connect a page with a Git commit. This implies a fatal error, but that may not be the case.
2018-02-22 17:21:09 +01:00
Bjørn Erik Pedersen
19d9a46f63
Properly handle -DEV suffix when comparing Hugo versions
See #4443
2018-02-22 17:16:42 +01:00