diff --git a/.SRCINFO b/.SRCINFO index 5e3253f..85685b1 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,7 +1,7 @@ pkgbase = open-video-downloader-bin pkgdesc = A cross-platform GUI for youtube-dl made in Rust with Tauri and Vue + Typescript pkgver = 3.2.0 - pkgrel = 1 + pkgrel = 2 url = https://github.com/jely2002/youtube-dl-gui arch = x86_64 license = AGPL3 diff --git a/PKGBUILD b/PKGBUILD index 9f77796..27e914e 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -6,7 +6,7 @@ _srcmntr="jely2002" pkgname="${_pkgname}-bin" pkgver="3.2.0" -pkgrel="1" +pkgrel="2" pkgdesc="A cross-platform GUI for youtube-dl made in Rust with Tauri and Vue + Typescript" url="https://github.com/${_srcmntr}/${_srcname}" arch=("x86_64") diff --git a/push.sh b/push.sh index 6668635..f2b4e75 100755 --- a/push.sh +++ b/push.sh @@ -38,27 +38,26 @@ else fi # Perform variable substitution -url="${url//\$\{pkgname\}/$pkgname}" url="${url//\$\{_pkgname\}/$_pkgname}" url="${url//\$\{_srcname\}/$_srcname}" url="${url//\$\{_srcmntr\}/$_srcmntr}" url="${url//\$\{pkgver\}/$pkgver}" -_archive="${_archive//\$\{pkgname\}/$pkgname}" _archive="${_archive//\$\{_pkgname\}/$_pkgname}" _archive="${_archive//\$\{pkgver\}/$pkgver}" aur_url="${aur_url//\$\{_pkgname\}/$_pkgname}" +pkgname="${pkgname//\$\{_pkgname\}/$_pkgname}" # Download archive -wget -O ${_archive} "${url}" +wget -qO ${_archive} "${url}" # Extract icon / .desktop files if appimage if printf '%s' "${_archive,,}" | grep -qi "appimage"; then chmod +x "${_archive}" - "./${_archive}" --appimage-extract + "./${_archive}" --appimage-extract >/dev/null cp "squashfs-root/${desktop}" "${newdesktop}" cp "squashfs-root/${icon}" "${newicon}" - if [ -L "squashfs-root" ]; then - rm -rf $(readlink -f squashfs-root) squashfs-root - fi + sed -i '/^X-AppImage-/d;/^$/d' "${newdesktop}" + sed -i 's/^Exec=.*/Exec=reflex %U/' "${newdesktop}" + rm -rf $(readlink -f squashfs-root) squashfs-root fi # Calculate checksums sha256bin=$(sha256sum ${_archive} | awk '{print $1}') @@ -79,7 +78,10 @@ sha256sums=(\ "'"$sha256ico"'"\ )' PKGBUILD else - sed -i -E "s|^sha256sums=.*|sha256sums=(\"$sha256bin\")|" PKGBUILD + sed -i -E "s/^sha256sums=\(\"[^\"]+\"\)/sha256sums=(\"$sha256bin\")/" PKGBUILD +fi +if [ "${pkgver}" != "${oldver}" ] && [ -n "${FORCE_REBUILD}" ]; then + sed -i -E "s/^pkgrel=\"[^\"]+\"/pkgrel=\"1\"/" PKGBUILD fi # Update .SRCINFO makepkg --printsrcinfo > .SRCINFO @@ -94,7 +96,7 @@ fi if [ -z "${NO_GIT_PUSH}" ]; then # In case of fire, git commit, git push, leave building git add . - git commit -m "Updated ${pkgname} to ${pkgver}-${pkgrel}" + git commit -m "${commit_msg}" git remote add aur ${aur_url} git push origin main git push aur main:master