GitHub Actions 워크플로우 업데이트: 빌드 프로세스 제거 및 릴리스 워크플로우 추가, package.json의 진입점 수정

This commit is contained in:
2024-12-18 03:43:47 +09:00
parent 2bd1c05af3
commit 08b5538e49
4 changed files with 63 additions and 44 deletions

62
.github/workflows/release.yml vendored Normal file
View File

@@ -0,0 +1,62 @@
name: Release
on:
release:
types: [published]
jobs:
build-and-release:
runs-on: macos-latest
strategy:
matrix:
node-version: [18.x, 20.x, 22.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
steps:
- uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/setup-node@v3
- name: Install dependencies and build nfd2nfc
run: |
cd nfd2nfc
npm install
npm run build
- name: Install dependencies and build MACOS-APP
run: |
cd MACOS-APP
npm install
npm run build
- name: Upload NFD2NFC executable
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./nfd2nfc/dist/NFD2NFC-$(uname -s).zip
asset_name: NFD2NFC-$(uname -s).zip
asset_content_type: application/zip
- name: Upload MacOS .app
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./MACOS-APP/dist/*.app.zip
asset_name: MacApp.zip
asset_content_type: application/zip
- name: Upload MacOS .dmg
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./MACOS-APP/dist/*.dmg
asset_name: MacApp.dmg
asset_content_type: application/octet-stream