summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorHexchain Tong2016-03-30 12:59:22 +0800
committerHexchain Tong2016-03-30 12:59:22 +0800
commit4396fc1c01552a8e60aacb17f5ed6006560f4072 (patch)
treeb19b3dc8553204977c4f2af81f0574dae5f5f1b7
parent285e89a9fd6aa2256e0a2bba26ab509610ad9516 (diff)
downloadaur-4396fc1c01552a8e60aacb17f5ed6006560f4072.tar.gz
put elvish into /etc/shells
-rw-r--r--.SRCINFO5
-rw-r--r--PKGBUILD3
-rw-r--r--elvish.install9
3 files changed, 14 insertions, 3 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 84d533574ec0..10c60fe9a073 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,10 +1,11 @@
# Generated by mksrcinfo v8
-# Wed Mar 30 04:43:31 UTC 2016
+# Wed Mar 30 04:59:08 UTC 2016
pkgbase = elvish
pkgdesc = A novel Unix shell.
pkgver = 0.1
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/elves/elvish
+ install = elvish.install
arch = i686
arch = x86_64
license = custom:2-clause BSD
diff --git a/PKGBUILD b/PKGBUILD
index 74861211e379..235a9499e429 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=elvish
pkgver=0.1
-pkgrel=1
+pkgrel=2
pkgdesc="A novel Unix shell."
arch=('i686' 'x86_64')
url="https://github.com/elves/elvish"
@@ -12,6 +12,7 @@ makedepends=('git' 'go')
depends=('glibc')
source=("git+https://github.com/elves/elvish.git#tag=0.1")
md5sums=('SKIP')
+install=elvish.install
prepare() {
cd "$srcdir"
diff --git a/elvish.install b/elvish.install
new file mode 100644
index 000000000000..41414644e72c
--- /dev/null
+++ b/elvish.install
@@ -0,0 +1,9 @@
+post_install() {
+ grep -qe '^/usr/bin/elvish$' etc/shells || echo '/usr/bin/elvish' >> etc/shells
+}
+
+pre_remove() {
+ sed -ri '\|^/usr/bin/elvish$|d' etc/shells
+}
+
+# vim:set ts=2 sw=2 et: