summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorXZS2015-07-28 14:40:05 +0200
committerXZS2015-07-28 14:40:05 +0200
commita566dac1aea1f3187026a8e13e7ce7a5209dddaa (patch)
tree35c46bb4d1c70cd13907d880869e0ffd56d95820
downloadaur-a566dac1aea1f3187026a8e13e7ce7a5209dddaa.tar.gz
intital import from old AUR version 3
-rw-r--r--.SRCINFO14
-rw-r--r--PKGBUILD57
-rw-r--r--gschemas.install20
3 files changed, 91 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..3aecdb257afe
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,14 @@
+pkgbase = gnome-shell-extension-middleclickclose
+ pkgdesc = Close windows with a button click (the middle one by default) when in overview mode
+ pkgver = 6
+ pkgrel = 2
+ url = http://sourceforge.net/projects/buttons-to-panel/
+ install = gschemas.install
+ arch = any
+ license = unknown
+ depends = gnome-shell
+ source = gnome-shell-extension-middleclickclose.zip::http://sourceforge.net/projects/mt-miscellaneous/files/gnome-extensions/3.16/middleclickclose@paolo.tranquilli.gmail.com.v6.shell-extension.zip/download
+ md5sums = e7ea5800d8408ea33496cdac01a058f6
+
+pkgname = gnome-shell-extension-middleclickclose
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..9de979f26a71
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,57 @@
+# Maintainer: XZS <d dot f dot fischer at web dot de>
+# This PKGBUILD is maintained on GitHub <https://github.com/dffischer/gnome-shell-extensions>.
+# You may find it convenient to file issues and pull requests there.
+
+pkgname='gnome-shell-extension-middleclickclose'
+_extname='middleclickclose@paolo.tranquilli.gmail.com'
+pkgdesc="Close windows with a button click (the middle one by default) when in overview mode"
+pkgver=6
+pkgrel=2
+arch=(any)
+url='http://sourceforge.net/projects/buttons-to-panel/'
+license=(unknown)
+source=("${pkgname}.zip::http://sourceforge.net/projects/mt-miscellaneous/files/gnome-extensions/3.16/${_extname}.v6.shell-extension.zip/download")
+md5sums=('e7ea5800d8408ea33496cdac01a058f6')
+
+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
+ $function
+ done
+}
+package_01_locate() {
+ msg2 'Locating extension...'
+ cd "$(dirname $(find -name 'metadata.json' -print -quit))"
+ extname=$(grep -Po '(?<="uuid": ")[^"]*' metadata.json)
+ destdir="$pkgdir/usr/share/gnome-shell/extensions/$extname"
+}
+
+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
+
+package_10_schemas() {
+ msg2 'Installing schemas...'
+ find -name '*.xml' -exec install -Dm644 -t "$pkgdir/usr/share/glib-2.0/schemas" '{}' +
+}
diff --git a/gschemas.install b/gschemas.install
new file mode 100644
index 000000000000..863897ad5436
--- /dev/null
+++ b/gschemas.install
@@ -0,0 +1,20 @@
+post_install() {
+ instruct
+ echo "and enable the extension with gnome-tweak-tool."
+}
+
+post_upgrade() {
+ instruct
+ echo "for the changes to have an effect."
+}
+
+post_remove() {
+ glib-compile-schemas usr/share/glib-2.0/schemas/
+}
+
+instruct() {
+ post_remove
+ echo "Don't forget to restart GNOME Shell ([Alt]+[F2], r)"
+}
+
+# vim: ts=2 sw=2 et: