On 05/04/2010 07:32 AM, Holger Hans Peter Freyther wrote:
I found it useful to be able to pass -V/-v/--verbose to all of the
tools. The patch is implemented it in the brute force way. I wonder if a
patch to create a base for the tools and common option handling would be
appreciated?

Yes, possibly following the option parsing code in the scripts/Package.st file, where the main body of the file is just

[ PackageManager new
        parseArguments: Smalltalk arguments;
        run
]
    on: Error
    do: [ :ex |
        ('gst-package: ', ex messageText, '
') displayOn: stderr.
        ex pass. ObjectMemory quit: 1 ].

There is one ugly nit however. scripts/Package.st must not require any package. So you cannot just put a superclass of PackageManager into a package "Tools".

I suppose you could put the code into scripts/Common.st and load it from gst-tool.c instead (using gst_process_file like it does already for the other scripts/*.st file).

I'll merge the patch soon.

Paolo


_______________________________________________
help-smalltalk mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-smalltalk

Reply via email to