chiark
/
gitweb
/
~mdw
/
profile
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
afda7f5
)
dot/bashrc: Portability: use termcap if terminfo doesn't work.
author
Mark Wooding
<mdw@distorted.org.uk>
Sat, 25 Jun 2011 13:40:05 +0000
(14:40 +0100)
committer
Mark Wooding
<mdw@distorted.org.uk>
Wed, 30 Nov 2011 19:18:58 +0000
(19:18 +0000)
Grumble grumble FreeBSD grumble.
dot/bashrc
patch
|
blob
|
blame
|
history
diff --git
a/dot/bashrc
b/dot/bashrc
index c26fad38cab93136c1157eb265d67347a4269373..f6b7a56e0015135c8781772182f88e6da04a3336 100644
(file)
--- a/
dot/bashrc
+++ b/
dot/bashrc
@@
-26,7
+26,12
@@
if [ -t 0 ]; then
## Fancy highlighting in some terminals.
case "$TERM" in
linux*|screen*|xterm*|vt100*|eterm*)
- bold="\[$(tput bold)\]" unbold="\[$(tput sgr0)\]" nl="\[
\r
\]" ;;
+ case "$(tput bold)" in
+ "") bold="\[$(tput md)\]" unbold="\[$(tput me)\]" ;;
+ *) bold="\[$(tput bold)\]" unbold="\[$(tput sgr0)\]" ;;
+ esac
+ nl="\[
\r
\]"
+ ;;
*)
bold='' unbold='' nl='' ;;
esac