diff options
| author | Ralph Amissah <ralph@amissah.com> | 2010-09-13 07:54:13 -0400 | 
|---|---|---|
| committer | Ralph Amissah <ralph@amissah.com> | 2010-09-22 09:53:09 -0400 | 
| commit | 95a44653ab3d679464510161d3f5a9cb65b97c5f (patch) | |
| tree | f08d559e8dbd14584a5aac66f87848c37ba92b90 /lib | |
| parent | changelog 2.6.3-4 [debian package rebuilt (squeeze freeze)] (diff) | |
options, add expressive options --[name] as alternative to flags -[x]
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/sisu/v2/options.rb | 43 | 
1 files changed, 33 insertions, 10 deletions
| diff --git a/lib/sisu/v2/options.rb b/lib/sisu/v2/options.rb index fbf8336a..94a23590 100644 --- a/lib/sisu/v2/options.rb +++ b/lib/sisu/v2/options.rb @@ -125,16 +125,39 @@ module SiSU_commandline        unless m.empty?          m.each do |m|            case m -          when /--maintenance/ -            c=c+'M' -          when /--verbose[=-]3/ -            c=c+'VM' -          when /--verbose[=-]2|--Verbose|--VERBOSE/ -            c=c+'V' -          when /--verbose(?:[=-]1)?/ -            c=c+'v' -          when /--verbose[=-]0|--quiet|--silent/ -            c=c+'q' +          when /--color-toggle/;                           c=c+'c' +          when /--configure/;                              c=c+'C' # issue should be CC +          when /--machine|--middle/;                       c=c+'m' +          when /--txt|--text|--plaintext/;                 c=c+'t' +          when /--html/;                                   c=c+'h' +          when /--epub/;                                   c=c+'e' +          when /--od[ft]/;                                 c=c+'o' +          when /--pdf/;                                    c=c+'p' +          when /--concordance|--wordmap/;                  c=c+'w' +          when /--manpage/;                                c=c+'i' +          when /--texinfo/;                                c=c+'I' +          when /--xhtml/;                                  c=c+'b' +          when /--xml-sax/;                                c=c+'x' +          when /--xml-dom/;                                c=c+'X' +          when /--digest/;                                 c=c+'N' +          when /--termsheet/;                              c=c+'T' +          when /--manifest/;                               c=c+'my' +          when /--sqlite/;                                 c=c+'d' +          when /--pg|--psql/;                              c=c+'D' +          when /--remote|--rsync/;                         c=c+'R' +          when /--scp/;                                    c=c+'r' +          when /--source/;                                 c=c+'s' +          when /--sisupod/;                                c=c+'S' +          when /--git/;                                    c=c+'g' +          when /--urls/;                                   c=c+'U' +          when /--zap|--delete/;                           c=c+'Z' +          when /--sample-search-form/;                     c=c+'F' +          when /--webserv|--webrick/;                      c=c+'W' +          when /--maintenance/;                            c=c+'M' +          when /--verbose[=-]3/;                           c=c+'VM' +          when /--verbose[=-]2|--Verbose|--VERBOSE/;       c=c+'V' +          when /--verbose(?:[=-]1)?/;                      c=c+'v' +          when /--verbose[=-]0|--quiet|--silent/;          c=c+'q'            else @mod << m            end          end | 
