Re: Mimic zsh's right prompt in bash
* Thorsten Kampe (Thu, 31 May 2007 19:02:46 +0100)
> * Thorsten Kampe (Thu, 31 May 2007 18:25:17 +0100)
> > How can I mimic a typical zsh prompt with the current directory at the
> > right in bash?
> >
> > My zsh prompt is:
> > user@host% /path/to/pwd
> >
> > How can I mimic the right hand side in bash with PS1?
>
> Oops, that's already been asked in May. I'll read through the
> thread...
Hm, interesting thread but no answer given. I /guess/ it should be
possible to mimic the RPS1 in bash by extending the PS1 prompt to the
right.
Just to give a hint how this could be achieved in a shell that doesn't
have its own right hand side prompt:
In 4NT (Windows Cmd enhancement and replacement) you could do:
set prompt=`%_winuser@%_host%$g$s$e[s$e[%@inc[%_row];%@eval[%_columns
- %@len[%_cwd]]H$p$e[u`
Thorsten
|