From dab6f6dfa286a0bf069881cc84040154302c12eb Mon Sep 17 00:00:00 2001 From: syui Date: Mon, 12 Feb 2024 10:29:53 +0900 Subject: [PATCH] fid --- .github/workflows/release.yml | 59 ++++++++++++++++++----------------- 1 file changed, 31 insertions(+), 28 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index dc21a53..0206aa9 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,38 +1,41 @@ name: release on: + workflow_dispatch: push: branches: - main schedule: - cron: '0 0 * * *' +permissions: + contents: write + jobs: - build: - runs-on: ubuntu-latest - container: - image: archlinux:base - options: --privileged - - - name: install - run: pacman -Syyu --noconfirm archiso docker - - - name: checkout - uses: actions/checkout@v4 - - - name: build - env: - DOCKER_USER: ${{ secrets.DOCKER_USER }} - DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} - run: | - ./build.zsh gh - systemctl start docker - docker login -u=$DOCKER_USER -p=$DOCKER_PASSWORD - tar -C ./root.x86_64 -c . | docker import - syui/aios - docker push syui/aios - - - name: bootstrap - uses: actions/upload-artifact@v4 - with: - name: aios-bootstrap - path: ./*.tar.gz + release: + name: Release + runs-on: ubuntu-latest + container: + image: archlinux:latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Initialize + env: + DOCKER_USER: ${{ secrets.DOCKER_USER }} + DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} + run: | + pacman -Syuu --noconfirm base-devel archiso docker + ./build.zsh gh + mv *.tar.gz ./aios-bootstrap.tar.gz + systemctl start docker + docker login -u=$DOCKER_USER -p=$DOCKER_PASSWORD + tar -C ./root.x86_64 -c . | docker import - syui/aios + docker push syui/aios + - name: Create new release + uses: softprops/action-gh-release@v1 + with: + name: Release latest + tag_name: latest + files: + aios-bootstrap.tar.gz