This commit is contained in:
25
.github/workflows/release.yml
vendored
25
.github/workflows/release.yml
vendored
@@ -15,18 +15,16 @@ jobs:
|
||||
release:
|
||||
name: Release
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: archlinux
|
||||
options: --privileged
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install build dependencies
|
||||
run: pacman -Sy --noconfirm arch-install-scripts zsh docker
|
||||
|
||||
- name: Build aios
|
||||
run: zsh ./build.zsh
|
||||
run: |
|
||||
docker run --rm --privileged \
|
||||
-v ${{ github.workspace }}:/work -w /work \
|
||||
archlinux:latest \
|
||||
bash -c "pacman -Sy --noconfirm arch-install-scripts zsh && zsh ./build.zsh"
|
||||
|
||||
- name: Push to GitHub Container Registry
|
||||
run: |
|
||||
@@ -36,11 +34,10 @@ jobs:
|
||||
docker push ghcr.io/syui/aios
|
||||
|
||||
- name: Create new release
|
||||
uses: softprops/action-gh-release@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ env.APP_TOKEN }}
|
||||
with:
|
||||
name: latest
|
||||
tag_name: latest
|
||||
files:
|
||||
aios.tar.gz
|
||||
GH_TOKEN: ${{ env.APP_TOKEN }}
|
||||
run: |
|
||||
gh release delete latest --yes --cleanup-tag || true
|
||||
git tag -f latest
|
||||
git push -f origin latest
|
||||
gh release create latest aios.tar.gz --title "latest" --notes "build $(date +%Y.%m.%d)"
|
||||
|
||||
Reference in New Issue
Block a user