|
Re: Insert date: msg#00049gnu.screen.user
On Thu, Apr 21, 2005 at 08:38:34PM +0200, Julius Plenz wrote: > Recently, I came across the idea to bind a key to insert the current > date, just like I bound keys to insert things using "stuff". > > However, I tried :bind d exec ! date +%Y-%m-%d. That almost works like > expected. I couldn't figure out exactly, but screen adds some strange > control character before or after the command. > > Why doesn't this work? How do I realize to insert the current date? [...] If you want the output of that command to be inserted as if typed from the keyboard, then, it should be exec .!. Note that date outputs a trailing NL (^J) character, that may be what you get. :bind d exec .!. zsh -c 'print -Pn %D{%F}' -- Stéphane |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Insert date: 00049, Julius Plenz |
|---|---|
| Next by Date: | Re: Insert date: 00049, Julius Plenz |
| Previous by Thread: | Insert datei: 00049, Julius Plenz |
| Next by Thread: | Re: Insert date: 00049, Julius Plenz |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |