Re: Root/Administrator privileges from cygwin terminal

2013-10-24 Thread Kevin Layer
I use this: userchar='$' if [ "${WINDIR-}" ]; then if net session > /dev/null 2>&1; then userchar='#' fi fi export PS1="$PS1$userchar " I don't remember where I saw it, but it works well for me. I don't know if it's worse or better, but I'll throw it o

Re: Root/Administrator privileges from cygwin terminal

2013-10-24 Thread Christian Franke
someone at kosowsky dot org wrote: 2. Is there any better way to determine that one has Administrator privileges than to run something like: id -G | grep -Eq '<\544\>' Or: [[ `id -G` =~$(echo "\<544\>") ]] (note the 'echo' is used to get around inc

Re: Root/Administrator privileges from cygwin terminal

2013-10-24 Thread Corinna Vinschen
On Oct 24 12:22, Anthony Geoghegan wrote: > >The only solution I have now is to open a new bash window as > > administrator. > >So is there a way to elevate (or change) privileges from with a bash > > shell? > > A while ago, I researched a Cygwin equivalent for sudo but that's what > I e

Re: Root/Administrator privileges from cygwin terminal

2013-10-24 Thread Anthony Geoghegan
>The only solution I have now is to open a new bash window as administrator. >So is there a way to elevate (or change) privileges from with a bash shell? A while ago, I researched a Cygwin equivalent for sudo but that's what I ended up doing, myself. > 2. Is there any better way to determ