Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Want to replace bash w zsh as system shell on Ubuntu

Joke de Buhr wrote:
> On Tuesday 02 February 2010 11:11:40 Richard Hartmann wrote:
> Sh compliant shell scripting can't use stuff like associative arrays, 
> subshell commands like "echo $(date -R)" or "[["-style tests. But some init 
> scripts do.

Not entirely true. Associative arrays can't be used, true. [[ ... ]]
cannot either. True.

But $(...) is perfectly correct syntax in POSIX shells. You may be
confused here, because older bourne shells don't support this. Shells
that adhere the standard, however, do.

>> I would just
>>   chsh
>> as root and be done with it.
> There's a difference between running "sudo -s" and changing the shell via 
> "chsh" and using "su". Sudo doesn't change the HOME environmental variable to 
> HOME=/root. It's set to "HOME=$HOME" so the root session uses the 
> configuration files of the user. That's why you don't have to copy your 
> ~/.vimrc configuration to /root/.vimrc.
> This behavior is very important if you're running a system with multiple 
> admins.

Yeah, it's also funny to suddenly end up with a number of your files
being owned by root (shouldn't happen with zsh's history file, since zsh
keeps track of the file's permissions even with the HIST_SAVE_BY_COPY
option enabled - which is the default; but not everything is as cautious
as zsh is).

Regards, Frank

In protocol design, perfection has been reached not when there is
nothing left to add, but when there is nothing left to take away.
                                                  -- RFC 1925

Messages sorted by: Reverse Date, Date, Thread, Author