forked from spicetify/cli
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
172 additions
and
278 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: Release (Linux) | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
build: | ||
permissions: | ||
id-token: write | ||
contents: write | ||
attestations: write | ||
name: Release (Linux) | ||
strategy: | ||
matrix: | ||
arch: ["amd64", "arm64"] | ||
runs-on: ubuntu-latest | ||
if: startsWith(github.ref, 'refs/tags/v3') | ||
steps: | ||
- name: Set Tag in env | ||
run: echo "tag=${GITHUB_REF#refs/*/v}" >> "$GITHUB_ENV" | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Setup Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version-file: "go.mod" | ||
- name: Build | ||
shell: bash | ||
run: | | ||
mkdir dist | ||
go build -o dist/spicetify-${{ env.tag }}-linux-${{ matrix.arch }} -ldflags "-X main.version=${{ env.tag }}" | ||
env: | ||
GOARCH: ${{ matrix.arch }} | ||
- name: Upload artifact to release | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
files: "dist/*" | ||
env: | ||
GITHUB_TOKEN: ${{ inputs.GH_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
name: Release (macOS) | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
build: | ||
permissions: | ||
id-token: write | ||
contents: write | ||
attestations: write | ||
name: Release (macOS) | ||
strategy: | ||
matrix: | ||
arch: ["amd64", "arm64"] | ||
runs-on: macos-latest | ||
if: startsWith(github.ref, 'refs/tags/v3') | ||
steps: | ||
- name: Set Tag in env | ||
run: echo "tag=${GITHUB_REF#refs/*/v}" >> "$GITHUB_ENV" | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Setup Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version-file: "go.mod" | ||
- name: Build | ||
shell: bash | ||
run: | | ||
mkdir dist | ||
go build -o dist/spicetify-${{ matrix.arch }} -ldflags "-X main.version=${{ env.tag }}" | ||
env: | ||
GOARCH: ${{ matrix.arch }} | ||
- name: Upload macOS artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: spicetify-${{ matrix.arch }} | ||
path: dist/spicetify-${{ matrix.arch }} | ||
|
||
combine-release: | ||
name: Combine macOS release | ||
needs: [build] | ||
runs-on: macos-latest | ||
steps: | ||
- name: Set Tag in env | ||
run: echo "tag=${GITHUB_REF#refs/*/v}" >> "$GITHUB_ENV" | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- shell: bash | ||
run: mkdir dist | ||
- name: Download macOS artifacts | ||
uses: actions/download-artifact@v4 | ||
with: | ||
path: artifacts/ | ||
merge-multiple: true | ||
- name: Combine releases | ||
shell: bash | ||
run: | | ||
set -e | ||
brew install create-dmg | ||
cd build/macos | ||
chmod +x build.sh | ||
./build.sh ${{ env.tag }} | ||
mv spicetify.dmg ../../dist/spicetify-${{ env.tag }}.dmg | ||
- name: Upload artifact to release | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
files: "dist/*" | ||
env: | ||
GITHUB_TOKEN: ${{ inputs.GH_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name: Release (Windows) | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
build: | ||
permissions: | ||
id-token: write | ||
contents: write | ||
attestations: write | ||
name: Release (Windows) | ||
strategy: | ||
matrix: | ||
arch: ["amd64", "arm64", "386"] | ||
runs-on: windows-latest | ||
if: startsWith(github.ref, 'refs/tags/v3') | ||
steps: | ||
- name: Set Tag in env | ||
shell: pwsh | ||
run: | | ||
$version = $env:GITHUB_REF -replace 'refs/.*/v', '' | ||
echo "tag=$version" >> $env:GITHUB_ENV | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Setup Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version-file: "go.mod" | ||
- name: Setup Wix | ||
shell: pwsh | ||
run: | | ||
$ErrorActionPreference = 'Stop' | ||
dotnet tool install -g wix | ||
wix extension add -g WixToolset.Util.wixext | ||
wix extension add -g WixToolset.UI.wixext | ||
- name: Build | ||
shell: pwsh | ||
run: | | ||
$ErrorActionPreference = 'Stop' | ||
mkdir dist | ||
cd build\windows | ||
.\build.ps1 -version ${{ env.tag }} -platform ${{ matrix.arch }} | ||
mv spicetify.msi ..\..\dist\spicetify-${{ env.tag }}-${{ matrix.arch }}.msi | ||
- name: Upload artifact to release | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
files: "dist/*" | ||
env: | ||
GITHUB_TOKEN: ${{ inputs.GH_TOKEN }} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.