aboutsummaryrefslogtreecommitdiff
path: root/lib/keyringer/parser.rb
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2011-01-29 19:57:28 -0200
committerSilvio Rhatto <rhatto@riseup.net>2011-01-29 19:57:28 -0200
commit5d0ae3722c6889fff8c00018066662260a71f3e2 (patch)
tree79ebea1770f60385da6bd2b088f79be51ec8b97b /lib/keyringer/parser.rb
parent3625a33af33b5b44dcc9ec5b9abb87f9bea079e6 (diff)
downloadkeyringer-5d0ae3722c6889fff8c00018066662260a71f3e2.tar.gz
keyringer-5d0ae3722c6889fff8c00018066662260a71f3e2.tar.bz2
Minor parsing changes
Diffstat (limited to 'lib/keyringer/parser.rb')
-rw-r--r--lib/keyringer/parser.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/keyringer/parser.rb b/lib/keyringer/parser.rb
index a3e71cf..ee6ddae 100644
--- a/lib/keyringer/parser.rb
+++ b/lib/keyringer/parser.rb
@@ -26,7 +26,7 @@ module Keyringer
options = {}
optparse = OptionParser.new do |opts|
# Set a banner, displayed at the top of the help screen.
- opts.banner = "Usage: #{File.basename($0)} [options] file1 file2 ..."
+ opts.banner = "Usage: #{File.basename($0)} <keyring> <action> [arguments]"
# TODO: example option
options[:verbose] = false
@@ -54,6 +54,10 @@ module Keyringer
$args = ARGV
$keyring = $args.shift
$action = $args.shift
+
+ if !$keyring or !$action
+ opts.on
+ end
end
end
end