37 lines
1.3 KiB
YAML
37 lines
1.3 KiB
YAML
name: next-build
|
|
|
|
on:
|
|
push:
|
|
branches: [next]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: alkane-verify
|
|
container:
|
|
image: gitea.bluefla.re/blueflare/alkane-ci@sha256:9d2a992bbcb91014af3c85d2e1ec8c5990701cecf83fd06c8d46f9ef13dbd948
|
|
env:
|
|
CARGO_TARGET_DIR: target
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
- name: Build release candidate
|
|
run: cargo build --release --offline --locked
|
|
- name: Select candidate version
|
|
id: version
|
|
run: python3 ci/version.py next >> "$GITHUB_OUTPUT"
|
|
- name: Package source and build output
|
|
if: steps.version.outputs.release == 'true'
|
|
run: |
|
|
mkdir -p dist
|
|
git archive --format=tar.gz --output="dist/alkane-os-${{ steps.version.outputs.version }}-source.tar.gz" HEAD
|
|
cp target/release/alkane-os dist/
|
|
- name: Create private prerelease
|
|
if: steps.version.outputs.release == 'true'
|
|
env:
|
|
GITEA_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
run: python3 ci/release.py "${{ steps.version.outputs.tag }}" true "dist/alkane-os-${{ steps.version.outputs.version }}-source.tar.gz" dist/alkane-os
|
|
- name: Clean generated candidate build
|
|
if: always()
|
|
run: python3 ci/cleanup-generated.py
|