Update to 0.80.0

Close: rhbz#1856494

Signed-off-by: Robert-André Mauchin <zebob.m@gmail.com>
This commit is contained in:
Robert-André Mauchin 2021-01-19 17:11:54 +01:00
parent abc68b1525
commit 3291efb99c
No known key found for this signature in database
GPG Key ID: F07E690B12A82D56
8 changed files with 83 additions and 38 deletions

1
.gitignore vendored
View File

@ -26,3 +26,4 @@
/hugo-0.72.0.tar.gz
/hugo-0.73.0.tar.gz
/hugo-0.75.1.tar.gz
/hugo-0.80.0.tar.gz

View File

@ -0,0 +1,60 @@
From 5b6b022c98db95a97ee9c6b30ecd69c8ac4c18a9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Robert-Andr=C3=A9=20Mauchin?= <zebob.m@gmail.com>
Date: Mon, 18 Jan 2021 02:35:33 +0100
Subject: [PATCH 1/1] Bump afero to 1.5.1
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Robert-André Mauchin <zebob.m@gmail.com>
---
hugofs/filter_fs.go | 4 ++++
hugofs/noop_fs.go | 4 ++++
hugofs/slice_fs.go | 4 ++++
3 files changed, 12 insertions(+)
diff --git a/hugofs/filter_fs.go b/hugofs/filter_fs.go
index 279a2831..bee4d05d 100644
--- a/hugofs/filter_fs.go
+++ b/hugofs/filter_fs.go
@@ -137,6 +137,10 @@ func (fs *FilterFs) Chtimes(n string, a, m time.Time) error {
return syscall.EPERM
}
+func (fs *FilterFs) Chown(n string, uid, gid int) error {
+ return syscall.EPERM
+}
+
func (fs *FilterFs) LstatIfPossible(name string) (os.FileInfo, bool, error) {
fi, b, err := lstatIfPossible(fs.fs, name)
if err != nil {
diff --git a/hugofs/noop_fs.go b/hugofs/noop_fs.go
index c3d2f2da..12b4e937 100644
--- a/hugofs/noop_fs.go
+++ b/hugofs/noop_fs.go
@@ -80,3 +80,7 @@ func (fs noOpFs) Chmod(name string, mode os.FileMode) error {
func (fs noOpFs) Chtimes(name string, atime time.Time, mtime time.Time) error {
return errNoOp
}
+
+func (fs *noOpFs) Chown(name string, uid int, gid int) error {
+ return errNoOp
+}
diff --git a/hugofs/slice_fs.go b/hugofs/slice_fs.go
index f1682c1b..fd442ee8 100644
--- a/hugofs/slice_fs.go
+++ b/hugofs/slice_fs.go
@@ -60,6 +60,10 @@ func (fs *SliceFs) Chtimes(n string, a, m time.Time) error {
return syscall.EPERM
}
+func (fs *SliceFs) Chown(n string, uid, gid int) error {
+ return syscall.EPERM
+}
+
func (fs *SliceFs) LstatIfPossible(name string) (os.FileInfo, bool, error) {
fi, _, err := fs.pickFirst(name)
if err != nil {
--
2.29.2

View File

@ -1,7 +1,7 @@
diff -up hugo-0.75.1/hugolib/resource_chain_test.go.orig hugo-0.75.1/hugolib/resource_chain_test.go
--- hugo-0.75.1/hugolib/resource_chain_test.go.orig 2020-09-15 08:45:52.000000000 +0200
+++ hugo-0.75.1/hugolib/resource_chain_test.go 2020-09-18 06:09:09.236592187 +0200
@@ -489,7 +489,7 @@ Min HTML: {{ ( resources.Get "mydata/htm
@@ -576,7 +576,7 @@ Min HTML: {{ ( resources.Get "mydata/htm
`)
}, func(b *sitesBuilder) {
b.AssertFileContent("public/index.html", `Min CSS: h1{font-style:bold}`)
@ -19,6 +19,6 @@ diff -up hugo-0.75.1/minifiers/minifiers_test.go.orig hugo-0.75.1/minifiers/mini
rawJS = " var foo =1 ; foo ++ ; "
- minJS = "var foo=1;foo++;"
+ minJS = "var foo=1;foo++"
var rawJSON string
var minJSON string

View File

@ -1,26 +0,0 @@
From 0e066bfe26fa2e37a00afc269d096e54ad27c657 Mon Sep 17 00:00:00 2001
From: Elliott Sales de Andrade <quantum.analyst@gmail.com>
Date: Tue, 18 Feb 2020 06:24:23 -0500
Subject: [PATCH 1/2] Update error message.
Signed-off-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
---
commands/commands_test.go | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/commands/commands_test.go b/commands/commands_test.go
index 3b194489..e45174ba 100644
--- a/commands/commands_test.go
+++ b/commands/commands_test.go
@@ -90,7 +90,7 @@ func TestExecute(t *testing.T) {
defer clean()
resp := Execute([]string{"deploy", "-s=" + dir, "-e=staging", "--target=mydeployment", "--dryRun"})
c.Assert(resp.Err, qt.Not(qt.IsNil))
- c.Assert(resp.Err.Error(), qt.Contains, `no provider registered for "hugocloud"`)
+ c.Assert(resp.Err.Error(), qt.Contains, `no driver registered for "hugocloud"`)
})
c.Run("list", func(c *qt.C) {
--
2.21.1

View File

@ -8,11 +8,10 @@ Last-Update: 2019-08-04
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
--- a/modules/client_test.go
+++ b/modules/client_test.go
@@ -27,7 +27,7 @@ import (
@@ -30,6 +30,7 @@ import (
)
func TestClient(t *testing.T) {
-
+ t.Skip("skip test as network access is not allowed during package build")
modName := "hugo-modules-basic-test"
modPath := "github.com/gohugoio/tests/" + modName

View File

@ -11,9 +11,10 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+++ b/hugolib/hugo_modules_test.go
@@ -41,6 +41,7 @@ import (
)
func TestHugoModulesVariants(t *testing.T) {
+ t.Skip("Skip test as network is inaccessible during package build")
if !isCI() {
if !htesting.IsCI() {
t.Skip("skip (relative) long running modules test when running locally")
}

View File

@ -4,7 +4,7 @@
# https://github.com/gohugoio/hugo
%global goipath github.com/gohugoio/hugo
Version: 0.75.1
Version: 0.80.0
%gometa
@ -29,12 +29,12 @@ Source0: %{gosource}
Patch0001: 0005-skip-modules-TestClient.patch
# https://sources.debian.org/data/main/h/hugo/0.69.0-1/debian/patches/0006-skip-TestHugoModulesTargetInSubFolder.patch
Patch0002: 0006-skip-TestHugoModulesTargetInSubFolder.patch
# Fix error message that changed in gocloud.
Patch0003: 0001-Update-error-message.patch
# Minify 2.9.3 removed Decimals in favor of Precision
Patch0004: 0001-Update-to-minify-2.9.4.patch
# Fix for TestResourceChains/minify failure
Patch0005: 0001-Remove-trailing-semicolon.patch
# Bump afero to 1.5.1
Patch0006: 0001-Bump-afero-to-1.5.1.patch
BuildRequires: golang(github.com/bep/golibsass/libsass) >= 0.7.0
@ -48,15 +48,21 @@ BuildRequires: golang(github.com/bep/golibsass/libsass) >= 0.7.0
%patch0001 -p1
%patch0002 -p1
%patch0003 -p1
%patch0004 -p1
%patch0005 -p1
%patch0006 -p1
# Replace blackfriday import path to avoid conflict with v2
sed -i \
-e 's|"github.com/russross/blackfriday|"gopkg.in/russross/blackfriday.v1|' \
$(find . -name '*.go')
# Pin github.com/evanw/esbuild to v0.8.20
# See https://github.com/gohugoio/hugo/issues/8141
sed -i \
-e 's|"github.com/evanw/esbuild|"github.com/evanw/esbuild-0.8.20|' \
$(find . -name '*.go')
# Skip test that assumes directory is in a git repository
sed -i '/TestPageWithLastmodFromGitInfo/a t.Skip()' hugolib/page_test.go
@ -104,6 +110,10 @@ install -Dp man/* -t %{buildroot}%{_mandir}/man1
%changelog
* Sun Jan 17 22:04:05 CET 2021 Robert-André Mauchin <zebob.m@gmail.com> - 0.80.0-1
- Update to 0.80.0
- Close: rhbz#1856494
* Fri Sep 18 04:37:22 CEST 2020 Robert-André Mauchin <zebob.m@gmail.com> - 0.75.1-1
- Update to 0.75.1

View File

@ -1 +1 @@
SHA512 (hugo-0.75.1.tar.gz) = d942457a00c9cd58a6a2c2081da889e5d6cdf7839d8ed0b74f7a2888babcdbf5fcf2ba297085cf9ddda60f388e0b41e8b2527471d3a515119b7073e8ee9c2831
SHA512 (hugo-0.80.0.tar.gz) = 7942455b1429eda849ff9c09061abb08748619b20ce889b217b7c0aaa67e62e66a8ef3228f894943b6ea464b47e3f7543d81ebb061bb7a04d8106221922471e4