xdite 1.4.7 → 1.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/xdite.rb +7 -1
- data/lib/xdite/cli.rb +7 -3
- data/lib/xdite/version.rb +1 -1
- metadata +8 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a8ecd5e8da8f565b9dcb0e800971fa8507fa2e23
|
4
|
+
data.tar.gz: 4124b7f1fd96b70aa079f04365b177b894e6c78f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2ee9cb8e6ef28ae92481cb70a5481d2a2bc713f1c9014ba0a8b2271adf95802a023cb520efcda8985e4dd7d7f14b87408cc8333a78063bbee6957db7d9331cf3
|
7
|
+
data.tar.gz: e2c7e1fd707b2bb0211ed046d51aa66d543138633eb96bbfd6a47c6fed99ba51a0149259595b92391922a3c8869f0ce7108a9d262adca68a0d4431eca8bdee9a
|
data/lib/xdite.rb
CHANGED
@@ -17,7 +17,13 @@ module Xdite
|
|
17
17
|
end
|
18
18
|
|
19
19
|
def apologize
|
20
|
-
|
20
|
+
'別人變造我的講法還甚至發明我沒講過的話。那我到底要對這些內容去道歉什麼?'
|
21
|
+
end
|
22
|
+
|
23
|
+
def debate
|
24
|
+
ret = []
|
25
|
+
(rand(96) + 5).times{ ret << ['z', 'Z', '...'].sample }
|
26
|
+
ret.join
|
21
27
|
end
|
22
28
|
|
23
29
|
def quotes
|
data/lib/xdite/cli.rb
CHANGED
@@ -10,21 +10,25 @@ module Xdite
|
|
10
10
|
puts Xdite.says(number)
|
11
11
|
end
|
12
12
|
|
13
|
-
desc 'sentence [NUMBER]', 'Prints famous quotes inline
|
13
|
+
desc 'sentence [NUMBER]', 'Prints famous quotes inline'
|
14
14
|
def sentence number = 1
|
15
15
|
puts Xdite.sentence(number)
|
16
16
|
end
|
17
17
|
|
18
|
-
desc 'paragraph [NUMBER] [
|
18
|
+
desc 'paragraph [NUMBER] [SENTENCE_NUMBER]', 'Prints paragraphs'
|
19
19
|
def paragraph number = 1, per_paragraph = 5
|
20
20
|
puts Xdite.paragraph(number, per_paragraph)
|
21
21
|
end
|
22
22
|
|
23
|
-
desc 'apologize', '
|
23
|
+
desc 'apologize', 'Ask xdite to apologize'
|
24
24
|
def apologize
|
25
25
|
puts Xdite.apologize
|
26
26
|
end
|
27
27
|
|
28
|
+
desc 'debate', 'Ask xdite to debate'
|
29
|
+
def debate
|
30
|
+
puts Xdite.debate
|
31
|
+
end
|
28
32
|
|
29
33
|
desc 'version', 'Prints version'
|
30
34
|
def version
|
data/lib/xdite/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xdite
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tony Jian
|
@@ -47,12 +47,13 @@ post_install_message: |
|
|
47
47
|
|
48
48
|
$ xdite help
|
49
49
|
Commands:
|
50
|
-
xdite apologize
|
51
|
-
xdite
|
52
|
-
xdite
|
53
|
-
xdite
|
54
|
-
xdite
|
55
|
-
xdite
|
50
|
+
xdite apologize # Ask xdite to apologize
|
51
|
+
xdite debate # Ask xdite to debate
|
52
|
+
xdite help [COMMAND] # Describe available commands or one specific command
|
53
|
+
xdite paragraph [NUMBER] [SENTENCE_NUMBER] # Prints paragraphs
|
54
|
+
xdite says [NUMBER] # Prints famous quotes. (Default task)
|
55
|
+
xdite sentence [NUMBER] # Prints famous quotes inline
|
56
|
+
xdite version # Prints version
|
56
57
|
|
57
58
|
============================================
|
58
59
|
rdoc_options: []
|