Skip to content

Commit 79b06cb

Browse files
committed
build(cicd): remove aur as it has another maintainer
1 parent 6ea3d20 commit 79b06cb

1 file changed

Lines changed: 0 additions & 79 deletions

File tree

.github/workflows/publish.yml

Lines changed: 0 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -161,85 +161,6 @@ jobs:
161161
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
162162
run: gh release upload "${{ github.ref_name }}" vendor.tar --clobber
163163

164-
aur:
165-
name: Publish PKGBUILD to AUR
166-
needs: create-release
167-
runs-on: ubuntu-latest
168-
steps:
169-
- uses: actions/checkout@v4
170-
- name: Install makepkg (needed to regenerate .SRCINFO)
171-
run: |
172-
sudo apt-get update
173-
sudo apt-get install -y pacman-package-manager || true
174-
- name: Resolve version + checksums
175-
id: prep
176-
run: |
177-
set -e
178-
VERSION=$(grep -m1 '^version' Cargo.toml | sed 's/version = "\(.*\)"/\1/')
179-
TAG="${GITHUB_REF_NAME}"
180-
# sha256 of the GitHub source tarball backing Source0 in the PKGBUILD.
181-
URL="https://github.com/cosmic-utils/enroll/archive/refs/tags/${TAG}.tar.gz"
182-
SUM=$(curl -fsSL "$URL" | sha256sum | awk '{print $1}')
183-
{
184-
echo "version=$VERSION"
185-
echo "tag=$TAG"
186-
echo "sha256=$SUM"
187-
} >> "$GITHUB_OUTPUT"
188-
- name: Render PKGBUILD
189-
env:
190-
VERSION: ${{ steps.prep.outputs.version }}
191-
SHA256: ${{ steps.prep.outputs.sha256 }}
192-
run: |
193-
set -e
194-
mkdir -p out
195-
# Stamp pkgver + sha256sums into the committed PKGBUILD.
196-
awk -v v="$VERSION" -v s="$SHA256" '
197-
/^pkgver=/ { print "pkgver=" v; next }
198-
/^sha256sums=/ { print "sha256sums=(\x27" s "\x27)"; next }
199-
{ print }
200-
' packaging/aur/PKGBUILD > out/PKGBUILD
201-
- name: Push to AUR
202-
env:
203-
# Private key whose public half is registered on the AUR account.
204-
AUR_SSH_KEY: ${{ secrets.AUR_SSH_KEY }}
205-
VERSION: ${{ steps.prep.outputs.version }}
206-
run: |
207-
set -e
208-
mkdir -p ~/.ssh
209-
printf '%s\n' "$AUR_SSH_KEY" > ~/.ssh/aur
210-
chmod 600 ~/.ssh/aur
211-
{
212-
echo "Host aur.archlinux.org"
213-
echo " HostName aur.archlinux.org"
214-
echo " User aur"
215-
echo " IdentityFile ~/.ssh/aur"
216-
echo " StrictHostKeyChecking accept-new"
217-
} > ~/.ssh/config
218-
ssh-keyscan -t ed25519,rsa aur.archlinux.org >> ~/.ssh/known_hosts 2>/dev/null
219-
220-
git config --global user.email "102735115+jotuel@users.noreply.github.com"
221-
git config --global user.name "enroll-release-bot"
222-
223-
# PKGBUILD name in the repo matches `pkgname` in the file.
224-
git clone ssh://aur@aur.archlinux.org/cosmic-utils-enroll.git aur-repo
225-
cp out/PKGBUILD aur-repo/PKGBUILD
226-
227-
cd aur-repo
228-
# Render .SRCINFO from the rendered PKGBUILD. makepkg ships on Arch
229-
# (and via the pacman-package-manager apt port as a fallback). If
230-
# makepkg is unavailable, fall back to the namcap-free mksrcinfo.
231-
if command -v makepkg >/dev/null 2>&1; then
232-
makepkg --printsrcinfo > .SRCINFO
233-
elif command -v mksrcinfo >/dev/null 2>&1; then
234-
mksrcinfo
235-
else
236-
echo "::warning::no makepkg/mksrcinfo on runner; .SRCINFO not regenerated"
237-
fi
238-
239-
git add PKGBUILD .SRCINFO
240-
git commit -m "Update to v$VERSION" || exit 0
241-
git push
242-
243164
copr:
244165
name: Submit SRPM to Copr
245166
needs: vendor-tar

0 commit comments

Comments
 (0)