diff options
author | 2011-08-11 10:40:41 +0000 | |
---|---|---|
committer | 2011-08-11 10:40:41 +0000 | |
commit | d081602c783c0348159bbbb5ebcb20dadca84b96 (patch) | |
tree | d7a69272b388e9e121ac8f132ad16fcef4e10a34 /app-misc/editor-wrapper/files | |
parent | Add missing dependency: dev-perl/Capture-Tiny (#378739) (diff) | |
download | historical-d081602c783c0348159bbbb5ebcb20dadca84b96.tar.gz historical-d081602c783c0348159bbbb5ebcb20dadca84b96.tar.bz2 historical-d081602c783c0348159bbbb5ebcb20dadca84b96.zip |
Package moved from app-editors/gentoo-editor to app-misc/editor-wrapper.
Package-Manager: portage-2.1.10.10/cvs/Linux x86_64
RepoMan-Options: --force
Diffstat (limited to 'app-misc/editor-wrapper/files')
-rw-r--r-- | app-misc/editor-wrapper/files/editor-wrapper-2.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/app-misc/editor-wrapper/files/editor-wrapper-2.sh b/app-misc/editor-wrapper/files/editor-wrapper-2.sh new file mode 100644 index 000000000000..dc8e065e0f29 --- /dev/null +++ b/app-misc/editor-wrapper/files/editor-wrapper-2.sh @@ -0,0 +1,17 @@ +#!/bin/sh +# Copyright 2009-2011 Gentoo Foundation +# Distributed under the terms of the MIT/X11 license + +# Editor wrapper script, executes ${EDITOR} with arguments $@ + +if [ -z "${EDITOR}" ]; then + # Try to get EDITOR from system profile + EDITOR=$(. /etc/profile &>/dev/null; echo "${EDITOR}") +fi + +if [ -z "${EDITOR}" ]; then + echo "$0: The EDITOR variable must be set" >&2 + exit 1 +fi + +exec ${EDITOR} "$@" |