rubyworks / qed

Quality Ensured Documentation

Home Page:http://rubyworks.github.com/qed

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Command line issues

wwood opened this issue · comments

Hi,

I'm attempting to package qed for the GNU Guix package manager, and I came across some things I imagine are easy to fix.

First, --version:

$ qed --version
/home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/lib/qed/cli/qed.rb:133:in `block (2 levels) in cli_parse': uninitialized constant QED::VERSION (NameError)
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1359:in `call'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1359:in `block in parse_in_order'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1346:in `catch'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1346:in `parse_in_order'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1340:in `order!'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1432:in `permute!'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1454:in `parse!'
    from /home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/lib/qed/cli/qed.rb:156:in `cli_parse'
    from /home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/lib/qed/cli/qed.rb:57:in `cli'
    from /home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/lib/qed/cli/qed.rb:5:in `cli'
    from /home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/bin/qed:3:in `<top (required)>'
    from /home/ben/.rvm/gems/ruby-2.1.1/bin/qed:23:in `load'
    from /home/ben/.rvm/gems/ruby-2.1.1/bin/qed:23:in `<main>'
    from /home/ben/.rvm/gems/ruby-2.1.1/bin/ruby_executable_hooks:15:in `eval'
    from /home/ben/.rvm/gems/ruby-2.1.1/bin/ruby_executable_hooks:15:in `<main>'

-h also gives some errors and a non-zero exitstatus (though it does get the job of providing help done):

$ qed -h
Usage: qed [options] <files...>
Report Formats (pick one):
    -v, --verbatim                   shortcut for verbatim reporter
    -y, --tapy                       shortcut for TAP-Y reporter
    -f, --format FORMAT              use custom reporter
Control Options:
    -p, --profile NAME               load runtime profile
    -c, --comment                    run comment code
    -I, --loadpath PATH              add paths to $LOAD_PATH
    -r, --require LIB                require feature (immediately)
    -R, --rooted                     run from project root instead of temporary directory
    -t, --trace [COUNT]              number of backtraces for exceptions (0 for all)
        --warn                       run with warnings turned on
        --debug                      exit immediately upon raised exception
Optional Commands:
        --version                    display version
        --copyright                  display copyrights
    -h, --help                       display this help message
/home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/lib/qed/cli/qed.rb:143:in `block (2 levels) in cli_parse': undefined local variable or method `settings' for QED::Session:Class (NameError)
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1390:in `call'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1390:in `block in parse_in_order'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1346:in `catch'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1346:in `parse_in_order'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1340:in `order!'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1432:in `permute!'
    from /home/ben/.rvm/rubies/ruby-2.1.1/lib/ruby/2.1.0/optparse.rb:1454:in `parse!'
    from /home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/lib/qed/cli/qed.rb:156:in `cli_parse'
    from /home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/lib/qed/cli/qed.rb:57:in `cli'
    from /home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/lib/qed/cli/qed.rb:5:in `cli'
    from /home/ben/.rvm/gems/ruby-2.1.1/gems/qed-2.9.2/bin/qed:3:in `<top (required)>'
    from /home/ben/.rvm/gems/ruby-2.1.1/bin/qed:23:in `load'
    from /home/ben/.rvm/gems/ruby-2.1.1/bin/qed:23:in `<main>'
    from /home/ben/.rvm/gems/ruby-2.1.1/bin/ruby_executable_hooks:15:in `eval'
    from /home/ben/.rvm/gems/ruby-2.1.1/bin/ruby_executable_hooks:15:in `<main>'

And lastly, the --copyright seems to be inconsistent with that described in the README. I imagine the README is correct and qed is licensed under bsd-2 and not asl2.0?

$ qed --copyright
Copyright (c) 2008 Thomas Sawyer, Apache 2.0 License

As the license is encoded in the Guix package definition, I am keen to get this right.

Thanks,
ben