try an even older rust ver #51
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: Build and Release | |
| permissions: | |
| contents: write | |
| on: | |
| workflow_dispatch: | |
| push: | |
| tags: | |
| - "v*" | |
| jobs: | |
| build-linux: | |
| runs-on: "ubuntu-latest" | |
| container: "quay.io/pypa/manylinux_2_28_x86_64" # needed for old glibc support | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Set up Rust | |
| uses: dtolnay/rust-toolchain@v1 | |
| with: | |
| toolchain: nightly-2025-03-01 # stdcall causing compile errors on latest nightly https://github.com/Hpmason/retour-rs/issues/69 | |
| - name: Cache Cargo Registry | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.cargo/registry | |
| key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-cargo-registry- | |
| - name: Cache Cargo Build | |
| uses: actions/cache@v4 | |
| with: | |
| path: target | |
| key: ${{ runner.os }}-cargo-build-${{ hashFiles('**/Cargo.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-cargo-build- | |
| - name: Build | |
| run: cargo prepare-release | |
| - name: Package Linux artifacts | |
| run: | | |
| mkdir -p artifacts/linux | |
| cp target/release/vencord-stable artifacts/linux/ | |
| cp target/release/vencord-ptb artifacts/linux/ | |
| cp target/release/vencord-canary artifacts/linux/ | |
| cp target/release/libvencord_launcher.so artifacts/linux/ | |
| cp installers/linux-sh/install.sh artifacts/linux/ | |
| mkdir -p artifacts/linux/icons | |
| cp installers/assets/icon-*.png artifacts/linux/icons/ | |
| - name: Bundle Linux artifacts | |
| run: | | |
| cd artifacts/linux | |
| tar -czf VencordStable-${{ github.ref_name }}.tar.gz vencord-stable libvencord_launcher.so icons | |
| tar -czf VencordPTB-${{ github.ref_name }}.tar.gz vencord-ptb libvencord_launcher.so icons | |
| tar -czf VencordCanary-${{ github.ref_name }}.tar.gz vencord-canary libvencord_launcher.so icons | |
| rm -r vencord-stable vencord-ptb vencord-canary libvencord_launcher.so icons | |
| - name: Upload artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: ${{ runner.os }}-artifacts | |
| path: artifacts/ | |
| build-windows: | |
| strategy: | |
| matrix: | |
| arch: [x64, arm64] | |
| include: | |
| - arch: x64 | |
| runner_type: "windows-latest" | |
| rust_target: x86_64-pc-windows-msvc | |
| - arch: arm64 | |
| runner_type: "windows-11-arm" | |
| rust_target: aarch64-pc-windows-msvc | |
| runs-on: "${{ matrix.runner_type }}" | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Set up Rust | |
| uses: dtolnay/rust-toolchain@v1 | |
| with: | |
| toolchain: nightly | |
| target: ${{ matrix.rust_target }} | |
| - name: Cache Cargo Registry | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.cargo/registry | |
| key: ${{ runner.os }}-${{ matrix.arch }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-${{ matrix.arch }}-cargo-registry- | |
| - name: Cache Cargo Build | |
| uses: actions/cache@v4 | |
| with: | |
| path: target | |
| key: ${{ runner.os }}-${{ matrix.arch }}-cargo-build-${{ hashFiles('**/Cargo.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-${{ matrix.arch }}-cargo-build- | |
| - name: Install NSIS | |
| run: choco install nsis --version 3.10 -y | |
| - name: Build | |
| run: cargo prepare-release | |
| - name: Package Windows artifacts | |
| run: | | |
| mkdir -p artifacts/windows | |
| cp "target/release/Vencord Installer.exe" "artifacts/windows/VencordInstaller-${{ matrix.arch }}.exe" | |
| - name: Upload artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: ${{ runner.os }}-${{ matrix.arch }}-artifacts | |
| path: artifacts/ | |
| release: | |
| needs: [build-linux, build-windows] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Download artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| path: artifacts | |
| - name: Debugging | |
| run: ls -R | |
| - name: Create Release | |
| id: create_release | |
| uses: softprops/action-gh-release@v2 | |
| if: startsWith(github.ref, 'refs/tags/v') | |
| with: | |
| tag_name: ${{ github.ref_name }} | |
| name: ${{ github.ref_name }} | |
| draft: false | |
| prerelease: false | |
| preserve_order: true | |
| files: | | |
| artifacts/**/windows/* | |
| artifacts/**/linux/* |