trollop:mainline.git
6 years agomore documentation fixups master release-2.0
William Morgan [Wed, 15 Aug 2012 06:04:35 +0000 (23:04 -0700)]
more documentation fixups

6 years agobump to 2.0
William Morgan [Wed, 15 Aug 2012 04:42:04 +0000 (21:42 -0700)]
bump to 2.0

6 years agofix rake test task
William Morgan [Wed, 15 Aug 2012 04:40:08 +0000 (21:40 -0700)]
fix rake test task

6 years agomisc code cleanups
William Morgan [Wed, 15 Aug 2012 04:39:58 +0000 (21:39 -0700)]
misc code cleanups

6 years agochange behavior for boolean flags
William Morgan [Sun, 12 Aug 2012 22:11:14 +0000 (15:11 -0700)]
change behavior for boolean flags

With this change, specifying --x on the commandline sets the value of
option :x to true. Specifying --no-x sets the value of option :x to
false. Not specifying either on the commandline sets the value of option
:x to its default.

(Previously, using --x would set the value of :x to the opposite of its
default value, and not specifying it would set :x to the default value,
and using --no-x would result in an error.)

There is one special case to this, which is that an option called :no_x
gets the inverted behavior of what the option :x would have.
Specifically, specifying --no-x on the commandline will set the value of
:no_x to true, specifying --x will set the value of :no_x to false, and
not specifying either will set the value of :no_x to its default.

6 years agorandom documentation tweaks
William Morgan [Sat, 11 Aug 2012 23:06:37 +0000 (16:06 -0700)]
random documentation tweaks

6 years agofix broken example on webpage
William Morgan [Fri, 18 May 2012 04:14:06 +0000 (21:14 -0700)]
fix broken example on webpage

6 years agofor flags that default to true, display --no-X instead of --X
William Morgan [Mon, 23 Apr 2012 23:22:26 +0000 (16:22 -0700)]
for flags that default to true, display --no-X instead of --X

Continue to accept --X as well as --no-X.

6 years agoremove warnings during test time
William Morgan [Mon, 23 Apr 2012 23:08:31 +0000 (16:08 -0700)]
remove warnings during test time

6 years agofix warning; thanks to Petty E. Metzger
William Morgan [Mon, 23 Apr 2012 23:08:18 +0000 (16:08 -0700)]
fix warning; thanks to Petty E. Metzger

6 years agofix Rakefile to 1.9 compatibility
William Morgan [Mon, 23 Apr 2012 23:07:34 +0000 (16:07 -0700)]
fix Rakefile to 1.9 compatibility

8 years agofix w_s_e_h example, thanks to 'jon.forums'
William Morgan [Mon, 28 Jun 2010 19:04:16 +0000 (15:04 -0400)]
fix w_s_e_h example, thanks to 'jon.forums'

8 years agobump to 1.16.2 release-1.16.2
William Morgan [Tue, 6 Apr 2010 15:52:58 +0000 (11:52 -0400)]
bump to 1.16.2

8 years agoadd unit test for Trollop::die bug
William Morgan [Tue, 6 Apr 2010 15:52:45 +0000 (11:52 -0400)]
add unit test for Trollop::die bug

8 years agoanother bugfix in Trollop::options
William Morgan [Tue, 6 Apr 2010 15:19:22 +0000 (11:19 -0400)]
another bugfix in Trollop::options

This time, with unit tests!

8 years agoupdate release-script.txt
William Morgan [Tue, 6 Apr 2010 00:29:57 +0000 (20:29 -0400)]
update release-script.txt

8 years agobump to 1.16.1 release-1.16.1
William Morgan [Tue, 6 Apr 2010 00:23:46 +0000 (20:23 -0400)]
bump to 1.16.1

8 years agotweak README so that it looks better with darkfish
William Morgan [Tue, 6 Apr 2010 00:22:34 +0000 (20:22 -0400)]
tweak README so that it looks better with darkfish

8 years agorefactor Trollop::die into Trollop::Parser#die and fix a bug
William Morgan [Tue, 6 Apr 2010 00:13:46 +0000 (20:13 -0400)]
refactor Trollop::die into Trollop::Parser#die and fix a bug

