While ZIP is a widely known and used archiving format, it is not very convenient in non-Windows systems where the unzip command may not even be installed by default. For systems such as Linux and macOS, the defacto standard archiving tool is tar and for compression is gzip or even bzip2. For this reason, many software archives are usually distributed in tar.gz or tar.bz2 formats.
Would go-getter consider releasing archives in tar.gz (more widely used) or tar.bz2 formats for Linux and macOS?
This is actually very easy to accomplish with goreleaser, which is the releasing tool seemingly used in this repository.
Currently, go-getter uses the following goreleaser configuration which generates the ZIP files for everything:
From the official documentation of goreleaser it can be seen that using tar.gz for non-Windows and ZIP for Windows systems is rather trivial and even documented as a common use case:
archives:
# Archive format. Valid options are `tar.gz`, `tgz`, `tar.xz`, `txz`, tar`, `gz`, `zip` and `binary`.
# If format is `binary`, no archives are created and the binaries are instead
# uploaded directly.
#
# Default: 'tar.gz'
format: tar.gz
# Can be used to change the archive formats for specific GOOSs.
# Most common use case is to archive as zip on Windows.
format_overrides:
- goos: windows
format: zip
# The rest used by go-getter
name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}"
files:
- none*
With non-Windows releases in tar.gz format, this pattern can be used for installing go-getter for example inside a container:
First of all, thanks for this very useful tool. 💯
I noticed that the release artifacts for
go-getter
are formatted as ZIP files (for example for 1.7.2):While ZIP is a widely known and used archiving format, it is not very convenient in non-Windows systems where the
unzip
command may not even be installed by default. For systems such as Linux and macOS, the defacto standard archiving tool istar
and for compression isgzip
or evenbzip2
. For this reason, many software archives are usually distributed intar.gz
ortar.bz2
formats.Would
go-getter
consider releasing archives intar.gz
(more widely used) ortar.bz2
formats for Linux and macOS?This is actually very easy to accomplish with goreleaser, which is the releasing tool seemingly used in this repository.
Currently,
go-getter
uses the following goreleaser configuration which generates the ZIP files for everything:From the official documentation of goreleaser it can be seen that using
tar.gz
for non-Windows and ZIP for Windows systems is rather trivial and even documented as a common use case:With non-Windows releases in
tar.gz
format, this pattern can be used for installinggo-getter
for example inside a container:Currently, with the ZIP format archives, it is required to install additional tools and create temporary files and boilerplate code.