Build WSL tarball and attach to release #15
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 WSL tarball and attach to release | |
| on: | |
| release: | |
| types: [published] | |
| permissions: | |
| contents: write | |
| jobs: | |
| build-and-upload: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Install Nix | |
| uses: cachix/install-nix-action@v31 | |
| - name: Build WSL tarball | |
| run: | | |
| set -eux | |
| sudo rm -rf /homeless-shelter | |
| sudo -E env "PATH=$PATH" nix run --impure .#wsl-tarball | |
| ls -la output || true | |
| - name: Upload WSL tarball to release | |
| uses: actions/upload-release-asset@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| upload_url: ${{ github.event.release.upload_url }} | |
| asset_path: output/nixos.wsl | |
| asset_name: nix-develop.wsl | |
| asset_content_type: application/octet-stream | |
| - name: Upload PowerShell installer to release | |
| uses: actions/upload-release-asset@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| upload_url: ${{ github.event.release.upload_url }} | |
| asset_path: scripts/install.ps1 | |
| asset_name: install.ps1 | |
| asset_content_type: application/octet-stream |