Skip to content

Commit

Permalink
Update cargo-dist to v0.22.1
Browse files Browse the repository at this point in the history
  Necessary to make use of the custom github build steps.
  • Loading branch information
KtorZ committed Oct 2, 2024
1 parent 5204831 commit b0cad2b
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 10 deletions.
3 changes: 2 additions & 1 deletion .github/musl-build-setup.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
- if: ${{ runner.os == 'Linux' }}
- name: Musl build setup
if: ${{ runner.os == 'Linux' }}
run: |
sudo apt-get install -y pkg-config libssl-dev musl musl-dev musl-tools
rustup target add x86_64-unknown-linux-musl
14 changes: 13 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/
#
# Copyright 2022-2024, axodotdev
# SPDX-License-Identifier: MIT or Apache-2.0
#
Expand Down Expand Up @@ -61,7 +63,7 @@ jobs:
# we specify bash to get pipefail; it guards against the `curl` command
# failing. otherwise `sh` won't catch that `curl` returned non-0
shell: bash
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.19.1/cargo-dist-installer.sh | sh"
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.22.1/cargo-dist-installer.sh | sh"
- name: Cache cargo-dist
uses: actions/upload-artifact@v4
with:
Expand Down Expand Up @@ -115,6 +117,11 @@ jobs:
- uses: actions/checkout@v4
with:
submodules: recursive
- name: "Musl build setup"
if: "${{ runner.os == 'Linux' }}"
run: |
sudo apt-get install -y pkg-config libssl-dev musl musl-dev musl-tools
rustup target add x86_64-unknown-linux-musl
- name: Install cargo-dist
run: ${{ matrix.install_dist }}
# Get the dist-manifest
Expand Down Expand Up @@ -299,6 +306,11 @@ jobs:
name=$(echo "$filename" | sed "s/\.rb$//")
version=$(echo "$release" | jq .app_version --raw-output)
export PATH="/home/linuxbrew/.linuxbrew/bin:$PATH"
brew update
# We avoid reformatting user-provided data such as the app description and homepage.
brew style --except-cops FormulaAudit/Homepage,FormulaAudit/Desc,FormulaAuditStrict --fix "Formula/${filename}" || true
git add "Formula/${filename}"
git commit -m "${name} ${version}"
done
Expand Down
11 changes: 3 additions & 8 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,15 @@ tag-name = "v{{version}}"
# Config for 'cargo dist'
[workspace.metadata.dist]
# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax)
cargo-dist-version = "0.19.1"
cargo-dist-version = "0.22.1"
# CI backends to support
ci = "github"
# The installers to generate for each app
installers = ["shell", "powershell", "npm", "homebrew"]
# A GitHub repo to push Homebrew formulas to
tap = "aiken-lang/homebrew-tap"
# Target platforms to build apps for (Rust target-triple syntax)
targets = [
"aarch64-apple-darwin",
"x86_64-apple-darwin",
"x86_64-unknown-linux-musl",
"x86_64-pc-windows-msvc",
]
targets = ["aarch64-apple-darwin", "x86_64-apple-darwin", "x86_64-unknown-linux-musl", "x86_64-pc-windows-msvc"]
# The archive format to use for windows builds (defaults .zip)
windows-archive = ".tar.gz"
# The archive format to use for non-windows builds (defaults .tar.xz)
Expand All @@ -31,7 +26,7 @@ unix-archive = ".tar.gz"
npm-scope = "@aiken-lang"
# Publish jobs to run in CI
publish-jobs = ["homebrew", "npm"]
# Publish jobs to run in CI
# Which actions to run on pull requests
pr-run-mode = "plan"
# Whether to install an updater program
install-updater = false
Expand Down

0 comments on commit b0cad2b

Please sign in to comment.