diff options
| author | diogo464 <[email protected]> | 2024-01-01 18:22:32 +0000 |
|---|---|---|
| committer | diogo464 <[email protected]> | 2024-01-01 18:22:32 +0000 |
| commit | a73979c1c55a5474bc338f067b14830b68e02ae7 (patch) | |
| tree | 9735718908e93739b86a8e46825eea9844a55438 | |
| parent | 48d563959b3d6cbe6edc7921cfa1fd22935177d2 (diff) | |
updated action
| -rw-r--r-- | .gitea/workflows/check.yaml (renamed from .gitea/workflows/build.yaml) | 8 | ||||
| -rw-r--r-- | .gitea/workflows/release.yaml | 28 |
2 files changed, 32 insertions, 4 deletions
diff --git a/.gitea/workflows/build.yaml b/.gitea/workflows/check.yaml index af317fd..d412980 100644 --- a/.gitea/workflows/build.yaml +++ b/.gitea/workflows/check.yaml | |||
| @@ -1,11 +1,11 @@ | |||
| 1 | name: build | 1 | name: check |
| 2 | on: [push] | 2 | on: [push] |
| 3 | jobs: | 3 | jobs: |
| 4 | build: | 4 | check: |
| 5 | runs-on: [ubuntu-latest] | 5 | runs-on: [ubuntu-latest] |
| 6 | steps: | 6 | steps: |
| 7 | - name: Checkout repository | 7 | - name: Checkout repository |
| 8 | uses: actions/checkout@v4 | 8 | uses: actions/checkout@v4 |
| 9 | - uses: dtolnay/rust-toolchain@nightly | 9 | - uses: dtolnay/rust-toolchain@nightly |
| 10 | - name: Build | 10 | - name: Cargo check |
| 11 | run: cargo build --release | 11 | run: cargo check |
diff --git a/.gitea/workflows/release.yaml b/.gitea/workflows/release.yaml new file mode 100644 index 0000000..cc3240a --- /dev/null +++ b/.gitea/workflows/release.yaml | |||
| @@ -0,0 +1,28 @@ | |||
| 1 | name: release | ||
| 2 | on: | ||
| 3 | push: | ||
| 4 | tags: | ||
| 5 | - "[0-9]+.[0-9]+.[0-9]+" | ||
| 6 | jobs: | ||
| 7 | release: | ||
| 8 | runs-on: [ubuntu-latest] | ||
| 9 | steps: | ||
| 10 | - name: Checkout repository | ||
| 11 | uses: actions/checkout@v4 | ||
| 12 | - uses: dtolnay/rust-toolchain@nightly | ||
| 13 | - name: Build | ||
| 14 | run: cargo build --release | ||
| 15 | - name: Create release | ||
| 16 | id: create-release | ||
| 17 | uses: https://git.d464.sh/actions/release@v1 | ||
| 18 | with: | ||
| 19 | token: ${{ secrets.AUTH_TOKEN }} | ||
| 20 | tag: ${{ github.ref_name }} | ||
| 21 | - name: Upload assets | ||
| 22 | id: upload-assets | ||
| 23 | uses: https://git.d464.sh/actions/upload-asset@v1 | ||
| 24 | with: | ||
| 25 | token: ${{ secrets.AUTH_TOKEN }} | ||
| 26 | release_id: ${{ steps.create-release.outputs.release_id }} | ||
| 27 | paths: | | ||
| 28 | target/release/zsnap | ||
