summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2013-09-08 11:51:26 (EDT)
committer P. J. McDermott <pjm@nac.net>2013-09-08 11:51:26 (EDT)
commit33d619a3a1f841158782a03fb78759aae1bec3ed (patch)
tree22efc03a1466afc05c3f3ac2c18623af5f0f2665
parentb833998bf932d783e3fb078353129d25ea1ef323 (diff)
gawk: Make /usr/bin/awk with update-alternatives.
-rw-r--r--gawk.pkg/postinst5
-rw-r--r--gawk.pkg/prerm5
2 files changed, 10 insertions, 0 deletions
diff --git a/gawk.pkg/postinst b/gawk.pkg/postinst
new file mode 100644
index 0000000..7e24c86
--- /dev/null
+++ b/gawk.pkg/postinst
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+if [ "x${1}" = 'xconfigure' ]; then
+ update-alternatives --install /usr/bin/awk awk /usr/bin/gawk 20
+fi
diff --git a/gawk.pkg/prerm b/gawk.pkg/prerm
new file mode 100644
index 0000000..0a76458
--- /dev/null
+++ b/gawk.pkg/prerm
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+if [ "x${1}" = 'xremove' ]; then
+ update-alternatives --remove awk /usr/bin/gawk
+fi