From dfd4e99c1e981e66be32f113c1ea2b0e2b82f8bc Mon Sep 17 00:00:00 2001 From: MohamedElsiddig Date: Mon, 30 Mar 2020 19:45:06 +0200 Subject: [PATCH 1/6] Updated pachook --- pachook | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pachook b/pachook index f00a53c..f0a47c0 100755 --- a/pachook +++ b/pachook @@ -271,6 +271,6 @@ case "$1" in create) hook.create "$2";; enable|start) hook.setstate "${hook}" enable;; disable|stop) hook.setstate "${hook}" disable;; - -h) usage;; + -h|--help) usage;; *) hooks.view esac From 3389018b232f085e4fa63319e9cc327732d15be7 Mon Sep 17 00:00:00 2001 From: MohamedElsiddig Date: Mon, 30 Mar 2020 19:55:06 +0200 Subject: [PATCH 2/6] Updated readme.md --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index c242597..b1f6b09 100644 --- a/readme.md +++ b/readme.md @@ -7,7 +7,7 @@ Archlinux pacman hooks administrator with disabled exemples ## Installation With AUR : - yaourt -S pachook + yay -S pachook or : From a203cb277cbc631a3adae91166e2c439b915bc78 Mon Sep 17 00:00:00 2001 From: MohamedElsiddig Date: Mon, 30 Mar 2020 22:17:30 +0200 Subject: [PATCH 3/6] basic completion for pachook --- pachook-completion | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 pachook-completion diff --git a/pachook-completion b/pachook-completion new file mode 100644 index 0000000..b0b7d3f --- /dev/null +++ b/pachook-completion @@ -0,0 +1,11 @@ +__pachook() +{ + if [ "${#COMP_WORDS[@]}" != "2" ]; then + return + fi + + COMPREPLY=($(compgen -W "cat edit enable disable list" "${COMP_WORDS[1]}")) + +} + + complete -F __pachook pachook From 4b681f5ddb0d3eb0bd7e2732ad32e4fec9e54694 Mon Sep 17 00:00:00 2001 From: MohamedElsiddig Date: Mon, 30 Mar 2020 22:24:02 +0200 Subject: [PATCH 4/6] basic completion for pachook --- pachook-completion => etc/bash_completion.d/pachook-completion | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename pachook-completion => etc/bash_completion.d/pachook-completion (100%) diff --git a/pachook-completion b/etc/bash_completion.d/pachook-completion similarity index 100% rename from pachook-completion rename to etc/bash_completion.d/pachook-completion From fce121761d04fd4e4295459f9a631fde3b476a9f Mon Sep 17 00:00:00 2001 From: MohamedElsiddig Date: Mon, 30 Mar 2020 22:35:36 +0200 Subject: [PATCH 5/6] PKGBUILD To pachook --- PKGBUILD | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 PKGBUILD diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..454e948 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,25 @@ +# Maintainer: Papajoker +pkgname=pachook +pkgver=0.1.3.r1.g5d6fe4f +pkgrel=1 +pkgdesc="simple administrator pacman hooks" +arch=('any') +url="https://github.com/MohamedElsiddig/pachook" +license=('GPL') +depends=('pacman') +makedepends=('git') +source=("$pkgname::git+https://github.com/MohamedElsiddig/pachook") +md5sums=('SKIP') + +pkgver() { + cd "$srcdir/$pkgname" + git describe --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g' +} + +package() { + cd "$srcdir/$pkgname" + install -Dm755 ${pkgname} ${pkgdir}/usr/bin/${pkgname} + #cp -r usr ${pkgdir}/ + cp -r etc ${pkgdir}/ +} + From 9b9e53da64a48d0b5cdd4e3df81e641ad259639a Mon Sep 17 00:00:00 2001 From: MohamedElsiddig Date: Mon, 30 Mar 2020 22:57:26 +0200 Subject: [PATCH 6/6] removed PKGBUILD to anther repo --- PKGBUILD | 25 ------------------------- 1 file changed, 25 deletions(-) delete mode 100644 PKGBUILD diff --git a/PKGBUILD b/PKGBUILD deleted file mode 100644 index 454e948..0000000 --- a/PKGBUILD +++ /dev/null @@ -1,25 +0,0 @@ -# Maintainer: Papajoker -pkgname=pachook -pkgver=0.1.3.r1.g5d6fe4f -pkgrel=1 -pkgdesc="simple administrator pacman hooks" -arch=('any') -url="https://github.com/MohamedElsiddig/pachook" -license=('GPL') -depends=('pacman') -makedepends=('git') -source=("$pkgname::git+https://github.com/MohamedElsiddig/pachook") -md5sums=('SKIP') - -pkgver() { - cd "$srcdir/$pkgname" - git describe --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g' -} - -package() { - cd "$srcdir/$pkgname" - install -Dm755 ${pkgname} ${pkgdir}/usr/bin/${pkgname} - #cp -r usr ${pkgdir}/ - cp -r etc ${pkgdir}/ -} -