Skip to content

Commit

Permalink
Merge pull request #964 from twpayne/update-release-process
Browse files Browse the repository at this point in the history
Update release process
  • Loading branch information
twpayne committed Dec 20, 2020
2 parents 115be3e + a8de684 commit 11ed57d
Show file tree
Hide file tree
Showing 5 changed files with 63 additions and 28 deletions.
21 changes: 7 additions & 14 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,10 @@ jobs:
test-release:
runs-on: ubuntu-latest
steps:
- name: Install musl
- name: Install build dependencies
run: |
sudo apt install -y musl-tools
sudo apt-get update
sudo apt-get -yq --no-install-suggests --no-install-recommends install musl-tools snapcraft
- name: Set up Go
uses: actions/setup-go@v2
with:
Expand All @@ -54,10 +55,6 @@ jobs:
${{ runner.os }}-go-
- name: Checkout
uses: actions/checkout@v2
- name: Install snapcraft
run: |
sudo apt-get update
sudo apt-get -yq --no-install-suggests --no-install-recommends install snapcraft
- name: Build release
uses: goreleaser/goreleaser-action@v2
with:
Expand Down Expand Up @@ -109,9 +106,10 @@ jobs:
- test-release
runs-on: ubuntu-latest
steps:
- name: Install musl
- name: Install build dependencies
run: |
sudo apt install -y musl-tools
sudo apt-get update
sudo apt-get -yq --no-install-suggests --no-install-recommends install musl-tools snapcraft
- name: Set up Go
uses: actions/setup-go@v2
with:
Expand All @@ -125,16 +123,11 @@ jobs:
${{ runner.os }}-go-
- name: Checkout
uses: actions/checkout@v2
- name: Install snapcraft
run: |
sudo apt-get update
sudo apt-get -yq --no-install-suggests --no-install-recommends install snapcraft
- name: Snapcraft Login
if: success() && startsWith(github.ref, 'refs/tags/v')
env:
SNAPCRAFT_LOGIN: ${{ secrets.SNAPCRAFT_LOGIN }}
run: |
snapcraft login --with <(echo "$SNAPCRAFT_LOGIN")
snapcraft login --with <(echo "$SNAPCRAFT_LOGIN" | base64 -d)
- name: Release
uses: goreleaser/goreleaser-action@v2
with:
Expand Down
18 changes: 18 additions & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,12 @@ archives:
- goos: windows
format: zip

changelog:
sort: asc
filters:
exclude:
- "Merge pull request"

checksum:

nfpms:
Expand Down Expand Up @@ -108,6 +114,18 @@ nfpms:
arm64: aarch64
files:
"completions/chezmoi.zsh": "/usr/share/zsh/functions/_chezmoi"
- id: apks
builds:
- chezmoi-cgo-musl
- chezmoi-nocgo
vendor: "Tom Payne <[email protected]>"
homepage: "https://chezmoi.io/"
maintainer: "Tom Payne <[email protected]>"
description: "Manage your dotfiles across multiple diverse machines, securely."
license: MIT
formats:
- apk
bindir: /usr/bin

release:

Expand Down
26 changes: 19 additions & 7 deletions cmd/docs.gen.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 12 additions & 1 deletion docs/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,11 +107,22 @@ To build a test release, without publishing, (Linux only) run:

make test-release

To create a new release, create and push a tag, e.g.:
Publish a new release by creating and pushing a tag, e.g.:

git tag v1.2.3
git push --tags

This triggers a [GitHub Action](https://github.com/twpayne/chezmoi/actions) that
builds and publishes archives, packages, and snaps, and creates a new [GitHub
Release](https://github.com/twpayne/chezmoi/releases).

Publishing [Snaps](https://snapcraft.io/) requires a `SNAPCRAFT_LOGIN`
[repository
secret](https://github.com/twpayne/chezmoi/settings/secrets/actions). Snapcraft
logins periodically expire. Create a new snapcraft login by running:

snapcraft export-login --snaps=chezmoi --channels=stable --acls=package_upload -

[brew](https://brew.sh/) formula must be updated manually with the command:

brew bump-formula-pr --tag=v1.2.3 chezmoi
Expand Down
13 changes: 7 additions & 6 deletions docs/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,13 @@ Install chezmoi with a single command.
Download a package for your operating system and architecture and install it
with your package manager.

| Distribution | Architectures | Package |
| ------------ | --------------------------------------------------------- | ------------------------------------------------------------------------- |
| Debian | `amd64`, `arm64`, `armel`, `i386`, `ppc64`, `ppc64le` | [`deb`](https://github.com/twpayne/chezmoi/releases/latest) |
| RedHat | `aarch64`, `armhfp`, `i686`, `ppc64`, `ppc64le`, `x86_64` | [`rpm`](https://github.com/twpayne/chezmoi/releases/latest) |
| OpenSUSE | `aarch64`, `armhfp`, `i686`, `ppc64`, `ppc64le`, `x86_64` | [`rpm`](https://github.com/twpayne/chezmoi/releases/latest) |
| Ubuntu | `amd64`, `arm64`, `armel`, `i386`, `ppc64`, `ppc64le` | [`deb`](https://github.com/twpayne/chezmoi/releases/latest) |
| Distribution | Architectures | Package |
| ------------ | --------------------------------------------------------- | ----------------------------------------------------------- |
| Alpine | `386`, `amd64`, `arm64`, `arm`, `ppc64`, `ppc64le` | [`apk`](https://github.com/twpayne/chezmoi/releases/latest) |
| Debian | `amd64`, `arm64`, `armel`, `i386`, `ppc64`, `ppc64le` | [`deb`](https://github.com/twpayne/chezmoi/releases/latest) |
| RedHat | `aarch64`, `armhfp`, `i686`, `ppc64`, `ppc64le`, `x86_64` | [`rpm`](https://github.com/twpayne/chezmoi/releases/latest) |
| OpenSUSE | `aarch64`, `armhfp`, `i686`, `ppc64`, `ppc64le`, `x86_64` | [`rpm`](https://github.com/twpayne/chezmoi/releases/latest) |
| Ubuntu | `amd64`, `arm64`, `armel`, `i386`, `ppc64`, `ppc64le` | [`deb`](https://github.com/twpayne/chezmoi/releases/latest) |

## Pre-built binaries

Expand Down

0 comments on commit 11ed57d

Please sign in to comment.