[arch-commits] Commit in ksh/trunk (ksh.install)

Eli Schwartz eschwartz at archlinux.org
Wed Jun 19 01:30:49 UTC 2019


    Date: Wednesday, June 19, 2019 @ 01:30:48
  Author: eschwartz
Revision: 482272

committing the install script too, would be prudent

Added:
  ksh/trunk/ksh.install

-------------+
 ksh.install |   12 ++++++++++++
 1 file changed, 12 insertions(+)

Added: ksh.install
===================================================================
--- ksh.install	                        (rev 0)
+++ ksh.install	2019-06-19 01:30:48 UTC (rev 482272)
@@ -0,0 +1,12 @@
+post_install() {
+    grep -qx /bin/ksh /etc/shells || echo /bin/ksh >>/etc/shells
+    grep -qx /usr/bin/ksh /etc/shells || echo /usr/bin/ksh >>/etc/shells
+}
+
+post_upgrade() {
+    post_install
+}
+
+post_remove() {
+    sed -i -r '/^(\/usr)?\/bin\/ksh$/d' etc/shells
+}



More information about the arch-commits mailing list