New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(nfpm): Add extension to produced artifacts #3940
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good, should probably add a test too.
This should suffice:
diff --git a/internal/pipe/nfpm/nfpm_test.go b/internal/pipe/nfpm/nfpm_test.go
index 21e23af1..57809ae8 100644
--- a/internal/pipe/nfpm/nfpm_test.go
+++ b/internal/pipe/nfpm/nfpm_test.go
@@ -281,6 +281,7 @@ func TestRunPipe(t *testing.T) {
for _, pkg := range packages {
format := pkg.Format()
require.NotEmpty(t, format)
+ require.Equal(t, pkg.Format(), artifact.ExtraOr(*pkg, artifact.ExtraExt, ""))
arch := pkg.Goarch
if pkg.Goarm != "" {
arch += "v" + pkg.Goarm
Add extension to produced artifacts so that they can be filtered in later steps Fixes goreleaser#3933 Co-authored-by: Carlos A Becker <caarlos0@users.noreply.github.com>
bff8044
to
d716e0a
Compare
awesome, thank you! |
hmmm which error you got? may be worth investigating... |
Output:
Having spent more than 5s actually reading this error, it's probably because I don't have |
this seems to be the root cause... |
this should improve it: #3942 |
Awesome! Thanks! |
Add extension to produced artifacts so that they can be filtered in later steps
Fixes #3933
I tried running the tests before raising this, but I get an unrelated error with docker (I get the same error on
main
). I'm not sure about if you value a test specifically around this? If so, lmk and I'll try to add one