Trollop::die was depending on a magic @p variable to know which parser
to produce an error message for, which was removed in the last release.
Re-add this variable with a better name, improve the error handling, and
have the actual meat of the method be Parser#die

8 years agobump to 1.16 release-1.16
William Morgan [Thu, 1 Apr 2010 19:32:53 +0000 (15:32 -0400)]
bump to 1.16

8 years agoupdate release-script to gemcutter world
William Morgan [Thu, 1 Apr 2010 20:43:57 +0000 (16:43 -0400)]
update release-script to gemcutter world

8 years agoupdate index.html with 1.16 documentation and contributors
William Morgan [Thu, 1 Apr 2010 20:40:13 +0000 (16:40 -0400)]
update index.html with 1.16 documentation and contributors

8 years agoupdate History for 1.16 release
William Morgan [Thu, 1 Apr 2010 20:39:58 +0000 (16:39 -0400)]
update History for 1.16 release

8 years agodrop hoe and get with new gem creation
William Morgan [Thu, 1 Apr 2010 19:30:15 +0000 (15:30 -0400)]
drop hoe and get with new gem creation

Finally!

8 years agoadd Trollop::with_standard_exception_handling method
William Morgan [Thu, 1 Apr 2010 18:41:55 +0000 (14:41 -0400)]
add Trollop::with_standard_exception_handling method

Refactors the "standard" exception-handling logic into this method, so
that people who want specialized logic with Parser#parse can still make
use of it.

8 years agomodify #parse argument array in place
William Morgan [Thu, 1 Apr 2010 18:24:49 +0000 (14:24 -0400)]
modify #parse argument array in place

This was the effective behavior of Trollop::options anyways, and
this makes it easier to implement variants of that method.

8 years agohandle scientific notation
Will Fitzgerald [Wed, 31 Mar 2010 17:48:59 +0000 (13:48 -0400)]
handle scientific notation

The float option doesn't (yet) handle scientific notation, but it
could with this diff from the current Git repo. It adds an optional
part to the FLOAT_RE, and a test at the end.

8 years agoadd .gitignore
William Morgan [Thu, 1 Apr 2010 19:33:09 +0000 (15:33 -0400)]
add .gitignore

9 years agoupdate license in trollop.rb to match the license terms in README.txt
William Morgan [Sun, 3 Jan 2010 12:37:34 +0000 (07:37 -0500)]
update license in trollop.rb to match the license terms in README.txt

9 years agominor: required option error message was ugly
William Morgan [Tue, 8 Dec 2009 14:40:35 +0000 (06:40 -0800)]
minor: required option error message was ugly

It should use the real option name, not the ruby symbol.

9 years agoupdate URL in README.txt
William Morgan [Wed, 30 Sep 2009 19:15:05 +0000 (15:15 -0400)]
update URL in README.txt

9 years agofix broken html on webpage
William Morgan [Wed, 30 Sep 2009 18:56:54 +0000 (14:56 -0400)]
fix broken html on webpage

9 years agobump to 1.15 release-1.15
William Morgan [Wed, 30 Sep 2009 18:53:22 +0000 (14:53 -0400)]
bump to 1.15

9 years agominor README.txt tweaks
William Morgan [Sun, 27 Sep 2009 17:49:08 +0000 (13:49 -0400)]
minor README.txt tweaks

9 years agodon't raise when out of short options
William Morgan [Sun, 27 Sep 2009 17:39:51 +0000 (13:39 -0400)]
don't raise when out of short options

9 years agobump to 1.14
William Morgan [Fri, 19 Jun 2009 14:35:03 +0000 (10:35 -0400)]
bump to 1.14

9 years agoupdate changelog for 1.14
William Morgan [Fri, 19 Jun 2009 14:34:40 +0000 (10:34 -0400)]
update changelog for 1.14

9 years agomake :multi arguments default to [], not nil
William Morgan [Fri, 19 Jun 2009 14:32:18 +0000 (10:32 -0400)]
make :multi arguments default to [], not nil

