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

Re: Setting paths with ~'s in values.



Quoting Bart Schaefer (schaefer@xxxxxxxxxxxxxxxx):
> Danny Dulai writes:
>  > Quoting Bart Schaefer (schaefer@xxxxxxxxxxxxxxxx):
>  > > 
>  > >   for t_path in $(<${HOME}/.zpaths)
>  > >   do
>  > >       if 
>  > >           [[ -d $t_path ]]
>  > >       then 
>  > >           eval path=\( $path $t_path \)
>  > >       fi
>  > >   done
>  > 
>  > This didnt seem to add the paths with ~ in them because the ~ didnt get
>  > expanded in the test for existence.
> 
> Right, silly me.  There was even some discussion of file expansion (or
> more accurately, lack thereof) in [[ ... ]] expressions not long after
> this.

what is the difference between [[ ... ]] and [ ... ] ?

Is [[ the builtin version of the test command? Some systems I've seen have
has the [ command as a symlink to test. but zsh seems to have [ as a
builtin. So what is the diff between [[ ... ]] and [ ... ] ?

-- 
___________________________________________________________________________
Danny Dulai                                           Feet. Pumice. Lotion.
http://www.ishiboo.com/~nirva/                            nirva@xxxxxxxxxxx



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