1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-01-06 03:13:48 +02:00
Commit Graph

1144 Commits

Author SHA1 Message Date
Ochi Daiki
3734c2d9be
fix: check that the variable resp is not nil (#3670)
# If applied, this commit will

Linked issues will be resolved.

# Why is this change being made?

Because the program will no longer have to refer to nil.

# Provide links to any relevant tickets, URLs or other resources
- https://github.com/goreleaser/goreleaser/issues/3669
2022-12-29 09:29:15 -03:00
Carlos Alexandro Becker
47ce9a9b33
fix: only fail announcing phase in the end (#3666)
This prevents one announce failure to skip all other announcers.

The release will still report a failure in the end, but will not fail in
the first failure.

Also improved errors messages a little bit.

closes #3663

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-28 12:24:21 -03:00
Carlos Alexandro Becker
1d2842c419
fix: log which token will be used (#3665)
this just helps debugging issues like #3661

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-28 10:27:17 -03:00
Carlos A Becker
33528d701a
fix: remove warning 2022-12-27 19:31:40 -03:00
Carlos Alexandro Becker
a209757ad2
feat: better archives relative paths (#3656)
with this patch, a config like:

```yaml
archives:
  - format: tar.gz
    # this name template makes the OS and Arch compatible with the results of uname.
    name_template: >-
      {{ .ProjectName }}_
      {{- title .Os }}_
      {{- if eq .Arch "amd64" }}x86_64
      {{- else if eq .Arch "386" }}i386
      {{- else }}{{ .Arch }}{{ end }}
      {{- if .Arm }}v{{ .Arm }}{{ end }}
    rlcp: true
    files:
      - src: "build/**/*"
        dst: .

nfpms:
  - package_name: foo
    contents:
      - src: "build/**/*"
        dst: usr/share/foo
    formats:
      - apk

```

will eval this:

<img width="1384" alt="CleanShot 2022-12-21 at 22 21 00@2x"
src="https://user-images.githubusercontent.com/245435/209034244-7c31b5f7-cfcd-4825-bb2f-7dd463c5286a.png">

as much as I would like to make this the default, it would be a breaking
change, so we really can't do it.

If `dst` is empty, it'll have the same behavior as before (no rlcp), and
if `strip_parent` is set, it will also still have the same behavior.
Finally, if the format is binary, `rlcp` is ignored too (as it doesn't
make sense).

So, this only changes if:
- your format is not binary; and
- you have files with `src` and `dst` set

Then, goreleaser will warn you to set `rlcp: true`.

## todo

- [x] docs
- [x] more tests probably
- [x] any ideas for a better name for the new config option?

fixes #3655

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-27 17:42:55 -03:00
Carlos Alexandro Becker
46fdb5552a
fix: multiple files with same name warning (#3660)
the warning was too trigger happy, this should fix it.

thanks @ioga for reporting it.

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-23 11:17:11 -03:00
Carlos A Becker
21648d187c
fix: init with extra quote
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-21 23:43:30 -03:00
Carlos A Becker
494ba29267
fix: lint issue
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-21 01:07:07 -03:00
Carlos A Becker
d4b570a002
fix: clarify scoop no windows archive errors
closes #3648

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-18 16:49:55 -03:00
dependabot[bot]
691234d402
feat(deps): bump github.com/atc0005/go-teams-notify/v2 from 2.6.1 to 2.7.0 (#3638)
Bumps
[github.com/atc0005/go-teams-notify/v2](https://github.com/atc0005/go-teams-notify)
from 2.6.1 to 2.7.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/atc0005/go-teams-notify/releases">github.com/atc0005/go-teams-notify/v2's
releases</a>.</em></p>
<blockquote>
<h2>v2.7.0</h2>
<h2>Added</h2>
<ul>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/134">GH-134</a>)
Allow setting user agent, fallback to project-specific default
value</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/135">GH-135</a>)
Allow overriding default <code>http.Client</code></li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/157">GH-157</a>)
Add <code>Adaptive Card</code> message format support
<ul>
<li>see also discussion from <a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/127">GH-127</a>,
including feedback from
<a href="https://github.com/ghokun"><code>@​ghokun</code></a></li>
</ul>
</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/169">GH-169</a>)
Added YAML en(de)coding support to <code>MessageCard</code>
<ul>
<li>credit: <a
href="https://github.com/pcanilho"><code>@​pcanilho</code></a></li>
</ul>
</li>
</ul>
<h2>Changed</h2>
<ul>
<li>Dependencies
<ul>
<li><code>github.com/stretchr/testify</code>
<ul>
<li><code>v1.7.0</code> to <code>v1.8.1</code></li>
</ul>
</li>
</ul>
</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/154">GH-154</a>)
Deprecate API interface, expose underlying &quot;Teams&quot; client</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/183">GH-183</a>)
Update Makefile and GitHub Actions Workflows</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/190">GH-190</a>)
Refactor GitHub Actions workflows to import logic</li>
</ul>
<h2>Fixed</h2>
<ul>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/166">GH-166</a>)
Update <code>lintinstall</code> Makefile recipe</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/184">GH-184</a>)
Apply Go 1.19 specific doc comments linting fixes</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/176">GH-176</a>)
<code>./send_test.go:238:8: second argument to errors.As should not be
*error</code></li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/179">GH-179</a>)
Wrong json key name for URL (uses uri instead)
<ul>
<li>credit: <a
href="https://github.com/janfonas"><code>@​janfonas</code></a></li>
</ul>
</li>
</ul>
<h2>References</h2>
<ul>
<li>See the <a
href="https://github.com/atc0005/go-teams-notify/milestone/11?closed=1"><code>v2.7.0</code>
milestone</a> for the issues associated with this release.</li>
<li>See our <a
href="https://github.com/atc0005/go-teams-notify/blob/master/CHANGELOG.md">CHANGELOG</a>
for more information.</li>
</ul>
<h2>v2.7.0-rc.2</h2>
<h2>WARNING</h2>
<p>This is a release candidate (RC) release. Unless issues are
discovered &amp; reported, this will become the next v2.7.0 stable
release.</p>
<p>Please test and provide feedback so that any blocking issues can be
resolved before the v2.7.0 release.</p>
<p>Thanks in advance!</p>
<h2>Changes for the <code>v2.7.0-rc.2</code> release</h2>
<ul>
<li>dependency updates</li>
<li>CI tweaks/enhancements</li>
</ul>
<h2>Changes for the <code>v2.7.0-rc.1</code> release</h2>
<ul>
<li>Go 1.19 specific linting fixes</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/atc0005/go-teams-notify/blob/master/CHANGELOG.md">github.com/atc0005/go-teams-notify/v2's
changelog</a>.</em></p>
<blockquote>
<h2>[v2.7.0] - 2022-12-12</h2>
<h3>Added</h3>
<ul>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/134">GH-134</a>)
Allow setting user agent, fallback to project-specific default
value</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/135">GH-135</a>)
Allow overriding default <code>http.Client</code></li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/157">GH-157</a>)
Add <code>Adaptive Card</code> message format support
<ul>
<li>see also discussion from <a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/127">GH-127</a>,
including feedback from
<a href="https://github.com/ghokun"><code>@​ghokun</code></a></li>
</ul>
</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/169">GH-169</a>)
Added YAML en(de)coding support to <code>MessageCard</code>
<ul>
<li>credit: <a
href="https://github.com/pcanilho"><code>@​pcanilho</code></a></li>
</ul>
</li>
</ul>
<h3>Changed</h3>
<ul>
<li>Dependencies
<ul>
<li><code>github.com/stretchr/testify</code>
<ul>
<li><code>v1.7.0</code> to <code>v1.8.1</code></li>
</ul>
</li>
</ul>
</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/154">GH-154</a>)
Deprecate API interface, expose underlying &quot;Teams&quot; client</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/183">GH-183</a>)
Update Makefile and GitHub Actions Workflows</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/190">GH-190</a>)
Refactor GitHub Actions workflows to import logic</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/166">GH-166</a>)
Update <code>lintinstall</code> Makefile recipe</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/184">GH-184</a>)
Apply Go 1.19 specific doc comments linting fixes</li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/176">GH-176</a>)
<code>./send_test.go:238:8: second argument to errors.As should not be
*error</code></li>
<li>(<a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/179">GH-179</a>)
Wrong json key name for URL (uses uri instead)
<ul>
<li>credit: <a
href="https://github.com/janfonas"><code>@​janfonas</code></a></li>
</ul>
</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="c205f3b9c9"><code>c205f3b</code></a>
Merge pull request <a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/195">#195</a>
from atc0005/update-changelog-for-v2.7.0-release</li>
<li><a
href="8ea4c384a6"><code>8ea4c38</code></a>
Update CHANGELOG for v2.7.0 release</li>
<li><a
href="76cdfd663d"><code>76cdfd6</code></a>
Merge pull request <a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/191">#191</a>
from atc0005/dependabot/go_modules/master/github.com/...</li>
<li><a
href="0ae634df2e"><code>0ae634d</code></a>
go.mod: bump github.com/stretchr/testify from 1.8.0 to 1.8.1</li>
<li><a
href="dece5c5e6f"><code>dece5c5</code></a>
Merge pull request <a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/190">#190</a>
from atc0005/ghaw-refactor</li>
<li><a
href="00f3f9dc82"><code>00f3f9d</code></a>
Refactor GitHub Actions workflows to import logic</li>
<li><a
href="8524906f8a"><code>8524906</code></a>
Merge pull request <a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/189">#189</a>
from atc0005/dependabot/github_actions/master/github/...</li>
<li><a
href="10f4c0e5f9"><code>10f4c0e</code></a>
ghaw: bump github/codeql-action from 2.1.24 to 2.1.25</li>
<li><a
href="bf0a4f6096"><code>bf0a4f6</code></a>
Merge pull request <a
href="https://github-redirect.dependabot.com/atc0005/go-teams-notify/issues/188">#188</a>
from atc0005/dependabot/github_actions/master/github/...</li>
<li><a
href="81f64b7826"><code>81f64b7</code></a>
ghaw: bump github/codeql-action from 2.1.23 to 2.1.24</li>
<li>Additional commits viewable in <a
href="https://github.com/atc0005/go-teams-notify/compare/v2.6.1...v2.7.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/atc0005/go-teams-notify/v2&package-manager=go_modules&previous-version=2.6.1&new-version=2.7.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-15 14:19:31 -03:00
Carlos Alexandro Becker
0767ded0cd
refactor: improving minio and docker tests (#3642)
using ory/dockertest to simplify integration tests

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-15 10:25:52 -03:00
Carlos Alexandro Becker
2e5a8e5a54
feat: allow to template archives.files.info (#3630)
this allows to template the owner, group and mtime in file infos inside
archives.

should help towards reproducible builds!

goes well with #3618

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-14 12:16:43 -03:00
Carlos Alexandro Becker
937067697b
feat: set file info for binaries inside archives (#3618)
closes #3582

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-14 12:16:03 -03:00
Carlos Alexandro Becker
f5696d01ee
feat: custom tag.sort (#3611)
closes #3609

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-12-02 21:50:04 -03:00
Carlos A Becker
a3d3ab2058
fix: improve docker warning 2022-11-30 22:47:53 -03:00
Carlos A Becker
7242733140
test: fix nfpm tests
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-29 21:59:38 -03:00
Carlos A Becker
54341682e0
docs: improve modeline docs
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-29 21:44:56 -03:00
Carlos Alexandro Becker
50bd78439c
fix: log request-id on upload error and release create/update (#3608)
this should help when reporting issues to github, especially the magical
"failed successfully" error

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-29 21:38:39 -03:00
Carlos Alexandro Becker
24d86475b4
fix: warn if list has multiple files with same name (#3607)
`List()` "materializes" the filters, so its used everywhere... if we
have multiple files with the same name there, its likely some filter
wasn't enough, or that the user configuration is faulty. Either way, we
should warn about it to help prevent release issues (like duplicated
assets on github).

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-29 21:37:23 -03:00
Carlos A Becker
6ff89366ca
fix: improve nfpm error
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-29 08:13:53 -03:00
Carlos A Becker
7ab711d682
test: fixed some tests
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-28 22:42:29 -03:00
Carlos Alexandro Becker
c2adc1727f
fix: missing digests on manifests (#3602)
it was missing the digest parsing for the manifest, and there were no
tests covering it.

now the tests are there, and so is the fix.

refs #3599
2022-11-28 21:30:16 -03:00
Carlos A Becker
f05f3b5b7f
fix: merge issues 2022-11-28 14:28:38 -03:00
Carlos Alexandro Becker
1b8395d6b6
feat(build): allow to template env (#3592)
GoReleaser evolved a lot since the last time I tried to implement this
>1 year ago.
Now its 100% possible, and way simpler to do it!

closes #3580
refs #2583

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-25 15:26:29 -03:00
Carlos Alexandro Becker
e54656438b
feat: deprecate replacements (#3589)
The replacements thing was always a bit weird, especially on archives.

We can solve that with templates, so, removing I'm deprecating it.

Also did the same on other places that had it the same feature.

Closes #3588

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-25 15:26:14 -03:00
Carlos Alexandro Becker
541e3dfed9
feat(brew): allow to template brew.install (#3593) 2022-11-25 09:32:43 -03:00
Carlos Alexandro Becker
a1305d3912
fix: validate env templates (#3591)
ignore invalid environment variables (e.g. no key, no value, or no equal
sign)

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-24 17:12:54 -03:00
John Olheiser
b66568529d
feat: add windows to default builds (#3581)
Resolves #3579

Signed-off-by: jolheiser <john.olheiser@gmail.com>
2022-11-24 15:48:37 -03:00
Carlos Alexandro Becker
f3f1c08caf
feat: title template function (#3590)
added new `title` template function.


extracted from #3589

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-24 15:21:42 -03:00
Carlos A Becker
78fa66ac7e
revert: unneeded release update
refs #3541
refs #3547

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-17 23:57:28 -03:00
Carlos A Becker
9a546a9782
test: internal/client/github tests
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-17 22:58:09 -03:00
Carlos Alexandro Becker
5731815e62
fix: improve github release code (#3547)
It makes no sense, but I saw it happens some times... the release will
be created as a draft, even though there's nothing telling it to do so.

Editing the release later might do the trick, hopefully.

closes #3541

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-17 22:57:42 -03:00
Carlos Alexandro Becker
ab08d0b706
fix: move mastodon server to yaml (#3568)
refs #3567

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-17 20:54:57 -03:00
John Olheiser
e65c53172e
feat: add mastodon (#3567)
This PR adds [mastodon](https://joinmastodon.org/) as an announcement
pipeline. 🥳


![mastodon-announce](https://user-images.githubusercontent.com/42128690/202544345-d90d8f10-0818-4bc2-bc35-3dbcba4254b0.png)


Resolves #3566

Signed-off-by: jolheiser <john.olheiser@gmail.com>
2022-11-17 20:40:00 -03:00
Carlos A Becker
8ef1d4339b
test: fix docker test
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-17 20:39:21 -03:00
Carlos A Becker
1a9209eb1f
fix: log missing image name
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-15 08:59:18 -03:00
Carlos A Becker
096c6ba6b2
fix: variable name 2022-11-15 08:31:21 -03:00
Carlos A Becker
33ea55b8e6
refactor: use the variable from artifact
refs #3496

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-15 08:29:01 -03:00
Carlos Alexandro Becker
4863781b48
feat: use digest on manifests (#3555)
this use the digests on the manifest creation.
Another PR will add it to signing too.

refs #3496
refs #3540

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-15 08:21:28 -03:00
Carlos Alexandro Becker
b55b9976c7
feat: use digest to sign docker images/manifests (#3556)
this drives it home by using the actual images/manifest digests to sign
with cosign by default.

the default signing command is changing in this PR, but since `digest`
should be always there (if not, the pipeline will fail way earlier), it
should be fine.

refs https://github.com/goreleaser/goreleaser/issues/3496
refs https://github.com/goreleaser/goreleaser/pull/3540

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-15 08:21:18 -03:00
Carlos Alexandro Becker
5ca4a7d2ff
fix: log when no artifacts are found for docker (#3554)
refs #3545

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-14 14:49:49 -03:00
gal-legit
76dc0b559e
feat: output checksums to artifacts info (#3548)
Following #3540, output artifacts' checksums to the artifact info.
This addition makes it easier to consume the checksums, especially when
running from e.g. GitHub Actions.

New tests:
1. Add a check for the checksum in the extra field. 
2. Add a test for every checksum algorithm (to see that it doesn't break
for any algo's output).
3. Add a case of a binary and an extra file (to see that the logic
doesn't break when there's a mix).

p.s.
While working on that, I noticed that the convention for extra fields is
actually to use UpperCamelCase rather than lower.
I was mistaken because I looked at the subfields of the "DockerConfig"
extra field.
I think it's a good idea to fix it quickly, before the next release
rolls and it becomes a compatibility issue.
I took the liberty to fix it here as an extra commit. Please let me know
if you want it to be in a separate PR.

---
Tests:
```
go test
  • refreshing checksums                             file=binary_bar_checksums.txt
  • refreshing checksums                             file=binary_bar_checksums.txt
  • refreshing checksums                             file=binary_bar_checksums.txt
PASS
ok  	github.com/goreleaser/goreleaser/internal/pipe/checksums	0.184s
```

Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2022-11-14 14:49:34 -03:00
Carlos A Becker
6df90e578a
test: fix defaults test 2022-11-14 14:00:12 -03:00
Carlos Alexandro Becker
bb00edac2a
fix: set dockers.goarm to 6 by default (#3552)
fixes #3545

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-14 13:59:01 -03:00
Carlos A Becker
e1ab1049ed
test: fix broken test
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-12 17:57:02 -03:00
Carlos A Becker
e8c0f578b5
test: improve test stability
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-12 15:44:26 -03:00
gal-legit
5eb1e4ad0d
feat: add digest to artifacts info of published docker images (#3540)
Extract the digest (sha256) of docker images from the `docker push`
command for dockers published to the docker registry.
Outputting the digest is required to avoid a race condition when
referencing the image, where the image tag is being modified before the
reference is done.
See this [blog
post](https://github.com/goreleaser/goreleaser/issues/3496) for more
info.
This PR fixes https://github.com/goreleaser/goreleaser/issues/3496.

Note that the 'publish' pipe now must run before the 'metadata' pipe, so
that the information extracted during the 'publish' pipe would appear in
the metadata.
Previously, the published docker images metadata wasn't printed (because
of the order). It made sense because the content of the published image
was just a subset of the local one.
Now that it is printed to the metadata, it should have a different name
to avoid confusion.
As I mentioned, it wasn't printed before - so there shouldn't be any
backward-compatibility issues.

---
Local tests:
```
go test -v .
=== RUN   TestVersion
=== RUN   TestVersion/only_version
=== RUN   TestVersion/version_and_date
=== RUN   TestVersion/version,_date,_built_by
=== RUN   TestVersion/all_empty
=== RUN   TestVersion/complete
--- PASS: TestVersion (0.00s)
    --- PASS: TestVersion/only_version (0.00s)
    --- PASS: TestVersion/version_and_date (0.00s)
    --- PASS: TestVersion/version,_date,_built_by (0.00s)
    --- PASS: TestVersion/all_empty (0.00s)
    --- PASS: TestVersion/complete (0.00s)
PASS
ok      github.com/goreleaser/goreleaser        0.764s
```

Output example:
```
  {
    "name": "gallegit/hello-world:latest",
    "path": "gallegit/hello-world:latest",
    "goos": "linux",
    "goarch": "amd64",
    "internal_type": 10,
    "type": "Published Docker Image",
    "extra": {
      "digest": "sha256:c3f7dd196a046dc061236d3c6ae1e2946269e90da30b0a959240ca799750e632"
    }
  }
```

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2022-11-12 14:51:53 -03:00
Carlos Alexandro Becker
778f099a9a
fix: improve artifactory error handling (#3546)
closes #3543

Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-12 00:49:08 -03:00
Fabio Ribeiro
f2281e8ff2
feat: chocolatey support (#3509)
This PR adds support for generating the structure used to pack and push
Chocolatey Packages. And will solve the #3154

Is not ready for merge yet, but has the main structure, and ready for
comments.

Accordingly to Chocolatey, in order to build a package, it's necessary a
`.nuspec` and `chocolateyinstall.ps1` files at least, having these ones,
we could pack and distribute without adding the binary inside the final
package and that was implemented here.

To complete, will be necessary to define the package build and
distribute, however will be required to have Chocolatey installed
(Windows Only). One of alternatives that I thought was, publish the
files like Scoop and Brew in a separate repository, and there we could
use `chocolatey` through
[crazy-max/ghaction-chocolatey](https://github.com/crazy-max/ghaction-chocolatey).

Chocolatey has a lot of good examples of repositories:

https://github.com/chocolatey-community/chocolatey-packages/tree/master/automatic/curl

A final compilation of the missing parts:
- [x] How to pack and push (chocolatey)
- [x] Documentation

Sorry for the long description😄 

All feedback very welcome!

Co-authored-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2022-11-11 23:52:32 -03:00
Carlos A Becker
22a7a9a835
refactor: small improvements
Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
2022-11-11 23:42:52 -03:00