Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: what is the effect of a percentage sign (%) as last character on the command line
- X-seq: zsh-users 14741
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: Peter <vmail@xxxxxxxxxxxxx>
- Subject: Re: what is the effect of a percentage sign (%) as last character on the command line
- Date: Sat, 23 Jan 2010 15:52:39 -0800
- Cc: zsh-users@xxxxxxx
- In-reply-to: <4B597061.10701@xxxxxxxxxxxxx>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <4B582F3C.2010709@xxxxxxxxxxxxx> <100121080540.ZM21444@xxxxxxxxxxxxxxxxxxxxxx> <4B58AB3A.7050300@xxxxxxxxxxxxx> <2d3b879b1001211336m5b78982au96f267ea472af43d@xxxxxxxxxxxxxx> <4B58D35D.1050208@xxxxxxxxxxxxx> <100121182713.ZM21821@xxxxxxxxxxxxxxxxxxxxxx> <4B597061.10701@xxxxxxxxxxxxx>
On Jan 22, 10:31am, Peter wrote:
}
} I had in .zshrc
}
} case $TERM in
} (xterm*|rxvt|mrxvt)
} print -Pn "\e]0;%n@%m: $1\a"
} ;;
} esac
I presume you had that somewhere interesting like inside your precmd
or preexec function? Just having it "in .zshrc" wouldn't affect any
command except possibly the very first one.
} I take it as an exercise for 2010 to understand why the first version
} causes the erroneous behavior (;-
Most likely there's an incomplete terminal control sequence being output
which causes the terminal to consume your input (or cover up the output).
Having the "% " in there somehow "finishes" that terminal control and
thus allows the I/O to pass normally through the shell.
You might be able to see more precisely what happened by running zsh
under "script" and then looking at the resulting typescript file.
SYNOPSIS
script [-a] [-c COMMAND] [-f] [-q] [-t] [file]
DESCRIPTION
Script makes a typescript of everything printed on your terminal
Messages sorted by:
Reverse Date,
Date,
Thread,
Author