summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorXZS2016-11-01 13:58:46 +0100
committerXZS2016-11-02 18:17:39 +0100
commit8f1d7a02d57c6b246239e2452bb112904349fe32 (patch)
tree9742bb7a43f41ba8309fe23e6f5d6f5cf0305fd3 /PKGBUILD
parentb7b96cd5d533b85269f8598ce540e7dab7bcc693 (diff)
downloadaur-8f1d7a02d57c6b246239e2452bb112904349fe32.tar.gz
choose newest extension source
Some extensions authors introduce build steps required before installing. Their execution normally produces a completed variant of the extension code in a subdirectory, difficult to tell apart from the original source. The find condition introduced herein proves the process against such cases to come. It always chooses the files created last, ensuring that a build which occurred after mere unpacking will always take precedence.
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD5
1 files changed, 3 insertions, 2 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 44e57c010de..d6764006fc4 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -7,7 +7,7 @@
pkgname=gnome-shell-extension-dash-to-dock
pkgver=55
-pkgrel=1
+pkgrel=2
pkgdesc="move the dash out of the overview transforming it in a dock"
arch=('any')
url="https://micheleg.github.io/dash-to-dock/"
@@ -38,7 +38,8 @@ package() {
}
package_01_locate() {
msg2 'Locating extension...'
- cd "$(find -name 'metadata.json' -execdir test -e extension.js \; -printf %h -quit)"
+ cd "$(find -name 'metadata.json' -execdir test -e extension.js \; \
+ -printf '%C@ %h\n' | sort -nr | sed 's/^.* //;q' )"
extname=$(grep -Po '(?<="uuid": ")[^"]*' metadata.json)
destdir="$pkgdir/usr/share/gnome-shell/extensions/$extname"
}