Skip to content

Commit 93bd597

Browse files
feat(dsm): makefile, cleanup action
feat(dsm): makefile, cleanup action
2 parents 1517b26 + 285da76 commit 93bd597

File tree

2 files changed

+25
-5
lines changed

2 files changed

+25
-5
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
2+
BINARY_NAME=dsm-launcher
3+
TARGET=x86_64-unknown-linux-musl
4+
DIST_DIR=dist
5+
ARCHIVE_NAME=$(BINARY_NAME)-$(TARGET).tar.gz
6+
7+
.PHONY: all build release archive clean
8+
9+
all: release archive
10+
11+
build:
12+
cross build --release --target $(TARGET)
13+
14+
release: build
15+
mkdir -p $(DIST_DIR)
16+
cp target/$(TARGET)/release/$(BINARY_NAME) $(DIST_DIR)/
17+
18+
archive: release
19+
cd $(DIST_DIR) && tar -czvf $(ARCHIVE_NAME) $(BINARY_NAME)
20+
21+
clean:
22+
rm -rf $(DIST_DIR)
23+
cargo clean

.github/workflows/dsm.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,11 @@ jobs:
1919
with:
2020
repository: ${{ github.repository }}
2121
latest: true
22-
fileName: dsm-launcher-x86_64-unknown-linux-gnu.tar.gz
22+
fileName: dsm-launcher-x86_64-unknown-linux-musl.tar.gz
2323
extract: true
24-
out-file-path: ${{ github.action_path }}
2524

2625
- name: Run DSM launcher
27-
run: |
28-
cd "${{ github.action_path }}"
29-
./dsm-launcher
26+
run: ./dsm-launcher
3027
env:
3128
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
3229
GITHUB_REPO_OWNER: ${{ github.repository_owner }}

0 commit comments

Comments
 (0)