Hi Henry,

I'm so sorry for this slow reply, I have been away from any active fish
development for about a year.

If you still want to do an OpenBSD port I'll be happy to help. I have a work
mate who is a big fan of OpenBSD, and is actually the auther of the 'Book of
PF', a very nice book on using OpenBSD as a firewall. An OpenBSD port of
fish might convince him to switch shells. :)

About the getopt issue, I would say that using the bsd getopt without
gnu-style options should be ok. The reason for this is that somewhere around
99 % of all the option parsing in fish is done on fish builtins, not on fish
or any other proper binaries. And fish builtins use an internal getopt
implementation, since there exists no library to parse options that are wide
character strings, and fish uses wide character strings internally.

Axel

2008/8/26 Henry Precheur <he...@precheur.org>

> Greetings fish-users mailling list!
>
>
> I just started using Fish on Ubuntu and really like it. I am slowly
> leaving my old love ZSH.
>
> I am trying to make fish work on OpenBSD and would eventually make a port
> of fish for OpenBSD. But I just ran into a problem regarding getopt(1).
>
> Fish assumes that the GNU version of getopt(1) is present. This version
> comes with several extra-"features". Including long-options as
> documented here:
>
> http://www.rt.com/man/getopt.1.html
>
> The problem is that most *BSD stick to 'classic' version of getopt(1)
> without adding extra features:
>
> http://www.freebsd.org/cgi/man.cgi?query=getopt
> http://www.openbsd.org/cgi-bin/man.cgi?query=getopt
> http://netbsd.gw.com/cgi-bin/man-cgi?getopt
>
> These versions treat all options as options to be parsed and do not
> support long-options parsing. Which means every time fish uses a
> GNU/getopt options I get something like this:
>
>  getopt: unknown option -- Q
>  getopt: unknown option -- o
>
>
> I guess that removing -Q from fish scripts  is not a problem even though
> I don't understand what it does, thanks to the 'clear' explanation in
> the manual:
>
>  -Q, --quiet-output
>      Do not generate normal output. Errors are still reported by
>      getopt(3), unless you also use -q.
>
> The long-options removal should not be a problem technically, since it
> is possible to replace them with short options. The only problem is that
> short-options are not as nice and explicit as long-options.
>
>
> I can provide a patch, but I would like to be sure of what I am doing
> before doing anything ;-)
>
>  Cheers,
>
> --
>  Henry PrĂȘcheur
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Fish-users mailing list
> Fish-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/fish-users
>
>
------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
Fish-users mailing list
Fish-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to