about summary refs log tree commit diff
path: root/Src/prompt.c
diff options
context:
space:
mode:
authorAndrey Borzenkov <bor@users.sourceforge.net>2001-06-22 11:41:32 +0000
committerAndrey Borzenkov <bor@users.sourceforge.net>2001-06-22 11:41:32 +0000
commit2e54ff7652aa7dbee70e5a0ea8316d8c9b85251f (patch)
tree7be7dbf3d54ba3f4013ff17c9790bb7bc4347039 /Src/prompt.c
parentd908792fd49f71dd4bb68e771caca4b958e32ea7 (diff)
downloadzsh-2e54ff7652aa7dbee70e5a0ea8316d8c9b85251f.tar.gz
zsh-2e54ff7652aa7dbee70e5a0ea8316d8c9b85251f.tar.xz
zsh-2e54ff7652aa7dbee70e5a0ea8316d8c9b85251f.zip
15021: revert old %l; add %y instead
Diffstat (limited to 'Src/prompt.c')
-rw-r--r--Src/prompt.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/Src/prompt.c b/Src/prompt.c
index 47c8af797..eb79c7e85 100644
--- a/Src/prompt.c
+++ b/Src/prompt.c
@@ -515,6 +515,14 @@ putpromptchar(int doprint, int endchar)
 		break;
 	    case 'l':
 		if (*ttystrname) {
+                   ss = (strncmp(ttystrname, "/dev/tty", 8) ?
+                           ttystrname + 5 : ttystrname + 8);
+                   stradd(ss);
+               } else
+                   stradd("()");
+               break;
+           case 'y':
+               if (*ttystrname) {
 		    ss = (strncmp(ttystrname, "/dev/", 5) ?
 			    ttystrname : ttystrname + 5);
 		    stradd(ss);