-
Notifications
You must be signed in to change notification settings - Fork 44
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
1 changed file
with
49 additions
and
0 deletions.
There are no files selected for viewing
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,49 @@ | ||
name: build | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build-and-release: | ||
runs-on: ununtu-latest | ||
|
||
steps: | ||
# Checkout | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
# Nodejs | ||
- name: Setup Nodejs | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: "18.x" | ||
|
||
- name: install yarn | ||
run: npm i yarn -g | ||
|
||
- name: install node pkg | ||
run: npm i pkg -g | ||
|
||
# - name: Setup Python 2.7 | ||
# uses: actions/setup-python@v4 | ||
# with: | ||
# architecture: x64 | ||
# python-version: "2.7" | ||
|
||
- name: install deps | ||
run: yarn | ||
|
||
- name: build project 64bit | ||
run: npx pkg -t node18-linux-arm64 -o ./build/sugar-wifi-conf-arm64 index.js | ||
|
||
- name: build project 32bit | ||
run: npx pkg -t node18-linux-armv7 -o ./build/sugar-wifi-conf-armv7 index.js | ||
|
||
# Upload artifact | ||
- name: Upload artifacts | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: sugar-wifi-conf | ||
path: | | ||
build | ||
if-no-files-found: warn |