Skip to content
This repository has been archived by the owner on Aug 7, 2024. It is now read-only.

fix(ci): build binaries for musl #9

Merged
merged 1 commit into from
Jul 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ on:
push:
branches: [main, dev]

pull_request:

workflow_dispatch:

env:
CARGO_TERM_COLOR: always

Expand All @@ -25,6 +29,7 @@ jobs:
components: clippy

- name: Setup Node.js
if: github.event_name != 'pull_request'
uses: actions/setup-node@v2
with:
node-version: "lts/*"
Expand All @@ -42,18 +47,27 @@ jobs:
uses: actions-rs/cargo@v1
with:
command: build
args: --release
args: --release --target=x86_64-unknown-linux-musl
use-cross: true

- name: cargo clippy
uses: actions-rs/cargo@v1
with:
command: clippy
args: --no-deps -- -D warnings

- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: revanced-discord-bot
path: target/x86_64-unknown-linux-musl/release/revanced-discord-bot

- name: Setup semantic-release
if: github.event_name != 'pull_request'
run: npm install -g semantic-release @semantic-release/git @semantic-release/changelog -D

- name: Release
if: github.event_name != 'pull_request'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: npx semantic-release
2 changes: 1 addition & 1 deletion .releaserc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
}],
["@semantic-release/github", {
"assets": [{
"path": "target/release/revanced-discord-bot"
"path": "target/x86_64-unknown-linux-musl/release/revanced-discord-bot"
}]
}]
]
Expand Down