Commit graph

80 commits

Author SHA1 Message Date
Bjørn Erik Pedersen
0091b1f893 travis: Use proxy.golang.org 2019-05-03 17:58:40 +02:00
Bjørn Erik Pedersen
3db4a1cf7a Update to Go 1.12.2 and Go 1.11.7
Fixes #5819
2019-04-07 18:54:53 +02:00
Bjørn Erik Pedersen
984a73af9e
Update to Go 1.12.1 and Go 1.11.6
Fixes #5755
2019-03-17 08:37:42 +01:00
Bjørn Erik Pedersen
b9e75afd6c
Update to Go 1.12
Fixes #5716
2019-03-07 10:26:26 +01:00
grahamjamesaddis
bdf47e8da8 Update Travis config to work for forked builds 2019-03-05 14:26:49 +01:00
Bjørn Erik Pedersen
8ed2a1caa9 Bump to Go 1.11.5
Fixes #5654
2019-01-31 13:23:55 +01:00
Bjørn Erik Pedersen
bb9c2988f8 Update to Go 1.11.4
Fixes #5524
2018-12-19 11:48:17 +01:00
Emir Beganović
7d78a2afd3 Add Windows build config to Travis 2018-11-13 11:39:54 +01:00
Bjørn Erik Pedersen
cf47f43ff1
ci: Add "go mod download" to CI scripts
To hopefully make them less flaky.
2018-09-24 10:31:59 +02:00
Bjørn Erik Pedersen
2cf8fe2ea2 Fix broken Travis config
See https://github.com/magefile/mage/issues/79
2018-09-06 13:42:41 +02:00
Bjørn Erik Pedersen
c7f057797c travis: Set GO111MODULE=on for mage install
See #5115
2018-08-28 11:22:50 +02:00
Bjørn Erik Pedersen
45c9c45d1d Use Go 1.11 modules with Mage
See #5115
2018-08-25 20:50:58 +02:00
Bjørn Erik Pedersen
d32ff16fd6 Update Travis to Go 1.11 and Go 1.10.4
See #5115
2018-08-25 17:37:42 +02:00
Bjørn Erik Pedersen
dea71670c0
Add Hugo Piper with SCSS support and much more
Before this commit, you would have to use page bundles to do image processing etc. in Hugo.

This commit adds

* A new `/assets` top-level project or theme dir (configurable via `assetDir`)
* A new template func, `resources.Get` which can be used to "get a resource" that can be further processed.

This means that you can now do this in your templates (or shortcodes):

```bash
{{ $sunset := (resources.Get "images/sunset.jpg").Fill "300x200" }}
```

This also adds a new `extended` build tag that enables powerful SCSS/SASS support with source maps. To compile this from source, you will also need a C compiler installed:

```
HUGO_BUILD_TAGS=extended mage install
```

Note that you can use output of the SCSS processing later in a non-SCSSS-enabled Hugo.

The `SCSS` processor is a _Resource transformation step_ and it can be chained with the many others in a pipeline:

```bash
{{ $css := resources.Get "styles.scss" | resources.ToCSS | resources.PostCSS | resources.Minify | resources.Fingerprint }}
<link rel="stylesheet" href="{{ $styles.RelPermalink }}" integrity="{{ $styles.Data.Digest }}" media="screen">
```

The transformation funcs above have aliases, so it can be shortened to:

```bash
{{ $css := resources.Get "styles.scss" | toCSS | postCSS | minify | fingerprint }}
<link rel="stylesheet" href="{{ $styles.RelPermalink }}" integrity="{{ $styles.Data.Digest }}" media="screen">
```

A quick tip would be to avoid the fingerprinting part, and possibly also the not-superfast `postCSS` when you're doing development, as it allows Hugo to be smarter about the rebuilding.

Documentation will follow, but have a look at the demo repo in https://github.com/bep/hugo-sass-test

New functions to create `Resource` objects:

* `resources.Get` (see above)
* `resources.FromString`: Create a Resource from a string.

New `Resource` transformation funcs:

* `resources.ToCSS`: Compile `SCSS` or `SASS` into `CSS`.
* `resources.PostCSS`: Process your CSS with PostCSS. Config file support (project or theme or passed as an option).
* `resources.Minify`: Currently supports `css`, `js`, `json`, `html`, `svg`, `xml`.
* `resources.Fingerprint`: Creates a fingerprinted version of the given Resource with Subresource Integrity..
* `resources.Concat`: Concatenates a list of Resource objects. Think of this as a poor man's bundler.
* `resources.ExecuteAsTemplate`: Parses and executes the given Resource and data context (e.g. .Site) as a Go template.

Fixes #4381
Fixes #4903
Fixes #4858
2018-07-06 11:46:12 +02:00
Anthony Fok
23d5fc82ee
Update to Go 1.9.7 and Go 1.10.3
for Travis CI, Docker and Snap
2018-06-14 15:50:25 -06:00
Bjørn Erik Pedersen
230f2b8c4f
Bump Go versions
Fixes #4545
2018-04-09 11:01:01 +02:00
Anthony Fok
094ec17142
travis: Disable shallow clone to fix TestPageWithLastmodFromGitInfo
Fixes #4584
2018-04-07 06:54:24 -06:00
Anthony Fok
60e66d12ea travis: Clean up and increase verbosity 2018-04-02 09:20:58 +02:00
Anthony Fok
eb15ac37ef travis: Run "gem install" without sudo
Running "sudo gem install" was causing random errors like the following:

