chore(release): v1.1.1 #26
Workflow file for this run
This file contains hidden or 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
| name: Desktop App | |
| # Electron 데스크톱 앱(인스톨러) 빌드. 스캐너는 여전히 Docker로 실행되며, 이 앱은 | |
| # 더블클릭 진입점을 제공한다. electron/ 변경 PR, 수동 실행, 태그 푸시에서 빌드한다. | |
| on: | |
| workflow_dispatch: | |
| pull_request: | |
| paths: | |
| - electron/** | |
| - .github/workflows/desktop.yml | |
| push: | |
| tags: | |
| - v*.*.* | |
| permissions: | |
| contents: read | |
| jobs: | |
| test: | |
| # container.mjs 순수 로직 단위 테스트(electron 불필요, 빠름). | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: electron | |
| steps: | |
| - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 | |
| - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4 | |
| with: | |
| node-version: 20 | |
| - run: node --test test/*.test.mjs | |
| build-desktop: | |
| needs: test | |
| # 태그 푸시일 때 인스톨러를 해당 릴리스에 첨부하므로 쓰기 권한이 필요하다. | |
| permissions: | |
| contents: write | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - os: windows-latest | |
| args: --win nsis | |
| artifact: desktop-windows | |
| - os: macos-latest | |
| args: --mac dmg | |
| artifact: desktop-macos | |
| runs-on: ${{ matrix.os }} | |
| defaults: | |
| run: | |
| working-directory: electron | |
| steps: | |
| - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 | |
| - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4 | |
| with: | |
| node-version: 20 | |
| - name: Install dependencies | |
| run: npm install | |
| # 1차 미서명: mac 자동 서명 탐색을 끄고, 어떤 레지스트리에도 publish 하지 않는다. | |
| # 태그 빌드는 버전을 태그에서 주입해 인스톨러 파일명이 릴리스와 항상 일치하게 한다. | |
| - name: Build installer | |
| shell: bash | |
| run: | | |
| args=(${{ matrix.args }} --publish never) | |
| if [[ "$GITHUB_REF" == refs/tags/v* ]]; then | |
| args+=("-c.extraMetadata.version=${GITHUB_REF#refs/tags/v}") | |
| fi | |
| npx --no-install electron-builder "${args[@]}" | |
| env: | |
| # Code signing is inert until these repo secrets are configured; without | |
| # them the build stays unsigned (current behavior). When CSC_LINK is set, | |
| # electron-builder signs the Windows installer. macOS Developer ID signing | |
| # and notarization additionally require removing `identity: null` from | |
| # electron-builder.yml and the APPLE_* secrets below — see electron/README.md. | |
| CSC_LINK: ${{ secrets.CSC_LINK }} | |
| CSC_KEY_PASSWORD: ${{ secrets.CSC_KEY_PASSWORD }} | |
| APPLE_ID: ${{ secrets.APPLE_ID }} | |
| APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.APPLE_APP_SPECIFIC_PASSWORD }} | |
| APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }} | |
| # Stay unsigned on macOS unless a Developer ID cert is provided. | |
| CSC_IDENTITY_AUTO_DISCOVERY: ${{ secrets.CSC_LINK != '' }} | |
| - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 | |
| with: | |
| name: ${{ matrix.artifact }} | |
| path: | | |
| electron/dist-electron/*.exe | |
| electron/dist-electron/*.dmg | |
| if-no-files-found: warn | |
| # 태그 릴리스에는 같은 릴리스에 인스톨러를 덧붙여 일반 사용자가 바로 받게 한다. | |
| # PR과 수동 실행에서는 이 단계를 건너뛰고 위 아티팩트만 남긴다. | |
| - name: Attach installer to the release | |
| if: startsWith(github.ref, 'refs/tags/') | |
| uses: softprops/action-gh-release@3bb12739c298aeb8a4eeaf626c5b8d85266b0e65 # v2 | |
| with: | |
| tag_name: ${{ github.ref_name }} | |
| files: | | |
| electron/dist-electron/*.exe | |
| electron/dist-electron/*.dmg | |
| fail_on_unmatched_files: false |