feat(source-control): add Sync Changes flow and More Actions dropdown #93
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: Release Koda-AI | |
| on: | |
| push: | |
| tags: | |
| - 'v*' # Trigger on version tags (e.g., v1.0.0) | |
| branches: | |
| - main # Also trigger on push to main (optional: for pre-releases) | |
| jobs: | |
| build: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| include: | |
| - os: ubuntu-latest | |
| platform: linux | |
| - os: macos-latest | |
| platform: mac | |
| - os: windows-latest | |
| platform: win | |
| arch: x64 | |
| - os: windows-latest | |
| platform: win | |
| arch: ia32 | |
| steps: | |
| - name: Check out git repository | |
| uses: actions/checkout@v4 | |
| - name: Install Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: 'npm' | |
| - name: Install Linux Build Dependencies | |
| if: matrix.platform == 'linux' | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y libx11-dev libxkbfile-dev libsecret-1-dev | |
| - name: Install dependencies | |
| run: npm install | |
| - name: Build Vite App | |
| if: matrix.platform == 'win' | |
| run: npm run build | |
| - name: Rebuild native modules for x64 | |
| if: matrix.platform == 'win' && matrix.arch == 'x64' | |
| run: npx electron-builder install-app-deps --arch=x64 | |
| shell: pwsh | |
| - name: Build Windows x64 | |
| if: matrix.platform == 'win' && matrix.arch == 'x64' | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: npx electron-builder --win --x64 --publish never | |
| - name: Rebuild native modules for ia32 | |
| if: matrix.platform == 'win' && matrix.arch == 'ia32' | |
| run: npx electron-builder install-app-deps --arch=ia32 | |
| shell: pwsh | |
| - name: Build Windows ia32 | |
| if: matrix.platform == 'win' && matrix.arch == 'ia32' | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: npx electron-builder --win --ia32 --publish never | |
| - name: List Windows Build Artifacts | |
| if: matrix.platform == 'win' | |
| run: | | |
| echo "Listing all generated files:" | |
| dir release-build | |
| shell: pwsh | |
| - name: Upload Windows Artifacts | |
| if: matrix.platform == 'win' | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: koda-windows-${{ matrix.arch }} | |
| path: release-build/*.exe | |
| retention-days: 7 | |
| - name: Publish Windows Builds to GitHub Release | |
| if: matrix.platform == 'win' && startsWith(github.ref, 'refs/tags/v') | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| gh release upload ${{ github.ref_name }} release-build/*.exe --clobber | |
| shell: pwsh | |
| - name: Publish install scripts to GitHub Release | |
| if: matrix.platform == 'win' && matrix.arch == 'x64' && startsWith(github.ref, 'refs/tags/v') | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| gh release upload ${{ github.ref_name }} scripts/install/install-linux.sh scripts/install/install-macos.sh --clobber | |
| shell: pwsh | |
| - name: Build and Publish (Linux/macOS) | |
| if: matrix.platform != 'win' | |
| uses: samuelmeuli/action-electron-builder@v1 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| release: ${{ startsWith(github.ref, 'refs/tags/v') }} | |
| max_attempts: 3 | |
| - name: Upload Artifacts (Linux/macOS) | |
| uses: actions/upload-artifact@v4 | |
| if: matrix.platform != 'win' | |
| with: | |
| name: koda-${{ matrix.os }}-build | |
| path: | | |
| release-build/*.dmg | |
| release-build/*.AppImage | |
| release-build/*.zip | |
| retention-days: 7 |