Skip to content

Archive binaries into tar.gz and zip for windows #4203

Answered by caarlos0
ShiranAvidov asked this question in Q&A
Discussion options

You must be logged in to vote

unfortunately there's no obvious way of doing this right now...

You could add another archive item with zip as format, but it would apply to all platforms, not only windows.

Format overrides don't work because, as the name implies, they override the pre-defined format.

What you could do is something like this:

builds:
- id: windows-only
  goos: [windows]
  # etc...
- id: default 
  goos: [linux, darwin]
  # etc...

archives:
- id: windows-only
  builds: [windows-only]
  format: zip 
  # etc...
- id: default 
  builds: [default, windows-only]
  format: tar.gz
  # etc...

This would generate .tar.gz archive for all three platforms, plus zip archives for windows.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@ShiranAvidov
Comment options

Answer selected by ShiranAvidov
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants