mirror of
https://github.com/goreleaser/goreleaser.git
synced 2025-01-26 04:22:05 +02:00
36a48eabb7
closes #3383 Signed-off-by: Carlos A Becker <caarlos0@users.noreply.github.com>
1.3 KiB
1.3 KiB
Archive has different count of binaries for each platform
This error looks like this:
⨯ release failed after 5s error=invalid archive: 0:archive has different count of binaries for each platform, which may cause your users confusion.
Learn more at https://goreleaser.com/errors/multiple-binaries-archive
This will happen when you have several builds, and their target platforms are different:
builds:
- id: b1
binary: b1
goos: [linux, darwin]
- id: b2
binary: b2
goos: [darwin]
archives:
- id: a1
In this scenario, GoReleaser will complain because the archive will have a
different binary count depending on which platform its being archived, since
it'll have 2 binaries on darwin
and only 1 on linux
.
From here on, you have a couple of options:
- add another archive, and filter the builds on each of them - e.g. archive
a1
with binaries from buildb1
, and archivea2
with builds from buildb2
:archives: - id: a1 builds: b1 name_template: something-unique-for-a1 - id: a2 builds: b2 name_template: something-unique-for-a2
- if you really want to have the mixed archive, you can add
allow_different_binary_count
to your archive configuration:archives: - id: a1 allow_different_binary_count: true