diff --git a/.github/workflows/draft.yml b/.github/workflows/draft.yml index 65b1be49..759437c3 100644 --- a/.github/workflows/draft.yml +++ b/.github/workflows/draft.yml @@ -187,6 +187,14 @@ jobs: with: merge-multiple: true + - name: Push snap to latest/candidate channel + env: + SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_TOKEN }} + run: | + for x in *.snap; do + snapcraft push -v --release latest/candidate $x + done + - name: Draft uses: softprops/action-gh-release@v1 with: @@ -221,6 +229,14 @@ jobs: git config user.email "41898282+github-actions[bot]@users.noreply.github.com" git tag --force nightly && git push --force origin tag nightly + - name: Push snap to latest/edge channel + env: + SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_TOKEN }} + run: | + for x in *.snap; do + snapcraft push -v --release latest/edge $x + done + - name: Nightly uses: softprops/action-gh-release@v1 with: diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 48d0051f..577815f2 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -18,3 +18,8 @@ jobs: identifier: sxyazi.yazi installers-regex: 'yazi-(x86_64|aarch64)-pc-windows-msvc\.zip$' token: ${{ secrets.WINGET_TOKEN }} + + - name: Promote snap to latest/stable + env: + SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_TOKEN }} + run: snapcraft promote yazi --from-channel latest/candidate --to-channel latest/stable --yes