summarylogtreecommitdiffstats
path: root/update_aur.sh
diff options
context:
space:
mode:
authorJan2019-12-07 14:21:18 +0100
committerJan2019-12-07 14:21:18 +0100
commit4560eb52e83bc310842f4e9c70686e952e58e63f (patch)
treee277f68e0b38795826574af259dbe72c113baebe /update_aur.sh
parent10c51cb97e5fc62fcd578ec9fdd41614d79c56dc (diff)
downloadaur-4560eb52e83bc310842f4e9c70686e952e58e63f.tar.gz
Improvements to PKGBUILD and preparation script
Diffstat (limited to 'update_aur.sh')
-rwxr-xr-xupdate_aur.sh35
1 files changed, 0 insertions, 35 deletions
diff --git a/update_aur.sh b/update_aur.sh
deleted file mode 100755
index f428bdfffa1a..000000000000
--- a/update_aur.sh
+++ /dev/null
@@ -1,35 +0,0 @@
-#!/usr/bin/env bash
-
-# Change to the AUR repo
-if [ -n "$1" ]; then
- cd "$1"
-fi
-
-if [ ! -d ".git" ]; then
- echo "Not a git repository!"
- exit 1
-fi
-
-BUILD_FILE="PKGBUILD"
-if [ ! -e "$BUILD_FILE" ]; then
- echo "Not an AUR repository!"
- exit 2
-fi
-source "$BUILD_FILE"
-
-# Replace with latest commit to master branch
-LATEST_COMMIT=$(git ls-remote "$url" master | cut -f 1)
-if [ "$commit" = "$LATEST_COMMIT" ]; then
- echo "Already on latest commit!"
- exit 3
-fi
-sed -i "s%commit\=.*%commit\=('$LATEST_COMMIT')%" "$BUILD_FILE"
-
-# Increment pkgrel on every "release"
-sed -i "s%pkgrel\=.*%pkgrel\=$((pkgrel+1))%" "$BUILD_FILE"
-
-# Update package checksum
-PKG_SHA=$(curl -L -s "$url/archive/$LATEST_COMMIT.tar.gz" | sha256sum | cut -d " " -f 1)
-sed -i "s%sha256sums\=.*%sha256sums\=('$PKG_SHA')%" "$BUILD_FILE"
-
-makepkg --printsrcinfo > .SRCINFO