summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorXZS2015-08-06 14:43:08 +0200
committerXZS2015-08-06 14:43:08 +0200
commit5f3cb252929f490ab7320b5d051e9108e7593097 (patch)
treed31a2b503a674a03c9bc9ca34c16c3085235c530
parentc141932b6ec4f7ce0772d0fa30effca22cb9233e (diff)
downloadaur-5f3cb252929f490ab7320b5d051e9108e7593097.tar.gz
sort package functions
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD61
2 files changed, 32 insertions, 31 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 29280698a7e..7b2bf97f857 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -6,8 +6,8 @@ pkgbase = gnome-shell-extension-activities-config
install = gschemas.install
arch = any
license = GPLv2
- depends = gnome-shell
depends = gnome-shell-extensions
+ depends = gnome-shell
source = extension.html::https://extensions.gnome.org/extension/358/activities-configurator/
source = archlinux-logo-gray-scalable.svg
md5sums = SKIP
diff --git a/PKGBUILD b/PKGBUILD
index f135d8749db..482ce56f283 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -46,22 +46,6 @@ build() {
cp --remove-destination ../archlinux-logo-gray-scalable.svg archlinux-logo-gray-scalable.svg
}
-depends[gnomeshell]=gnome-shell
-
-package_20_version() {
- local compatibles=($(\
- find -path ./pkg -type d -prune -o \
- -name metadata.json -exec grep -Pzo '(?s)(?<="shell-version": \[)[^\[\]]*(?=\])' '{}' \; | \
- tr '\n," ' '\n' | sed 's/3\.//g;/^$/d' | sort -n -t. -k 1,1))
- depends+=("gnome-shell>=3.${compatibles[0]}")
- local max="${compatibles[-1]}"
- if [ "3.$max" != $(
- gnome-shell --version | grep -Po '(?<=GNOME Shell 3\.)[[:digit:]]+'
- ) ]; then
- depends+=("gnome-shell<3.$((${max%%.*} + 1))")
- fi
- unset depends[gnomeshell]
-}
package() {
for function in $(declare -F | grep -Po 'package_[[:digit:]]+[[:alpha:]_]*$')
do
@@ -79,15 +63,18 @@ package_02_install() {
msg2 'Installing extension code...'
find -maxdepth 1 \( -iname '*.js*' -or -iname '*.css' -or -iname '*.ui' \) -exec install -Dm644 -t "$destdir" '{}' +
}
-if [ -z "$install" ]
-then
- install=gschemas.install
-fi
+depends+=(gnome-shell-extensions)
-package_10_schemas() {
- msg2 'Installing schemas...'
- find -name '*.xml' -exec install -Dm644 -t "$pkgdir/usr/share/glib-2.0/schemas" '{}' +
+package_03_unify_conveniencejs() {
+ ln -fs \
+ ../user-theme@gnome-shell-extensions.gcampax.github.com/convenience.js \
+ "$destdir/convenience.js"
}
+
+package_09_icon() {
+ install -Dm644 *.svg "$destdir"
+}
+
package_10_locale() {
msg2 'Installing translations...'
(
@@ -98,14 +85,28 @@ package_10_locale() {
done
)
}
-depends+=(gnome-shell-extensions)
+if [ -z "$install" ]
+then
+ install=gschemas.install
+fi
-package_03_unify_conveniencejs() {
- ln -fs \
- ../user-theme@gnome-shell-extensions.gcampax.github.com/convenience.js \
- "$destdir/convenience.js"
+package_10_schemas() {
+ msg2 'Installing schemas...'
+ find -name '*.xml' -exec install -Dm644 -t "$pkgdir/usr/share/glib-2.0/schemas" '{}' +
}
+depends[125]=gnome-shell
-package_09_icon() {
- install -Dm644 *.svg "$destdir"
+package_20_version() {
+ local compatibles=($(\
+ find -path ./pkg -type d -prune -o \
+ -name metadata.json -exec grep -Pzo '(?s)(?<="shell-version": \[)[^\[\]]*(?=\])' '{}' \; | \
+ tr '\n," ' '\n' | sed 's/3\.//g;/^$/d' | sort -n -t. -k 1,1))
+ depends+=("gnome-shell>=3.${compatibles[0]}")
+ local max="${compatibles[-1]}"
+ if [ "3.$max" != $(
+ gnome-shell --version | grep -Po '(?<=GNOME Shell 3\.)[[:digit:]]+'
+ ) ]; then
+ depends+=("gnome-shell<3.$((${max%%.*} + 1))")
+ fi
+ unset depends[125]
}