9 years agoimprove a few comments and error output
William Morgan [Fri, 19 Jun 2009 14:28:29 +0000 (10:28 -0400)]
improve a few comments and error output

9 years agoupdate webpage and FAQ
William Morgan [Wed, 3 Jun 2009 13:33:40 +0000 (09:33 -0400)]
update webpage and FAQ

9 years agoAdded :date option type.
Erik Ostrom [Thu, 11 Dec 2008 07:14:14 +0000 (23:14 -0800)]
Added :date option type.

Parses dates with Date.parse, or Chronic if it's available.

9 years agounshadow a variable
William Morgan [Mon, 23 Mar 2009 13:58:15 +0000 (09:58 -0400)]
unshadow a variable

Apparently this generates a warning in Ruby 1.9.1. No change in behavior
though.

Thanks to Tuomas Kareinen <kareinen@iki.fi>

9 years agobump to 1.13 release-1.13
William Morgan [Mon, 16 Mar 2009 17:53:23 +0000 (13:53 -0400)]
bump to 1.13

9 years agofix parsing of arg=<value with spaces>
William Morgan [Thu, 26 Feb 2009 21:50:47 +0000 (16:50 -0500)]
fix parsing of arg=<value with spaces>

Thanks to rogerpack2005 for pointing this out.

9 years agominor README tweaks
William Morgan [Fri, 30 Jan 2009 14:50:09 +0000 (06:50 -0800)]
minor README tweaks

9 years agobump to 1.12 release-1.12
William Morgan [Fri, 30 Jan 2009 14:45:15 +0000 (06:45 -0800)]
bump to 1.12

9 years agomove internal methods to bottom & mark private
William Morgan [Fri, 30 Jan 2009 14:41:44 +0000 (06:41 -0800)]
move internal methods to bottom & mark private

9 years agoresolve default shorts AFTER user shorts
William Morgan [Fri, 30 Jan 2009 14:36:19 +0000 (06:36 -0800)]
resolve default shorts AFTER user shorts

9 years agoadd some unit tests for given keys
William Morgan [Fri, 30 Jan 2009 13:50:48 +0000 (05:50 -0800)]
add some unit tests for given keys

9 years agoupdate unit tests to work with _given keys
William Morgan [Fri, 30 Jan 2009 13:47:30 +0000 (05:47 -0800)]
update unit tests to work with _given keys

9 years agobump to 1.11 release-1.11
William Morgan [Fri, 30 Jan 2009 03:01:35 +0000 (19:01 -0800)]
bump to 1.11

9 years agoset "<opt>_given" for each opt on the commandline
William Morgan [Fri, 30 Jan 2009 02:34:40 +0000 (18:34 -0800)]
set "<opt>_given" for each opt on the commandline

For every option <opt> given on the commanline, in the output hash of
Parser#parse (and thus Trollop.options), in addition to setting
<opt> to the value given, set <opt>_given to true. This is useful if you need
to know which arguments were actually specified on the commandline, e.g. for
situations where arguments can override other arguments when given.

10 years agoadd blog link to index.html
William Morgan [Thu, 23 Oct 2008 19:23:08 +0000 (12:23 -0700)]
add blog link to index.html

10 years agoadd links to README
William Morgan [Thu, 23 Oct 2008 18:48:17 +0000 (11:48 -0700)]
add links to README

10 years agofuck you rdoc, and fuck you rake
William Morgan [Thu, 23 Oct 2008 18:24:02 +0000 (11:24 -0700)]
fuck you rdoc, and fuck you rake

10 years agobump to 1.10.2 release-1.10.2
William Morgan [Thu, 23 Oct 2008 16:12:56 +0000 (09:12 -0700)]
bump to 1.10.2

10 years agoRevert "try and run 'stty size' to determine screen width"
William Morgan [Thu, 23 Oct 2008 16:10:11 +0000 (09:10 -0700)]
Revert "try and run 'stty size' to determine screen width"

This reverts commit 8dfa0de45bfcffc10eedf291b4c14426e3cb83d4.

