diff options
author | XZS | 2015-08-06 14:45:03 +0200 |
---|---|---|
committer | XZS | 2015-08-06 14:45:03 +0200 |
commit | 7b3be9637ad58f5af2bca60cf85b44e14b79f1cc (patch) | |
tree | b710b215525a8c767d45b44d275e334e197f51c0 | |
parent | 85e4868afb30ec1d4a0291d978ade50594653a43 (diff) | |
download | aur-7b3be9637ad58f5af2bca60cf85b44e14b79f1cc.tar.gz |
sort package functions
-rw-r--r-- | PKGBUILD | 32 |
1 files changed, 16 insertions, 16 deletions
@@ -22,22 +22,6 @@ pkgver() { [ ${PIPESTATUS[0]} -ne 0 ] && \ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" } -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 @@ -55,3 +39,19 @@ package_02_install() { msg2 'Installing extension code...' find -maxdepth 1 \( -iname '*.js*' -or -iname '*.css' -or -iname '*.ui' \) -exec install -Dm644 -t "$destdir" '{}' + } +depends[125]=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[125] +} |