42 lines
1.3 KiB
YAML
42 lines
1.3 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
tags: ['v*']
|
|
pull_request:
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
windows:
|
|
runs-on: windows-latest
|
|
permissions:
|
|
contents: write
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 22
|
|
cache: npm
|
|
- run: npm ci
|
|
- run: npm run typecheck
|
|
- run: npm test
|
|
- run: npm run dist
|
|
env:
|
|
CSC_IDENTITY_AUTO_DISCOVERY: false
|
|
# certificat de signature de code (secrets du dépôt) : sans eux, build non signé
|
|
WIN_CSC_LINK: ${{ secrets.WIN_CSC_LINK }}
|
|
WIN_CSC_KEY_PASSWORD: ${{ secrets.WIN_CSC_KEY_PASSWORD }}
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: orbe-launcher-windows
|
|
path: |
|
|
dist/*.exe
|
|
if-no-files-found: error
|
|
# tag v* : publie l'installeur et la version portable dans une release GitHub
|
|
- name: Release
|
|
if: startsWith(github.ref, 'refs/tags/v')
|
|
shell: bash
|
|
env:
|
|
GH_TOKEN: ${{ github.token }}
|
|
run: gh release create "${GITHUB_REF_NAME}" dist/*.exe --title "Orbe Launcher ${GITHUB_REF_NAME#v}" --notes "Installeur (Setup) et version portable pour Windows 10 / 11. Voir le README pour l'installation."
|