[bugs] [OpenIndiana Distribution - Bug #882] Default $PS1 doesn't work properly

illumos bugs bugs at lists.illumos.org
Sun Jul 17 02:57:53 PDT 2011


Issue #882 has been updated by Julian Wiesener.

Difficulty set to Medium
Tags set to needs-triage

1. seems to has been fixed

root at laphroaig:~# cd /tmp/root/
root at laphroaig:/tmp/root# p="${PWD/~(El)${HOME}/\~}"
root at laphroaig:/tmp/root# echo $p   
/tmp/root

2. i would reject, it's not a bug.

if anyone want to improve /etc/ksh.kshrc, go ahead.
----------------------------------------
Bug #882: Default $PS1 doesn't work properly
https://www.illumos.org/issues/882

Author: River Tarnell
Status: New
Priority: Normal
Assignee: 
Category: 
Target version: 
Difficulty: Medium
Tags: needs-triage


There are two problems with the default $PS1 on OI.

<pre>root at db:~# echo $PS1
${LOGNAME}@$(/usr/bin/hostname):$( [[ "${LOGNAME}" == "root" ]] && printf "%s" "${PWD/${HOME}/~}# " || printf "%s" "${PWD/${HOME}/~}\$ ")</pre>

1: Changing to a directory which contains $HOME as a substring gives wrong prompt:
<pre>root at db:/# echo $HOME
/root
root at db:/# mkdir /tmp/root
root at db:/# cd /tmp/root
root at db:/tmp~# </pre>

2: After 'su', username doesn't change:
<pre>root at db:~# id
uid=0(root) gid=0(root)
root at db:~# su postgres
root at db:~# id
uid=90(postgres) gid=90(postgres)</pre>




-- 
You have received this notification because you have either subscribed to it, or are involved in it.
To change your notification preferences, please click here: http://www.illumos.org/my/account



More information about the bugs mailing list