Include version on filename of downloaded sources

Some aur helpers cache downloaded sources to prevent unnecessary file
transfers.

Ckan.exe doesn't have a version descriptive name. So when the user
tries to upgrade the package the helper may use the previous version
present on cache (because the file name matches) but it will fail to
build because the checksum differ. (Or reinstall the previous version if
the user decides to skip the checksum).
master
rafasc 9 years ago committed by Patrik Plihal
parent 01b4b42ece
commit ecd0a85821
  1. 7
      PKGBUILD

@ -2,7 +2,7 @@
pkgname=ckan
pkgver=1.16.0
pkgrel=1
pkgrel=2
pkgdesc='All you need to find, install, and manage mods for Kerbal Space Program (ksp)'
arch=('any')
url="https://github.com/KSP-CKAN/CKAN/"
@ -10,13 +10,12 @@ license=('MIT')
depends=('curl' 'mono')
conflicts=('ckan-git')
source=("https://github.com/KSP-CKAN/CKAN/releases/download/v${pkgver}/ckan.exe")
source=("${pkgname}-v${pkgver}.exe::https://github.com/KSP-CKAN/CKAN/releases/download/v${pkgver}/ckan.exe")
sha256sums=('15c0c4a2fe876a560a53d0c706e0398bbc0e8058c355d7fa31e12c66acad4ca0')
package() {
mkdir -p "$pkgdir/usr/bin/"
cp "$srcdir/ckan.exe" "$pkgdir/usr/bin/ckan"
cp "$srcdir/$pkgname-v$pkgver.exe" "$pkgdir/usr/bin/ckan"
chmod 755 "$pkgdir/usr/bin/ckan"
}

Loading…
Cancel
Save