Show admin symbol in cygwin

This commit is contained in:
斟酌 鵬兄 2024-04-12 02:11:55 +09:00
parent 15e97dcc40
commit 7257ab62bc

View File

@ -290,7 +290,17 @@ function r2dissource {
rm -r "$_dis" "$RBASH_SOURCES" rm -r "$_dis" "$RBASH_SOURCES"
} }
export PS1="This is ${RHOSTNAME}\e[1;3${RCOLOR}m${RDOMAIN}\e[0m: \w\n\$ " _SHELLD="\$"
case $OSTYPE in
cygwin)
net session > /dev/null 2>&1
if [ $? -eq 0 ]; then
_SHELLD="#"
fi
;;
esac
export PS1="This is ${RHOSTNAME}\e[1;3${RCOLOR}m${RDOMAIN}\e[0m: \w\n$_SHELLD "
export EDITOR=vim export EDITOR=vim
export PATH="$RBASH_BIN:$PATH" export PATH="$RBASH_BIN:$PATH"