aboutsummaryrefslogtreecommitdiffhomepage
path: root/releaser
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <[email protected]>2022-08-29 11:47:37 +0200
committerBjørn Erik Pedersen <[email protected]>2022-08-29 14:56:15 +0200
commit79932e72257efe2ea525d546b32b3ecd3988605b (patch)
treede3516d3ded61c99a74fdc3b7e4cfe6a3591f9b6 /releaser
parent9eb9b70a29ce84abc754e634e69511c4044e5570 (diff)
downloadhugo-79932e72257efe2ea525d546b32b3ecd3988605b.tar.gz
hugo-79932e72257efe2ea525d546b32b3ecd3988605b.zip
release: Fix the Deb archives
Fixes #10220
Diffstat (limited to 'releaser')
-rw-r--r--releaser/releaser.go7
1 files changed, 5 insertions, 2 deletions
diff --git a/releaser/releaser.go b/releaser/releaser.go
index fc16a2572..afb5079a1 100644
--- a/releaser/releaser.go
+++ b/releaser/releaser.go
@@ -40,14 +40,17 @@ func New(skipPush, try bool, step int) (*ReleaseHandler, error) {
if err != nil {
return nil, err
}
+ branch = strings.TrimSpace(branch)
+
if !strings.HasPrefix(branch, prefix) {
return nil, fmt.Errorf("branch %q is not a release branch", branch)
}
- logf("Branch: %s\n", branch)
-
version := strings.TrimPrefix(branch, prefix)
version = strings.TrimPrefix(version, "v")
+
+ logf("Branch: %s|Version: v%s\n", branch, version)
+
rh := &ReleaseHandler{branchVersion: version, skipPush: skipPush, try: try, step: step}
if try {