Skip to content

Commit 2f53242

Browse files
committed
feat: Add Mac and Windows releases.
1 parent c80bc48 commit 2f53242

File tree

3 files changed

+44
-42
lines changed

3 files changed

+44
-42
lines changed

.github/workflows/lint.yaml

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -131,37 +131,3 @@ jobs:
131131

132132
- name: Check dependencies
133133
uses: bnjbvr/cargo-machete@main
134-
135-
semver:
136-
name: Semver Breaking Changes
137-
runs-on: ubuntu-latest
138-
env:
139-
SCCACHE_GHA_ENABLED: "true"
140-
RUSTC_WRAPPER: "sccache"
141-
steps:
142-
- name: Harden Runner
143-
uses: step-security/harden-runner@0080882f6c36860b6ba35c610c98ce87d4e2f26f # v2.10.2
144-
with:
145-
disable-sudo: true
146-
egress-policy: block
147-
allowed-endpoints: >
148-
api.deps.dev:443
149-
api.github.com:443
150-
api.osv.dev:443
151-
api.scorecard.dev:443
152-
fulcio.sigstore.dev:443
153-
github.com:443
154-
oss-fuzz-build-logs.storage.googleapis.com:443
155-
rekor.sigstore.dev:443
156-
tuf-repo-cdn.sigstore.dev:443
157-
www.bestpractices.dev:443
158-
objects.githubusercontent.com:443
159-
static.rust-lang.org:443
160-
index.crates.io:443
161-
static.crates.io:443
162-
163-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
164-
- uses: mozilla-actions/sccache-action@9e326ebed976843c9932b3aa0e021c6f50310eb4 # v0.0.6
165-
166-
- name: Check semver
167-
uses: obi1kenobi/cargo-semver-checks-action@v2

.github/workflows/release-packaging.yaml

Lines changed: 44 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,12 @@ on:
88
permissions:
99
contents: write
1010

11+
env:
12+
PROJECT_NAME_UNDERSCORE: test2
13+
1114
jobs:
1215
release:
13-
name: Release Packaging
14-
env:
15-
PROJECT_NAME_UNDERSCORE: test2
16+
name: Linux
1617
runs-on: ubuntu-latest
1718
steps:
1819
- name: Harden Runner
@@ -103,3 +104,43 @@ jobs:
103104
# --repo="$GITHUB_REPOSITORY" \
104105
# --title="${tag#v}" \
105106
# --generate-notes
107+
108+
macos:
109+
name: Mac
110+
runs-on: macos-latest
111+
permissions:
112+
contents: write
113+
packages: write
114+
needs: [release]
115+
steps:
116+
- uses: actions/checkout@v4
117+
- uses: actions-rs/toolchain@v1
118+
with:
119+
toolchain: stable
120+
default: true
121+
- run: cargo build --release
122+
- run: |
123+
mv target/release/${{ env.PROJECT_NAME_UNDERSCORE }} ${{ env.PROJECT_NAME_UNDERSCORE }}-macos-64bit.dmg
124+
gh release upload "${{ github.ref_name }}" ${{ env.PROJECT_NAME_UNDERSCORE }}-macos-64bit.dmg --clobber
125+
env:
126+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
127+
128+
windows:
129+
name: Windows
130+
runs-on: windows-latest
131+
permissions:
132+
contents: write
133+
packages: write
134+
needs: [release]
135+
steps:
136+
- uses: actions/checkout@v4
137+
- uses: actions-rs/toolchain@v1
138+
with:
139+
toolchain: stable
140+
default: true
141+
- run: cargo build --release
142+
- run: |
143+
mv target/release/${{ env.PROJECT_NAME_UNDERSCORE }}.exe ${{ env.PROJECT_NAME_UNDERSCORE }}-windows-64bit.exe
144+
gh release upload "${{ github.ref_name }}" ${{ env.PROJECT_NAME_UNDERSCORE }}-windows-64bit.exe --clobber
145+
env:
146+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

xtask/Cargo.toml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,5 @@ license = "Apache-2.0"
88

99
[dependencies]
1010

11-
clap = "4"
1211
anyhow = "1"
13-
duct = "0.13.7"
14-
glob = "0.3.1"
15-
fs_extra = "1"
16-
dialoguer = "^0.11.0"
1712
xtaskops = { version = "0.5.0", git = "https://github.com/yonasBSD/xtaskops" }

0 commit comments

Comments
 (0)