aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/.github/workflows
diff options
context:
space:
mode:
author简律纯 <i@jyunko.cn>2026-02-24 15:22:51 +0800
committerGitHub <noreply@github.com>2026-02-24 15:22:51 +0800
commit8f38a248e07d92fcdc207faad9353a20737c1ad7 (patch)
tree514f28ebbf996923ef370c8ef99e17dd69a6af5b /.github/workflows
parent08c10ff7bf63f701026f707801277b097c95054f (diff)
downloadsoon-8f38a248e07d92fcdc207faad9353a20737c1ad7.tar.gz
soon-8f38a248e07d92fcdc207faad9353a20737c1ad7.zip
Modify publish workflow to set pkgver from tag
Update PKGBUILD version dynamically based on tag.
Diffstat (limited to '.github/workflows')
-rw-r--r--.github/workflows/publish-aur.yml7
1 files changed, 6 insertions, 1 deletions
diff --git a/.github/workflows/publish-aur.yml b/.github/workflows/publish-aur.yml
index f9e43cd..f6e53f6 100644
--- a/.github/workflows/publish-aur.yml
+++ b/.github/workflows/publish-aur.yml
@@ -35,8 +35,13 @@ jobs:
run: |
git clone ssh://aur@aur.archlinux.org/soon.git aur-repo
cd aur-repo
- cp ../PKGBUILD .
+
+ TAG=${GITHUB_REF##*/}
+ VERSION=${TAG#v}
+ sed -i "s/^pkgver=.*/pkgver=${VERSION}/" PKGBUILD
+
makepkg --printsrcinfo > .SRCINFO
+
git add PKGBUILD .SRCINFO
if git diff --cached --quiet; then