Commit graph

96 commits

Author SHA1 Message Date
Bjørn Erik Pedersen
3cc41523be Update to Go 1.14.3 and Go 1.13.11 2020-05-16 23:25:45 +02:00
Bjørn Erik Pedersen
1d91d8e14b Update to Go 1.14.1 and 1.13.9
Fixes #7078
2020-03-20 18:25:54 +01:00
Bjørn Erik Pedersen
33ae621083 Update to Go 1.14 and 1.13.8
Fixes #6958
2020-02-26 17:33:11 +01:00
Bjørn Erik Pedersen
56d0b65887 Add "go mod verify" to build scripts 2020-02-16 00:15:58 +01:00
Bjørn Erik Pedersen
0792cfa9fa Update to Go 1.13.7 and Go 1.12.16
Fixes #6830
2020-01-31 14:18:48 +01:00
Bjørn Erik Pedersen
031f948f87 Update to Go 1.13.4 and Go 1.12.13 2019-11-25 18:59:06 +01:00
Anthony Fok
cafecca440 travis: Increase timeout to 30000 for mage -v check
The default timeout of 15000 millisecond is too short
for go test -race on arm64.

See golang/go#35308
2019-11-08 08:24:41 +01:00
Bjørn Erik Pedersen
ad4c56b551 travis: Allow arm64 to fail
As that is what it does at the moment.
2019-11-04 09:29:12 +01:00
Anthony Fok
ae4fde0866 Update .travis.yml for arm64 support, etc.
- Add arm64 support for Linux thanks to Travis CI’s new feature, see
  https://blog.travis-ci.com/2019-10-07-multi-cpu-architecture-support
- Force GO111MODULE=on
- Cache directories
- Switch to bionic (Ubuntu 18.04) environment
- Use "master" instead of "tip" to match the latest Travis CI docs
- Allow "mage -v check" to fail on non-AMD64 architectures
  because "go test -race ./..." currently fails on arm64 and ppc64le.
2019-11-01 11:03:06 -06:00
Bjørn Erik Pedersen
71b18a0786 Update to Go 1.12.10 and 1.13.1
Fixes #6406
2019-10-10 09:50:44 +02:00
Bjørn Erik Pedersen
b43130115d
Update to Go 1.13
Fixes #6304
2019-09-04 00:54:41 +02:00
Bjørn Erik Pedersen
05d83b6c08
Update to Go 1.11.13 and 1.12.9
Fixes #6228
2019-09-03 10:05:17 +02:00
Bjørn Erik Pedersen
f77a4a2f4a
Revert "Update to Go 1.11.13 and 1.12.9"
This reverts commit f28efd3582.
2019-08-17 19:38:12 +02:00
Bjørn Erik Pedersen
f28efd3582
Update to Go 1.11.13 and 1.12.9
Fixes #6228
2019-08-16 10:46:34 +02:00
Bjørn Erik Pedersen
58a47ccde0
travis: Ignore errors in go mod download
It sometimes fails with 502 errors, but the dependency download later when tests are run.
2019-07-17 15:35:31 +02:00
Bjørn Erik Pedersen
71b8d8b6a4
Update to Go 1.12.5 and Go 1.11.10
Fixes #5944
2019-05-15 07:49:04 +02:00
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