From 9e16a4aea0dad1909abc78b3f9bc1291917486db Mon Sep 17 00:00:00 2001 From: Mike Burns Date: Thu, 1 Aug 2013 16:06:30 -0400 Subject: Add `mkrc -o` to install host-specific files To make it easier to manage host-specific rc files, `mkrc` now supports a `-o` option. This causes the specified file to be added to the host section named for the current machine. This option is in conflict with the `-t` option. --- share/rcm.sh.in | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'share/rcm.sh.in') diff --git a/share/rcm.sh.in b/share/rcm.sh.in index c057e87..3b8b87b 100644 --- a/share/rcm.sh.in +++ b/share/rcm.sh.in @@ -6,6 +6,7 @@ DEBUG=: DEST_DIR=$HOME PRINT=echo PROMPT=echo_n +ERROR=echo_error VERBOSE=: MKDIR=mkdir LN=ln @@ -20,6 +21,13 @@ echo_n() { printf "%s " "$*" } +echo_error() { + local exit_status=$1 + shift + echo $* >&2 + exit $exit_status +} + version() { cat << EOV $1 (rcm) $VERSION -- cgit v1.2.3