There’s no syntax for it, but you can do something like set -l arg $argv[1]; test -z $arg; and set arg “default”
-Kevin On Jul 9, 2014, at 3:49 AM, Michael Stillwell <m...@beebo.org> wrote: > Does fish have a short equivalent to bash's "use default values" (i.e. > ${parameter:-word})? I'd like to use this to provide default values to > functions without having to write out laborious if ... else ... end > chains. > > > > > Michael > > ------------------------------------------------------------------------------ > Open source business process management suite built on Java and Eclipse > Turn processes into business applications with Bonita BPM Community Edition > Quickly connect people, data, and systems into organized workflows > Winner of BOSSIE, CODIE, OW2 and Gartner awards > http://p.sf.net/sfu/Bonitasoft > _______________________________________________ > Fish-users mailing list > Fish-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/fish-users ------------------------------------------------------------------------------ Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck® Code Sight™ - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds _______________________________________________ Fish-users mailing list Fish-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/fish-users