1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-01-04 03:11:55 +02:00
Commit Graph

841 Commits

Author SHA1 Message Date
Pedro López Mareque
d32454e279
Add telegram announcer (#2563)
* feat: add telegram announcer

* chore: remove hooks and use the Send method of the bot API

* chore: add docs and default config

* chore: add docs and default config

* chore: fix tabs

* chore: add docs

* chore: fix pr comments

* chore: fix pr comments

* chore: fix pr comments

* chore: add missing links in docs
2021-10-07 13:01:31 +00:00
Carlos A Becker
1f774d5d6a
fix: changelog filters and sort when using github
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-06 01:15:31 -03:00
Carlos A Becker
d7e1bcc1f0
fix: armv7 on linux is usually armv7l
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-05 23:15:21 -03:00
Carlos A Becker
18ca16d547
test: gitlab download url template
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-05 22:06:20 -03:00
Carlos A Becker
d7e5ea5abf
test: use mock client
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-05 20:53:17 -03:00
Carlos A Becker
ced5347388
refactor: improve scmChangeloger
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-04 23:35:28 -03:00
Carlos Alexandro Becker
16f1304498
test: speed up minio tests (#2550)
* test: speed up minio tests

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: speed up minio tests

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: speed up minio tests

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: rm unused param

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: use not-so-common contianer name

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: speed

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: inc coverage

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: inc coverage

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-04 10:14:51 -03:00
Carlos Alexandro Becker
89e5a4ebf1
feat: changelog from github (#2548)
* feat: changelog from github

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* refactor: unifying client mocks

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* refactor: unifying client mocks

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: mocks

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: added tests

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: remove unused code

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: added more

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: testdata

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: fmt

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: fix

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: fix

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* docs: improve docs

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-04 09:32:30 -03:00
Carlos Alexandro Becker
c739724f12
refactor: unifying client mocks (#2549)
* refactor: unifying client mocks

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* refactor: unifying client mocks

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-03 13:24:20 -03:00
Drew Stinnett
e0315ff4c4
feat: allow default branch to be used in CreateFile (#2539)
* feat: allow default branch to be used in gitlab

* feat: add func to get default branch

* fix: matching branch args

* feat: branch customization

* fix: fixing dummyclient naming

* refactor: remove createbranch

* feat: Adding gitlab branch customization

* feat: testing for github and gitea defaultbranch

* fix: remove dummy debug message

* fix: removing note about gitea not being supported

* feat: allow default branch to be used in gitlab

* docs: links updat

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* chore: delete kodiak.yml

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* feat: add func to get default branch

* fix: matching branch args

* feat: branch customization

* fix: docs: Missing mattermost docs on website (#2543)

* docs: update CircleCI example (#2545)

* fix: fixing dummyclient naming

* docs: some little fixes on the webpage (#2547)

* feat: some little fixes on the webpage

Signed-off-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>

* Update www/docs/overrides/home.html

Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

* refactor: remove unused not impl error (#2540)

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* feat: add template support for homebrew tap owner (#2544)

* feat: add template support for homebrew tap name

refs #2544

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* refactor: remove createbranch

* feat: Adding gitlab branch customization

* feat: testing for github and gitea defaultbranch

* fix: remove dummy debug message

* fix: removing note about gitea not being supported

Co-authored-by: Carlos Alexandro Becker <caarlos0@gmail.com>
Co-authored-by: Engin Diri <engin.diri@mail.schwarz>
Co-authored-by: Ricardo N Feliciano <FelicianoTech@gmail.com>
Co-authored-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>
Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
Co-authored-by: Erik Weber <terbolous@gmail.com>
2021-10-03 11:22:26 -03:00
Carlos Alexandro Becker
b50334f485
feat: add template support for homebrew tap name
refs #2544

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-10-02 12:53:06 -03:00
Erik Weber
20e14dd204
feat: add template support for homebrew tap owner (#2544) 2021-10-02 12:46:27 -03:00
Carlos Alexandro Becker
0d4430269b
refactor: remove unused not impl error (#2540)
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-10-02 12:39:52 -03:00
Carlos Alexandro Becker
e2f7c83064
feat: allow to skip announcers (#2528)
* feat: allow to skip announcers

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* docs: announce.skip

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-28 22:33:04 -03:00
Carlos Alexandro Becker
395a148300
refactor: improve brew templates (#2530)
* refactor: improve brew templates

based on #2509

Co-authored-by: Engin Diri <engin.diri@mail.schwarz>
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: improve templates a bit

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* refactor: improve check

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* refactor: improve less

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* refactor: improve counts

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

Co-authored-by: Engin Diri <engin.diri@mail.schwarz>
2021-09-28 21:34:35 -03:00
Carlos Tadeu Panato Junior
519a4f67c5
feat: announce: mattermost (#2536)
Signed-off-by: Carlos Panato <ctadeu@gmail.com>
2021-09-28 20:18:35 -03:00
Engin Diri
d2a63c1093
feat: publish: GoFish integration (#2509)
Signed-off-by: Engin Diri <engin.diri@mail.schwarz>
2021-09-28 20:16:39 -03:00
Carlos Alexandro Becker
c7580bf49f
fix: add a debug log on git config
refs #2537

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-28 10:49:59 -03:00
Carlos Alexandro Becker
0c51988ff1
fix: add a debug log on git config
refs #2537

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-28 10:48:49 -03:00
Carlos Alexandro Becker
2b646008f4
fix: add a debug log on git config
refs #2537

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-28 10:45:57 -03:00
Carlos Alexandro Becker
7b44f8da7f
test: add more url tests
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-28 10:43:54 -03:00
Engin Diri
8881328041
fix: regression on nil pointer check (#2533)
Signed-off-by: Engin Diri <engin.diri@mail.schwarz>
2021-09-28 09:11:04 -03:00
Drew Stinnett
608d48ab30
fix: bug in handling gitlab-ci style urls (#2527) 2021-09-28 00:08:22 +00:00
Carlos Alexandro Becker
c90f1085f2
fix: do not skip any defaults (#2521)
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-27 10:14:04 -03:00
Carlos Alexandro Becker
29016cb0e3
fix: brew/scoop panic (#2515) 2021-09-27 08:13:56 -03:00
Carlos Alexandro Becker
833db79bda
feat: removes deprecated non-semver allowance (#2503)
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-23 00:39:28 -03:00
Steve Azzopardi
421b92f375
feat: support subgroups in GitLab (#2474)
Background
---
GitLab supports
[subgroups](https://docs.gitlab.com/ee/user/group/subgroups/) so a
repository can look something like
`gitlab.com/top-level-group/sub-group/repository` for example https://gitlab.com/gitlab-com/gl-infra/jsonnet-tool.

At the moment this detection doens't work out of the box and requires
the user to set the
[`owner`](8b0781e576/.goreleaser.yml (L32-35))

Solution
---
Instead of dropping off the nested sub-groups automatically add them.

Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2021-09-23 00:34:14 -03:00
Carlos Alexandro Becker
f7c865c4d9
refactor: split go mod into 2 pipes (#2502)
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-22 22:25:26 -03:00
Carlos Alexandro Becker
28ef87b4b0
test: another try fixing minio tests
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-22 16:23:28 -03:00
Carlos Alexandro Becker
7c8c942b36
chore: fix wording
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-22 01:21:33 -03:00
Carlos Alexandro Becker
722343125a
test: remove bucket after test
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-22 01:19:37 -03:00
Carlos Alexandro Becker
ad7df518b6
test: fix minio tests
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-22 01:01:32 -03:00
Carlos Alexandro Becker
72053773d7
test: fix broken test
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-21 23:29:54 -03:00
Carlos Alexandro Becker
a8a3061fe9
fix: debug skip
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-18 10:25:28 -03:00
Carlos Alexandro Becker
61bead8989
feat: improve output and pipe skipping (#2480)
* refactor: improve middleware

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: upload tests

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: twitter tests

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: source tests

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: snapshot tests

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: improved some tests

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: snapcraft skip

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip slack

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip sign

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip scoop

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip reddit

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip discord

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip publish

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip nfpm

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip milestone

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip custompublishers

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip checksums

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip changelog

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip brew

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip blob

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip before

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip artifactory

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip announce

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip defaults

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: cmds

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip docker

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* chore: todo

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: go.mod

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip release

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: remove old skip pipe errors

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip teams

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip brew

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix/test: skip smtp

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: lint issues

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip docker

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip brew and scoop

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip docker

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: skip http/artifactory

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: increase coverage

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: fix

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-18 10:21:29 -03:00
Erkan Zileli
35cb87e66a
fix(buildpacks): add if check when copying Dockerfile (#2493)
Signed-off-by: Erkan Zileli <erkan.zileli@trendyol.com>
Co-authored-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>
Co-authored-by: Furkan Türkal <furkan.turkal@trendyol.com>

Co-authored-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>
Co-authored-by: Furkan Türkal <furkan.turkal@trendyol.com>
2021-09-16 22:18:44 +00:00
Carlos Alexandro Becker
820194cc92
docs: typo
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-16 14:32:36 -03:00
Batuhan Apaydın
4fb4ee67af
feat: Allow to specify the git remote name (#2486)
Signed-off-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>
Co-authored-with: Erkan Zileli <erkan.zileli@trendyol.com>
Co-authored-with: Furkan Türkal <furkan.turkal@trendyol.com>
2021-09-15 19:12:45 +00:00
Batuhan Apaydın
afad409c76
feat: add SMTP support to the announces (#2485)
Signed-off-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>
Co-authored-with: Erkan Zileli <erkan.zileli@trendyol.com>
Co-authored-with: Furkan Turkal <furkan.turkal@trendyol.com>
2021-09-15 18:38:58 +00:00
Carlos Alexandro Becker
e8c1a8af52
chore: gofumpt
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-12 19:59:26 -03:00
Engin Diri
1c44c2149d
feat: announce: teams (#2482)
Signed-off-by: Engin Diri <engin.diri@mail.schwarz>
2021-09-12 19:57:58 -03:00
Carlos Alexandro Becker
7b0b88f282
refactor: docker sign is actually a publisher
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-11 14:46:30 -03:00
Carlos Alexandro Becker
435593ae41
chore: gofumpt
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-11 14:36:40 -03:00
Carlos Alexandro Becker
6f219c2c38
test: coverage of buildtarget package
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-11 14:33:01 -03:00
Engin Diri
311479504e
feat: announce: discord (#2478)
Signed-off-by: Engin Diri <engin.diri@mail.schwarz>
2021-09-11 17:23:54 +00:00
Carlos Alexandro Becker
0017dc9351
fix: nfpm subdir in binary name
closes #2476

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-11 13:04:13 -03:00
Carlos Alexandro Becker
d77f862fa4
refactor: improve build (#2475)
* refactor: improve build

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: coverage

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-11 13:01:57 -03:00
Erkan Zileli
5ea003c6f6
feat(docker): add buildpacks support (#2461)
* feat(docker): add buildpacks support

Signed-off-by: Erkan Zileli <erkanzileli@gmail.com>

* fix: move buildpacker imager code into own go file

Signed-off-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>

* fix: use docker imager push method for buildpack imager push

Signed-off-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>

* fix: return statement

Signed-off-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>

* move test into api_buildback_test

Signed-off-by: Furkan <furkan.turkal@trendyol.com>

* fix: use buildpacks instead of buildpack

Signed-off-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>

* fix(lint): fix lint issue

* fix(buildpacks): use cwd instead of root directory

* doc: add how to use a custom buildpack document

Signed-off-by: Erkan Zileli <erkan.zileli@trendyol.com>

* fix(doc): update docs as suggested

Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

Co-authored-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>
Co-authored-by: Furkan <furkan.turkal@trendyol.com>
Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2021-09-11 02:21:33 +00:00
Steve Azzopardi
b0a6bf4705
fix: panic on gitlab create release (#2473)
Background
---
In 5bcfa9042d the condition was changed to
that it can support the new status code returned by GitLab. However, the
condition is now checked `resp != nil` and not `resp == nil` which causes
the condition not to trigger when the resp is nil and only returns an
error. We can reproduce this issue by running
`TestGitLabCreateReleaseUknownHost` test added in this commit.

Solution
---
If we look at other error handling
91a8abb2e6/internal/client/gitlab.go (L106)
we can see that we check if the `resp` is nil as well before continuing.

Added tests for the following use cases:
- When there is an error and no response was returned.
- When there is a 403 or 404 error so we expect to create a release
  first.
- When there is an unknown error (not 404, 403) we just bail.
2021-09-10 16:35:42 -03:00
Steve Azzopardi
68ff8e996f
feat: support templates for scm urls (#2465)
Background
---
When a git repository is hosted in multiple GitLab instances the
`.goreleaser.yml` needs to take in consideration both APIs endpoints. At
the moment it defaults to GitLab.com and you can override it with
`gitlab_urls` however this forces you to only support 1 GitLab instance.

We need this for
https://gitlab.com/gitlab-com/gl-infra/infrastructure/-/issues/14122
where we have a tool that is developed on GitLab.com but then mirrored
to an internal GitLab instance since we need it to operate GitLab.com
even when it's down.

Solution
---
Support templates like `{{ .Env.CI_SERVER_URL }}` for the
`gitlab_urls`, `github_urls`  and `gitea_urls` so it can use environment
variables and the same `.goreleaser` file can be used in multiple SCM
instances.

Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2021-09-09 01:42:13 +00:00
Carlos Alexandro Becker
8afb5eafe5
feat: Add support for templating NFPM bindir (#2466)
* feat: Add support for templating NFPM bindir

Example: Allow software to be deployed in '/usr/lib64' directory on x86_64 arch
and in '/usr/lib' directory in i386

* test: invalid bindir template

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* docs: bindir template

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

Co-authored-by: Rémi Ferrand <remi.ferrand@cc.in2p3.fr>
2021-09-07 15:43:06 -03:00
Batuhan Apaydın
5a01a10f9b
fix: clean user information from remote url if it contains username and token (#2457) 2021-09-03 20:06:53 -03:00
Joe
1e40bbacfa
fix: link in example config to https (#2455) 2021-09-03 09:51:08 -03:00
Carlos Alexandro Becker
19cd0e2289
refactor: remove unneeded if
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-01 23:17:01 -03:00
Carlos Alexandro Becker
0e54c8d882
test: checksum extra file that does not exist
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-01 23:16:26 -03:00
angie pinilla
9667216403
feat: add support for checksum generation for extra files (#2406)
Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2021-09-01 23:07:43 -03:00
Carlos Alexandro Becker
a9239e875d
chore : fmt
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-01 16:47:53 -03:00
Furkan Türkal
aa28f31ab5
feat: announce: slack (#2429)
Fixes #2425

Signed-off-by: Furkan <furkan.turkal@trendyol.com>
2021-09-01 16:46:25 -03:00
Carlos Alexandro Becker
b661a57105
feat: allow to template brew message (#2447)
closes #2441

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-01 10:27:31 -03:00
Carlos Alexandro Becker
b63e544725
feat: templateable nfpm key files (#2448)
closes #2419

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-01 10:27:08 -03:00
Carlos Alexandro Becker
1052ce17de
fix: log docker args on debug
refs #2438

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-31 23:34:21 -03:00
Carlos Alexandro Becker
b132d00aec
fix: build dir that dont exist yet (#2435)
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-31 22:42:15 -03:00
Carlos Alexandro Becker
788add91d7
chore: fmt
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-31 10:49:22 -03:00
Batuhan Apaydın
d3db692a0b
feat: announce: reddit (#2431)
* feat: announce: reddit

Signed-off-by: Batuhan Apaydın <batuhan.apaydin@trendyol.com>

* Update .goreleaser.yml

* Update internal/pipe/announce/announce.go

* Update pkg/defaults/defaults.go

Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2021-08-31 10:48:45 -03:00
Carlos Alexandro Becker
dd5ccf7170
feat: use go 1.17 (#2408)
* feat: use go 1.17

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: go mod tidy

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: fix failing test

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* ci: increase lint timeout

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* ci: increase lint timeout

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-24 20:49:11 -03:00
Carlos Alexandro Becker
ad57a133fb
feat: sign docker images with cosign (#2423)
* feat: sign docker images with cosign

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: improve sign logging

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: do not sign if skip publish is set

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: install cosign

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* docs: fix wrong docs

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-24 11:22:09 -03:00
Carlos Alexandro Becker
5bdbffc96f
feat: allow to template signs.stdin
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-23 22:00:44 -03:00
Carlos Alexandro Becker
67e2dc6020
refactor: lint issues
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-21 11:11:01 -03:00
Christian Mäder
757701f65c
feat: snapshot.name_template should use tag instead of version (#2417)
* fix: Change the init-template for snapshot.name_template

* fix: Change the default-template for snapshot.name_template

BREAKIND CHANGE: The default value of `snapshot.name_template` is changed.
2021-08-21 10:59:15 -03:00
Carlos Alexandro Becker
4c399575fc
fix: prevent panic on invalid git remote url (#2416)
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-21 10:57:19 -03:00
Rob Prentiss
013bd69126
fix: run 'go version' command in build.Dir (#2411)
Currently, the 'goVersion' function is run without any directory set.
This is problematic when a build uses the 'dir' config in combination
with the 'gobinary' config. When 'gobinary' is a relative path (like a
script in the current repository), goVersion silently fails, returning
an empty string.

This commit refactors 'goVersion' to execute the command with '.Dir' set
to the 'build.Dir', in addition to now returning an error, so that
issues may be bubbled up in the build log, rather than silently failing.

It also adds a new helper function to facilitate running 'goVersion' by
creating a temporary executable that outputs a given 'version' string.
This function is only currently used by 'TestWithDefaults'.

Co-authored-by: Rob Prentiss <prentiss@apple.com>
2021-08-21 10:56:54 -03:00
Carlos Alexandro Becker
3966921c86
fix: upload gcs blobs to bucket root (#2409)
* fix: upload gcs blobs to bucket root

* test: blob upload to bucket root

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

Co-authored-by: Adam Bouqdib <adam@abemedia.co.uk>
2021-08-17 00:31:20 -03:00
Carlos Alexandro Becker
a813644522
feat: support windows/arm64 (#2407)
* feat: support windows/arm64

closes #2404
closes #2405

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: broken test

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* docs: deprecation warnings

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-16 23:00:56 -03:00
Carlos Alexandro Becker
d329a9c0d3
feat: add id to dockers and docker_manifests (#2399)
* feat: add id to dockers and docker_manifests

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* feat: actually allow to use the images

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-16 22:11:54 -03:00
Carlos Alexandro Becker
72b7f3b302
feat: remove deprecated docker options (#2400)
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-16 15:21:16 -03:00
Carlos Alexandro Becker
a4a96eab54
fix: main check when using gomod.proxy (#2390)
* fix: main check when using gomod.proxy

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: main check when using gomod.proxy

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: fix

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: fix

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-08-13 20:33:48 -03:00
Jonas Lundberg
7f0edf6fe0
fix: make scoop write .json when --skip-publish (#2380)
* fix: make scoop write .json when --skip-publish

Don't skip the pipeline altogether but write
out the manifest.json file as the homebrew
pipeline does, only skip committing to the repo.

closes #2374

* Update internal/pipe/scoop/scoop_test.go

Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2021-08-03 02:37:02 +00:00
Edward Maxwell-Lyte
18695c2687
fix: sort tags by version not day of the week (#2377)
* fix: tag sorting

When the HEAD commit has multiple tags, they are sorted in order to select the latest so that it can be released.

However, the existing sort would not work if there were multiple commits across a Wednesday and a Thursday.

For example:

```
git tag --points-at HEAD --format='%(creatordate)%09%(refname)'
Wed Jul 28 07:13:19 2021 +0000  refs/tags/v0.0.183
Thu Jul 29 13:31:07 2021 +0000  refs/tags/v0.0.184
Thu Jul 29 13:38:42 2021 +0000  refs/tags/v0.0.185
Thu Jul 29 13:57:44 2021 +0000  refs/tags/v0.0.186
```

When using the existing sort the `creatordate` field was targeted and reversed. Alphabetically Thursday comes before Wednesday, so that is reversed and the Wednesday release always comes first:
```
git tag --points-at HEAD --sort=-version:creatordate --format='%(creatordate)%09%(refname)'
Wed Jul 28 07:13:19 2021 +0000  refs/tags/v0.0.183
Thu Jul 29 13:57:44 2021 +0000  refs/tags/v0.0.186
Thu Jul 29 13:38:42 2021 +0000  refs/tags/v0.0.185
Thu Jul 29 13:31:07 2021 +0000  refs/tags/v0.0.184
```

This would make goreleaser attempt to release that existing tag again, and fail.

If we instead sort by reversed `refname` we get the tags ordered by their numeric value, which ignore the day of the week of release:
```
git tag --points-at HEAD --sort=-version:refname --format='%(creatordate)%09%(refname)'
Thu Jul 29 13:57:44 2021 +0000  refs/tags/v0.0.186
Thu Jul 29 13:38:42 2021 +0000  refs/tags/v0.0.185
Thu Jul 29 13:31:07 2021 +0000  refs/tags/v0.0.184
Wed Jul 28 07:13:19 2021 +0000  refs/tags/v0.0.183
```

Allowing the latest version, 0.0.186 in this case, to be targeted for release.

* corrected test case

* add space

* remove space
2021-08-02 16:20:09 +00:00
Carlos Alexandro Becker
27139e251a
fix: better custom publisher logs
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-07-26 09:04:50 -03:00
Carlos Alexandro Becker
1dd2ad1ae6
fix: return an err with stdout/err when a command failed (#2363)
* fix: return an err with stdout/err when a command failed

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* chore: fmt

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: fixes

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-07-24 21:32:04 -03:00
Carlos Alexandro Becker
2a304f5932
chore: improve pre-commit
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-07-24 21:21:22 -03:00
Carlos Alexandro Becker
c63d704ce6
test: fix
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-07-24 21:20:08 -03:00
Carlos Alexandro Becker
f37c045052
fix: copying file on docker pkg instead of hard linking (#2362)
* refactor: move copyfile to gio package

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* refactor: copying file on docker pkg instead of hard linking

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* chore: fmt

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: fixex

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: one todo

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: copy with mode

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* chore: fmt

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: errors

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-07-24 19:59:43 -03:00
Carlos Alexandro Becker
b176b1ff80
feat: inc parts of semver, change snapshot default name (#2358) 2021-07-24 10:13:05 -03:00
Guilhem Lettron
6ecddbd7e9
feat(snapcraft): manage channel upload (#2361)
By default, snap store manage "edge", "beta", "candidate" and "stable".
Default to all this channels when package is in grade stable. But only on
"edge" and "beta" for grade "devel".

Signed-off-by: Guilhem Lettron <guilhem@barpilot.io>

Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2021-07-24 00:23:59 -03:00
Carlos Alexandro Becker
7f40922ea2
chore: gofumpt
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-07-23 23:54:13 -03:00
Carlos Alexandro Becker
bf19dc1079
feat: moving some cmd logs to debug (#2359)
* feat: moving some cmd logs to debug

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* feat: moving some cmd logs to debug

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-07-23 12:09:29 +01:00
Carlos Alexandro Becker
73641c71ac
feat: file mappings in archives (#2347)
* refactor: archive files

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* feat: better archives

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* feat: better archives

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: test todos

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: go mod tidy et al

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: improve docs and remove typoe 'licence' from defaults

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: fixes

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* fix: error string

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: remove some logs

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>

* test: use utc

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-07-21 22:09:02 -03:00
msvechla
5bcfa9042d
fix new gitlab releases throwing 404 due to API change #2334 (#2335) 2021-07-06 10:42:56 +02:00
Carlos A Becker
9333f80ad4
fix: improve docker logs
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-07-04 01:52:59 +00:00
Carlos A Becker
d4a455fc5a
test: header/footer invalid templates
refs #2326

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-07-03 19:23:51 +00:00
zhouhaibing089
bffa7e5e2f
feat: template header and footer (#2326)
A continuation of #2267 - the header and footer in release configuration
can be templatized as well to support more use cases like attaching
published docker image information(without using docker pipe).
2021-07-03 13:42:54 -03:00
Carlos Alexandro Becker
91848616e3
refactor(docker): preparing for multiple backends (#2319)
* refactor(docker): preparing for multiple backends

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: remove pro test

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: merge issues

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: merge issues

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: merge issues

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-06-27 17:55:00 -03:00
Carlos A Becker
32a44ab928
fix(docker_manifest): improve logs
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-06-27 00:29:26 +00:00
Carlos A Becker
52a64c7405
fix: fury upload
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-06-26 22:16:54 +00:00
Carlos Alexandro Becker
560938152a
feat: remove some nfpm deprecated options (#2315)
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-06-26 16:52:18 -03:00
Carlos A Becker
afc7d85688
docs: improve gitlab projectid readme
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-06-26 19:46:16 +00:00
Jesse Quinn
92a4afb169
feat(gitlab): use project id (#2297)
* feat: use project id

* fix: missing slash.

* Added comment.

* Added a comment

Signed-off-by: Jesse Quinn <jesse.quinn@zpesystems.com>

* Added a comment

Signed-off-by: Jesse Quinn <me@jessequinn.info>

Co-authored-by: Jesse Quinn <jesse.quinn@zpesystems.com>
Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2021-06-26 16:44:24 -03:00
Carlos Alexandro Becker
1883ed4a73
refactor: preparing for other docker implementations (#2314)
* wip: podman

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* refactor: preparing for other docker implementations

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* refactor: preparing for other docker implementations

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: log

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: use buildx

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* test: cover

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>

* fix: lint

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-06-26 16:36:31 -03:00
Carlos A Becker
c5bcff2b00
feat: scoop formula path
closes #2310

Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-06-26 17:14:42 +00:00