Wow, that was a very quick response. Thank you very much.

— Attila

On 16 Jul 2013, at 13:31, Stestagg <[email protected]> wrote:

> sorry for the mail Attila, something weird happened (I pressed ctrl+Enter 
> prematurely)
> 
> Fish 2.0 has the 'test' builtin:
> 
> https://github.com/fish-shell/fish-shell/blob/master/doc_src/test.txt
> 
> This provides a posix-like test interface.
> 
> Btw, it looks like the hosted fish-shell docs aren't up-to-date
> 
> Thanks
> 
> Steve
> 
> 
> On Tue, Jul 16, 2013 at 12:23 PM, Attila Györffy <[email protected]> 
> wrote:
> Hi all,
> 
> I’ve been a zsh shell user for a while and after I’ve discovered fish shell, 
> I became interested in it and decided to slowly migrate to it. I currently 
> have a couple of expressions and settings in .zshenv and .zshrc that I’d like 
> to port to the fish configuration.
> 
> My question is the following:
> 
> Does fish have a mechanism to tell if a directory exists? This could be extra 
> useful to set environment variables based on that condition. The POSIX 
> equivalent looks like this:
> 
> if [[ -d "${HOME}/.bin" ]]; then
>   export PATH=~/bin:${PATH}
> fi
> 
> I’d like to see how to use the same (and similar) functions in fish shell, 
> such as...
> 
> * Testing if a directory exists (-d)
> * Testing if a file exists (-a)
> * Testing if a file is executable (-x)
> 
> Thanks in advance,
> 
> — Attila
> ------------------------------------------------------------------------------
> See everything from the browser to the database with AppDynamics
> Get end-to-end visibility with application monitoring from AppDynamics
> Isolate bottlenecks and diagnose root cause in seconds.
> Start your free trial of AppDynamics Pro today!
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
> _______________________________________________
> Fish-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/fish-users

------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
Fish-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to