10 years agoprettify default in help screen for arrays and IOs release-1.10.1
William Morgan [Thu, 23 Oct 2008 06:06:47 +0000 (23:06 -0700)]
prettify default in help screen for arrays and IOs

10 years agobugfix for :multi arguments and array defaults
William Morgan [Thu, 23 Oct 2008 06:06:26 +0000 (23:06 -0700)]
bugfix for :multi arguments and array defaults

10 years agobah, minor Rakefile bugfix
William Morgan [Thu, 23 Oct 2008 05:40:34 +0000 (22:40 -0700)]
bah, minor Rakefile bugfix

10 years agoupdate release script
William Morgan [Thu, 23 Oct 2008 05:36:30 +0000 (22:36 -0700)]
update release script

10 years agobump to 1.10.1
William Morgan [Thu, 23 Oct 2008 05:35:31 +0000 (22:35 -0700)]
bump to 1.10.1

10 years agovarious rakefile tweaks
William Morgan [Thu, 23 Oct 2008 05:35:05 +0000 (22:35 -0700)]
various rakefile tweaks

10 years agofix up ambiguous multi-value vs multi-occurrence with default case
William Morgan [Thu, 23 Oct 2008 05:10:26 +0000 (22:10 -0700)]
fix up ambiguous multi-value vs multi-occurrence with default case

10 years agomore documentation improvements
William Morgan [Thu, 23 Oct 2008 03:08:33 +0000 (20:08 -0700)]
more documentation improvements

10 years agowebpage source code bugfix
William Morgan [Thu, 23 Oct 2008 03:07:45 +0000 (20:07 -0700)]
webpage source code bugfix

10 years agofix up rdoc documentation generation
William Morgan [Thu, 23 Oct 2008 03:07:28 +0000 (20:07 -0700)]
fix up rdoc documentation generation

10 years agocomment out bad unit test that requires network access (will mock later)
William Morgan [Thu, 23 Oct 2008 02:14:39 +0000 (19:14 -0700)]
comment out bad unit test that requires network access (will mock later)

10 years agooptions return value now accepts method calls as well as hash keys (like OpenStruct)
William Morgan [Thu, 23 Oct 2008 01:53:15 +0000 (18:53 -0700)]
options return value now accepts method calls as well as hash keys (like OpenStruct)

10 years agowhoops; :io objects not generating right in help output release-1.10
William Morgan [Wed, 22 Oct 2008 01:43:32 +0000 (18:43 -0700)]
whoops; :io objects not generating right in help output

10 years agobump version to 1.10
William Morgan [Tue, 21 Oct 2008 23:55:20 +0000 (16:55 -0700)]
bump version to 1.10

10 years agoadd :io type for readonly files, urls, and stdin
William Morgan [Wed, 22 Oct 2008 00:26:28 +0000 (17:26 -0700)]
add :io type for readonly files, urls, and stdin

10 years agoupdate rdoc documentation
William Morgan [Tue, 21 Oct 2008 23:54:18 +0000 (16:54 -0700)]
update rdoc documentation

10 years agotry and run 'stty size' to determine screen width
William Morgan [Tue, 21 Oct 2008 23:22:29 +0000 (16:22 -0700)]
try and run 'stty size' to determine screen width

10 years agolots of documentation updates in index.html
William Morgan [Tue, 21 Oct 2008 23:13:36 +0000 (16:13 -0700)]
lots of documentation updates in index.html

10 years agoremove documentation from README.txt
William Morgan [Tue, 21 Oct 2008 22:15:33 +0000 (15:15 -0700)]
remove documentation from README.txt

10 years agoremove outdated FAQ entry
William Morgan [Tue, 21 Oct 2008 22:13:40 +0000 (15:13 -0700)]
remove outdated FAQ entry

10 years agobump to 1.9 release-1.9
William Morgan [Wed, 20 Aug 2008 16:34:04 +0000 (09:34 -0700)]
bump to 1.9

10 years agoupdate gem description to match README.txt
William Morgan [Wed, 20 Aug 2008 16:28:05 +0000 (09:28 -0700)]
update gem description to match README.txt

