ruboty-snack 0.2.0 → 0.2.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 01a35a4719070bc5028697875cf0f94f044fc6f9
4
- data.tar.gz: 5da7def9df0118d1eff0b442198820d0dcc4f842
3
+ metadata.gz: cc41fa129f1900fbab5bdecf44e90577beae57a6
4
+ data.tar.gz: 463cfd9be7646fbbdbaa921838290ff274dc8f4e
5
5
  SHA512:
6
- metadata.gz: 9364c52bc532f3835a17f3c38f4333d90cf3bd14d929035afade0fc37a782cfd773e2d7fe9b770bf4be954b5f6d4b8a9519773fd5502958d96b506804518ad6b
7
- data.tar.gz: cf92d0b32e6db7c4615ea062fc8eeafd8b0b951a96bfa478ad58d7804746b8dddec119601dac041ca4f7316f1c8fb970fb3b02dffdeb0b7262ab9454e1fce48b
6
+ metadata.gz: 935969489869af7446ca2b8a4204e0b12ade6e5748267497d1f42604e02b3ae57f7530d098cb4fcddc8d46e21ce8b08f9bc6ead46c880e2e6b5133d4eafa23f2
7
+ data.tar.gz: ee018404d48c6322bbe4925a3ec9cfdeb48bad9111898f6579e9e0ac41c3d2f399b509a56c2390ee9a0eb34c520c5a30f42a4a848093befc18947e216864fd3e
@@ -12,23 +12,39 @@ module Ruboty
12
12
 
13
13
  on(
14
14
  /お腹(?<status>.+)/,
15
+ name: "feed",
16
+ description: "Gives you some snacks"
17
+ )
18
+
19
+ on(
20
+ /(harahe|はらへ|ハラへ|ハラヘ)/,
15
21
  name: "feed_snack",
16
22
  description: "Gives you some snacks"
17
23
  )
18
24
 
19
- def feed_snack(message)
20
- oyatsu =
25
+ def feed(message)
26
+ esa =
21
27
  case message[:status]
22
28
  when /すい/, /空/, /へっ/, /減/, /すき/,
23
29
  /ペコペコ/, /ぺこぺこ/
24
- OYATSU.sample
30
+ oyatsu
25
31
  when /痛い/, /いたい/
26
32
  "💊"
27
33
  when /いっぱい/, /ぱんぱん/, /パンパン/, /く/, /苦/
28
34
  "☕"
29
35
  end
36
+ message.reply("つ#{esa}")
37
+ end
38
+
39
+ def feed_snack(message)
30
40
  message.reply("つ#{oyatsu}")
31
41
  end
42
+
43
+ private
44
+
45
+ def oyatsu
46
+ OYATSU.sample
47
+ end
32
48
  end
33
49
  end
34
50
  end
@@ -1,5 +1,5 @@
1
1
  module Ruboty
2
2
  module Snack
3
- VERSION = "0.2.0"
3
+ VERSION = "0.2.1"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruboty-snack
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Risa Harada
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-10-28 00:00:00.000000000 Z
11
+ date: 2016-11-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ruboty