aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2017-01-18 20:46:01 +1300
committerTom Ryder <tom@sanctum.geek.nz>2017-01-18 20:46:01 +1300
commit8bf807ab49a9de27a8a01157ebc7d7a770dfb229 (patch)
treedfb72d2ef4a7f656599e8ea430ead3da3d80644f
parentRevert "Remove some quotes that confused OpenBSD" (diff)
downloaddotfiles-8bf807ab49a9de27a8a01157ebc7d7a770dfb229.tar.gz
dotfiles-8bf807ab49a9de27a8a01157ebc7d7a770dfb229.zip
Revert "Color ed(1) prompt if possible"
This reverts commit ffd9d95b6adf5982448e1685a8c79c74b148cb00.
-rw-r--r--sh/shrc.d/ed.sh16
1 files changed, 2 insertions, 14 deletions
diff --git a/sh/shrc.d/ed.sh b/sh/shrc.d/ed.sh
index 3e544c74..d7d3fa2f 100644
--- a/sh/shrc.d/ed.sh
+++ b/sh/shrc.d/ed.sh
@@ -11,20 +11,8 @@ ed() {
[ -e "$HOME"/.cache/ed/verbose ] &&
set -- --verbose "$@"
- # Add an asterisk prompt (POSIX feature); color it dark green if we can
- set -- -p "$(
- if [ "$(tput colors || tput Co)" -gt 8 ] ; then
- ec=${ED_PROMPT_COLOR:-2}
- tput setaf "$ec" ||
- tput setaf "$ec" 0 0 ||
- tput AF "$ec" ||
- tput AF "$ec" 0 0
- printf %s "${ED_PROMPT:-'*'}"
- tput sgr0 || tput me
- else
- printf %s "${ED_PROMPT:-'*'}"
- fi 2>/dev/null
- )" "$@"
+ # Add an asterisk prompt (POSIX feature)
+ set -- -p\* "$@"
# Run in rlwrap(1) if available
set -- ed "$@"