diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e173e84..bcb961b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,7 +1,7 @@ on: push: tags: - - "*.*" + - "v*.*.*" name: Build and Release diff --git a/PACKAGING.md b/PACKAGING.md index f25efa6..f15b245 100644 --- a/PACKAGING.md +++ b/PACKAGING.md @@ -8,12 +8,10 @@ We consider here the packaging flow of Bloom version `1.0.0` for Linux. 1. **How to bump Bloom version before a release:** 1. Bump version in `Cargo.toml` to `1.0.0` 2. Execute `cargo update` to bump `Cargo.lock` - 3. Bump Debian package version in `debian/rules` to `1.0` + 3. Bump Debian package version in `debian/rules` to `1.0.0` 2. **How to build Bloom, package it and release it on Crates, GitHub, Docker Hub and Packagecloud (multiple architectures):** - 1. Tag the latest Git commit corresponding to the release `v1.0.0` with tag `1.0` (**this is important!**), and push the tag + 1. Tag the latest Git commit corresponding to the release with tag `v1.0.0`, and push the tag 2. Wait for all release jobs to complete on the [actions](https://github.com/valeriansaliou/bloom/actions) page on GitHub - 3. Download all release archives, and sign them locally using: `./scripts/sign_binaries.sh --version=1.0` + 3. Download all release archives, and sign them locally using: `./scripts/sign_binaries.sh --version=1.0.0` 4. Publish a changelog and upload all the built archives, as well as their signatures on the [releases](https://github.com/valeriansaliou/bloom/releases) page on GitHub - -Notice: upon packaging `x86_64` becomes `amd64`. diff --git a/debian/rules b/debian/rules index f3f0aa5..054753c 100644 --- a/debian/rules +++ b/debian/rules @@ -1,9 +1,9 @@ #!/usr/bin/make -f DISTRIBUTION = $(shell lsb_release -sr) -VERSION = 1.35 +VERSION = 1.35.0 PACKAGEVERSION = $(VERSION)-0~$(DISTRIBUTION)0 -URL = https://github.com/valeriansaliou/bloom/releases/download/$(VERSION)/ +URL = https://github.com/valeriansaliou/bloom/releases/download/v$(VERSION)/ %: dh $@ --with systemd @@ -13,9 +13,11 @@ override_dh_auto_test: override_dh_auto_build: override_dh_auto_install: $(eval ENV_ARCH := $(shell dpkg --print-architecture)) - $(eval ENV_TARBALL := v$(VERSION)-$(ENV_ARCH).tar.gz) + $(eval ENV_ISA := $(shell if [ "$(ENV_ARCH)" = "amd64" ]; then echo "x86_64"; else echo "$(ENV_ARCH)"; fi)) + $(eval ENV_TARBALL := v$(VERSION)-$(ENV_ISA).tar.gz) echo "Architecture: $(ENV_ARCH)" + echo "Instruction Set: $(ENV_ISA)" echo "Target: $(URL)$(ENV_TARBALL)" wget -N --progress=dot:mega $(URL)$(ENV_TARBALL) diff --git a/scripts/release_binaries.sh b/scripts/release_binaries.sh index 87b8424..91142fd 100755 --- a/scripts/release_binaries.sh +++ b/scripts/release_binaries.sh @@ -63,7 +63,7 @@ rc=0 pushd "$BASE_DIR" > /dev/null echo "Executing release steps for Bloom v$BLOOM_VERSION..." - release_for_architecture "amd64" "x86_64-unknown-linux-musl" && \ + release_for_architecture "x86_64" "x86_64-unknown-linux-musl" && \ release_for_architecture "armhf" "armv7-unknown-linux-musleabihf" rc=$? diff --git a/scripts/sign_binaries.sh b/scripts/sign_binaries.sh index d3276cf..44e96d0 100755 --- a/scripts/sign_binaries.sh +++ b/scripts/sign_binaries.sh @@ -58,7 +58,7 @@ rc=0 pushd "$BASE_DIR" > /dev/null echo "Executing sign steps for Bloom v$BLOOM_VERSION..." - sign_for_architecture "amd64" && \ + sign_for_architecture "x86_64" && \ sign_for_architecture "armhf" rc=$?