10 years agoadd release script
William Morgan [Wed, 20 Aug 2008 16:27:43 +0000 (09:27 -0700)]
add release script

10 years agoadd support for multiple options and multiple parameters
Tuomas Kareinen [Wed, 30 Jul 2008 22:15:19 +0000 (01:15 +0300)]
add support for multiple options and multiple parameters

Additional features:
  - an option can be given multiple times
  - an option supports multiple parameters

10 years agotest for alternate args source
Ohad Lutzky [Sun, 3 Aug 2008 23:54:09 +0000 (02:54 +0300)]
test for alternate args source

10 years agoallow different source of args for options (rather than ARGV)
Ohad Lutzky [Sun, 3 Aug 2008 21:53:25 +0000 (00:53 +0300)]
allow different source of args for options (rather than ARGV)

10 years agorepair stop_on_unknown, add units tests
Ohad Lutzky [Sun, 3 Aug 2008 21:47:58 +0000 (00:47 +0300)]
repair stop_on_unknown, add units tests

10 years agoMerge commit 'lutzky/master'
William Morgan [Sun, 3 Aug 2008 16:30:06 +0000 (09:30 -0700)]
Merge commit 'lutzky/master'

10 years agoadd a pointer to lib/trollop.rb directly from the webpage
William Morgan [Thu, 31 Jul 2008 17:28:10 +0000 (10:28 -0700)]
add a pointer to lib/trollop.rb directly from the webpage

10 years agoadd a nasty list of reasons to use trollop to the webpage
William Morgan [Thu, 31 Jul 2008 16:52:29 +0000 (09:52 -0700)]
add a nasty list of reasons to use trollop to the webpage

10 years agoimplement stop_on_unknown
Ohad Lutzky [Thu, 31 Jul 2008 07:02:40 +0000 (10:02 +0300)]
implement stop_on_unknown

Imported from ditz

10 years agocolorize html
William Morgan [Wed, 30 Jul 2008 21:26:19 +0000 (14:26 -0700)]
colorize html

10 years agopoint webpage to the new git repo
William Morgan [Wed, 30 Jul 2008 21:17:24 +0000 (14:17 -0700)]
point webpage to the new git repo

10 years agobump to 1.8.2
William Morgan [Wed, 25 Jun 2008 21:43:43 +0000 (21:43 +0000)]
bump to 1.8.2

10 years agoanother bugfix: conflicts and depends error messages were broken
William Morgan [Wed, 25 Jun 2008 21:42:48 +0000 (21:42 +0000)]
another bugfix: conflicts and depends error messages were broken

10 years agoscp -> rsync
William Morgan [Tue, 24 Jun 2008 23:09:20 +0000 (23:09 +0000)]
scp -> rsync

10 years agobump version to 1.8.1
William Morgan [Tue, 24 Jun 2008 22:54:48 +0000 (22:54 +0000)]
bump version to 1.8.1

10 years agomake documentation aggressive
William Morgan [Tue, 24 Jun 2008 22:54:11 +0000 (22:54 +0000)]
make documentation aggressive

10 years agobugfix: short option autocreation tries (and dies on) dashes
William Morgan [Tue, 24 Jun 2008 22:12:02 +0000 (22:12 +0000)]
bugfix: short option autocreation tries (and dies on) dashes

10 years agoBump version to 1.8.
William Morgan [Tue, 17 Jun 2008 04:40:59 +0000 (04:40 +0000)]
Bump version to 1.8.

10 years agoadd sub-command support via Parser#stop_on
William Morgan [Tue, 17 Jun 2008 04:39:35 +0000 (04:39 +0000)]
add sub-command support via Parser#stop_on

11 years agomark as 1.7.2
William Morgan [Wed, 16 Jan 2008 18:44:42 +0000 (18:44 +0000)]
mark as 1.7.2

11 years agoruby 1.9-ify
William Morgan [Wed, 16 Jan 2008 18:39:56 +0000 (18:39 +0000)]
ruby 1.9-ify