feat: add local and dynamic port forward methods #123
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
name: Build | |
on: | |
push: | |
branches: [ master ] | |
tags: | |
- v* | |
pull_request: | |
branches: [ master ] | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
platform: [linux, windows, macos] | |
include: | |
- platform: linux | |
os: ubuntu-24.04 | |
target: AppImage | |
extension: AppImage | |
- platform: windows | |
os: ubuntu-24.04 | |
target: nsis | |
extension: exe | |
- platform: macos | |
os: macos-latest | |
target: dmg | |
extension: dmg | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install Node.js, NPM and Yarn | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '20' | |
- name: Install wine | |
if: ${{ matrix.platform == 'windows' }} | |
run: | | |
sudo dpkg --add-architecture i386 | |
sudo apt install --install-recommends wine | |
- name: Build | |
env: | |
PLATFORM: ${{ matrix.platform }} | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
if [ "${{ matrix.platform }}" == "macos" ]; then | |
export CSC_IDENTITY_AUTO_DISCOVERY=false | |
EXTRA_ARGS="-c.mac.identity=null" | |
fi | |
yarn install | |
yarn build | |
npx electron-builder --${{ matrix.platform }} ${{ matrix.target }} -p never $EXTRA_ARGS | |
- name: Upload artifact | |
if: "contains(github.ref, 'refs/tags/v')" | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{ matrix.platform }} | |
path: dist/*.${{ matrix.extension }} | |
publish: | |
if: "contains(github.ref, 'refs/tags/v')" | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Download windows artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: windows | |
- name: Download linux artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: linux | |
- name: Download macos artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: macos | |
- name: Create release draft | |
uses: softprops/action-gh-release@v2 | |
with: | |
draft: true | |
generate_release_notes: true | |
files: | | |
*.exe | |
*.AppImage | |
*.dmg |