mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2025-04-29 22:24:26 +02:00
ci: add nix out paths to job summary
Signed-off-by: Seth Flynn <getchoo@tuta.io>
This commit is contained in:
parent
d7eddedf41
commit
588e0d6305
50
.github/workflows/nix.yml
vendored
50
.github/workflows/nix.yml
vendored
@ -77,12 +77,54 @@ jobs:
|
||||
run: |
|
||||
nix flake check --print-build-logs --show-trace
|
||||
|
||||
- name: Build debug package
|
||||
- name: Select debug package
|
||||
if: ${{ env.DEBUG }}
|
||||
run: |
|
||||
nix build --print-build-logs .#prismlauncher-debug
|
||||
echo "installable='.#prismlauncher-debug'" >> "$GITHUB_ENV"
|
||||
|
||||
- name: Build release package
|
||||
- name: Select release package
|
||||
if: ${{ !env.DEBUG }}
|
||||
run: |
|
||||
nix build --print-build-logs .#prismlauncher
|
||||
echo "installable='.#prismlauncher'" >> "$GITHUB_ENV"
|
||||
|
||||
- name: Build package
|
||||
run: |
|
||||
nix build \
|
||||
--no-link --print-build-logs --print-out-paths \
|
||||
"$installable" >> "$RUNNER_TEMP"/out-paths
|
||||
|
||||
- name: Upload out paths
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ matrix.system }}-out-paths
|
||||
path: ${{ runner.temp }}/out-paths
|
||||
|
||||
release-gate:
|
||||
name: Release gate
|
||||
|
||||
if: ${{ always() }}
|
||||
needs: [ build ]
|
||||
|
||||
runs-on: ubuntu-22.04
|
||||
|
||||
steps:
|
||||
- name: Recover out paths
|
||||
uses: actions/download-artifact@v4
|
||||
|
||||
- name: Make job summary
|
||||
run: |
|
||||
{
|
||||
for artifact in *-out-paths/; do
|
||||
basename="$(basename "$artifact")"
|
||||
echo "# ${basename/%-out-paths/}"
|
||||
echo
|
||||
echo '```'
|
||||
cat "$artifact"/out-paths
|
||||
echo '```'
|
||||
echo
|
||||
done
|
||||
} >>"$GITHUB_STEP_SUMMARY"
|
||||
|
||||
- name: Exit with error
|
||||
if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}
|
||||
run: exit 1
|
||||
|
Loading…
x
Reference in New Issue
Block a user