ERROR:  While executing gem ... (Errno::EACCES)
    Permission denied @ rb_sysopen - /home/travis/.rvm/gems/ruby-2.4.1/cache/asciidoctor-1.5.6.2.gem

Perhaps sudo is no longer necessary, even on OS X?  :-)
2018-04-02 08:15:35 +02:00
Anthony Fok
511d5d3b76 travis: Move to Ubuntu Trusty image 2018-03-26 09:09:58 -06:00
Bjørn Erik Pedersen
a3f26e5636
Second try: Update to Go 1.10 (!) 2018-02-17 00:35:22 +01:00
Bjørn Erik Pedersen
0c452c6e7d
Revert "Update to Go 1.10 (!)"
This reverts commit ff10c15a93.
2018-02-16 23:42:42 +01:00
Bjørn Erik Pedersen
ff10c15a93
Update to Go 1.10 (!)
See https://blog.golang.org/go1.10
2018-02-16 23:29:51 +01:00
Bjørn Erik Pedersen
0de375a7e7
Bump Travis/Snapcraft to Go 1.9.4 2018-02-07 21:45:53 +01:00
Bjørn Erik Pedersen
96e3fbcf23
travis: Re-enable macOS builds 2018-01-26 17:08:32 +01:00
Bjørn Erik Pedersen
a91aba1c15
Update to Go 1.9.3
Fixes #4328
2018-01-26 17:07:08 +01:00
Bjørn Erik Pedersen
22ad1ebdbb
travis: Disable macOS builds for now
Travis have not been able to build those the last week or so.
2018-01-23 12:59:40 +01:00
Bjørn Erik Pedersen
77cbd001ff
Update Travis and snapcraft to Go 1.9.2
See #4064
2017-11-08 00:37:59 +01:00
Bjørn Erik Pedersen
856fc445da
Bump Go versions in Travis config 2017-10-05 18:50:36 +02:00
Bjørn Erik Pedersen
8d2580f07c Replace make with mage
Fixes #3937
2017-10-05 10:53:02 +02:00
Bjørn Erik Pedersen
fc4a0d1704 Update Travis build to Go 1.9!
Just released: https://blog.golang.org/go1.9
2017-08-25 08:08:17 +02:00
Bjørn Erik Pedersen
07f6e1499c travis: Pull docutils out into requirements.txt 2017-08-11 18:39:04 +02:00
Bjørn Erik Pedersen
e8468a9852 travis: Fix docutils setup 2017-08-11 17:23:40 +02:00
Bjørn Erik Pedersen
359af563a1 travis: Try to fix docutils setup on Linux 2017-08-11 14:21:21 +02:00
Bjørn Erik Pedersen
7198ea8a1e Revert "Remove docs building from CI builds"
Now /docs is a Git subtree, so now this should just work.

This reverts commit 214dbdfb6f.
2017-06-26 21:05:21 +02:00
Bjørn Erik Pedersen
214dbdfb6f Remove docs building from CI builds
We could probably get it working, but we have plenty of site tests now.
2017-06-14 11:16:06 +02:00
Bjørn Erik Pedersen
bde807bd1e travis: Update Go versions 2017-05-26 10:49:40 +03:00
Bjørn Erik Pedersen
9a8b65d8d7 travis: Go 1.8.1 2017-04-07 20:30:45 +02:00
Bjørn Erik Pedersen
b7aa230458 travis: Bump to Go 1.7.5 and 1.8 (Yay!) 2017-02-17 17:39:33 +01:00
Cameron Moore
1d7b960614 Clean up Makefile (#2924)
Add missing deprecated targets.  Remove `test` from `check` target since
we already have `test-race`.

Fixes #2901
2017-01-11 10:07:35 +01:00
Bjørn Erik Pedersen
6374d82b82 travis: Add GOARCH 386 test
Closes #2847
2016-12-29 16:44:39 +01:00
Cameron Moore
f25f837339 Update Travis go versions 2016-12-23 09:49:15 +01:00
Bjørn Erik Pedersen
1992b356b0 Bump Travis to Go 1.7.3 2016-10-19 21:53:56 +02:00
Bjørn Erik Pedersen
27d7aa5f10 travis: Reintroduce asciidoctor to build
Fixes #2524
2016-10-06 09:31:57 +02:00
Bjørn Erik Pedersen
00b3667f30 travis: Remove asciidoctor from build
It fails. Will have to investigate.
2016-10-05 14:36:50 +02:00
Bjørn Erik Pedersen
217d6ea605 travis: Fix asciidoctor build 2016-10-05 14:35:02 +02:00
Bjørn Erik Pedersen
f37f57a814 travis: Lock asciidoctor to 1.5.4
1.5.5 (the newly released) seems to break.
2016-10-05 14:11:56 +02:00
Cameron Moore
6e692f2d11 Add vendoring with govendor 2016-09-19 00:10:10 +02:00
Bjørn Erik Pedersen
a8fad86671 Bump Travis to Go 1.7.1 2016-09-08 00:37:04 +03:00
Cameron Moore
d3627b1747 Simplify Travis build 2016-08-16 17:01:59 -05:00