Re: [dev] goblin (9base in Go)

From: Alexander Surma <alexander.surma_AT_googlemail.com>
Date: Mon, 29 Mar 2010 17:56:42 +0200

How about improving the flags-package - or somewhat merging optparse
into flags (keeping the interface backwards-compatble).
I assume that would be greatly appreciated.

Surma

On Mon, Mar 29, 2010 at 5:51 PM, Jeff Shipley <jeffquiparle_AT_gmail.com> wrote:
> On Mon, Mar 29, 2010 at 2:41 AM, Szabolcs Nagy <nszabolcs_AT_gmail.com> wrote:
>> On 3/29/10, Jeff Shipley <jeffquiparle_AT_gmail.com> wrote:
>>> If you feel like criticizing, suggesting improvements, or helping out,
>>> check it out at http://bitbucket.org/amertune/goblin
>>>
>>>
>>
>> grep.go:7: fatal error: can't find import: optparse
>> i think you should use the "flag" package there as well
>>
>> in cat i think (&buf)[0:n] is the same as buf[0:n]
>>
>> the underscore_naming_style does not look nice in go somehow
>>
>>
>
> The Makefile isn't quite right for grep. It expects to find a compiled
> optparse in the _obj directory.
>
> The primary reason I went with the optparse library instead of using
> flag is that flag doesn't support multiple values for the same flag.
> grep -e expression1 -e expression2 -e expression3
> would be completely broken when using the flag package. I know that
> it's not really necessary; -e '(expression1|expression2|expression3)'
> would do the exact same thing. Still, it's a feature of grep that I
> like, and not one that I'd want to drop just because the built-in
> package doesn't support it.
>
> The biggest thing I don't like about using optparse for grep (and flag
> for everything else) is that it breaks consistency with the other
> programs. grep can group options (-hnv), while none of the other
> programs can. I'm considering moving everything over to optparse, for
> consistency.
>
> Thanks for the language tips, I just started learning Go last week
> when I started this project.
>
>
Received on Mon Mar 29 2010 - 15:56:42 UTC

This archive was generated by hypermail 2.2.0 : Mon Mar 29 2010 - 16:00:05 UTC