slanger 0.3.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/bin/slanger +11 -5
- metadata +2 -2
data/bin/slanger
CHANGED
|
@@ -9,17 +9,18 @@ options = {
|
|
|
9
9
|
websocket_port: '8080', debug: false, redis_address: 'redis://0.0.0.0:6379/0'
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
+
|
|
12
13
|
OptionParser.new do |opts|
|
|
13
14
|
opts.on '-h', '--help', 'Display this screen' do
|
|
14
15
|
puts opts
|
|
15
16
|
exit
|
|
16
17
|
end
|
|
17
18
|
|
|
18
|
-
opts.on '-k', '--app_key APP_KEY', "Pusher application key" do |k|
|
|
19
|
+
opts.on '-k', '--app_key APP_KEY', "Pusher application key. This parameter is required." do |k|
|
|
19
20
|
options[:app_key] = k
|
|
20
21
|
end
|
|
21
22
|
|
|
22
|
-
opts.on '-s', '--secret SECRET', "Pusher application secret" do |k|
|
|
23
|
+
opts.on '-s', '--secret SECRET', "Pusher application secret. This parameter is required." do |k|
|
|
23
24
|
options[:secret] = k
|
|
24
25
|
end
|
|
25
26
|
|
|
@@ -57,11 +58,16 @@ OptionParser.new do |opts|
|
|
|
57
58
|
opts.on "-v", "--[no-]verbose", "Run verbosely" do |v|
|
|
58
59
|
options[:debug] = v
|
|
59
60
|
end
|
|
61
|
+
|
|
62
|
+
%w<app_key secret>.each do |parameter|
|
|
63
|
+
puts "--#{parameter} STRING is a required argument. Use your Pusher #{parameter}.\n" unless options[parameter.to_sym]
|
|
64
|
+
puts opts
|
|
65
|
+
exit
|
|
66
|
+
end
|
|
67
|
+
|
|
60
68
|
end.parse!
|
|
61
69
|
|
|
62
|
-
|
|
63
|
-
raise RuntimeError.new "--#{parameter} STRING is a required argument. Use your Pusher #{parameter}." unless options[parameter.to_sym]
|
|
64
|
-
end
|
|
70
|
+
|
|
65
71
|
|
|
66
72
|
if options[:tls_options]
|
|
67
73
|
[:cert_chain_file, :private_key_file].each do |param|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: slanger
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.3.
|
|
4
|
+
version: 0.3.1
|
|
5
5
|
prerelease:
|
|
6
6
|
platform: ruby
|
|
7
7
|
authors:
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2012-07-
|
|
12
|
+
date: 2012-07-19 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: eventmachine
|