lita-talk 0.1.4 → 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a3857b5a96e64788e9c74bf411ad9019e8afe190
4
- data.tar.gz: 5e9218d0299585ac17f30eb3f8224ffdc57ded72
3
+ metadata.gz: 38b90ebfb227ce96dc0b0c89dac125a6cf00cf72
4
+ data.tar.gz: 84be5598b89b6341efefaafc42e1945a89f59442
5
5
  SHA512:
6
- metadata.gz: e334c1f7e9754061945586bd5b0537192b88774729671aa0a3040d8268a67a89bcddc84f659798e849744d5437ba7f2cfdb13022a82144f11b574bae69edc611
7
- data.tar.gz: 94f5dd0dad4c9c4a206a14e23d0774c7cee09ab2007b4a8b1af9e789f458a552343763aa81ac0edc6a888e86e7951b7d949718dd4a8777c8fca8ebf9cf4bd784
6
+ metadata.gz: 1f903894538c30335b9e82557994acd2025e8484bfb8633c4a1f6e85c5620480e24cbf6ad99bb70ac71a7daa978c471c4e7ae931e4716dc5f5dddc77b147a215
7
+ data.tar.gz: 08a43863c82d660bf6d497a28504506a64c0e2afcc5c0eef1dfcbaab0d16aa094364082767c69b2ba74a21f8069fdc297d73dae12c332acb74d68d7cba1e337c
data/README.md CHANGED
@@ -26,6 +26,7 @@ Lita.configure do |config|
26
26
  # 30 : 赤ちゃんキャラ
27
27
  # 指定なし : デフォルトキャラ
28
28
  config.handlers.talk.docomo_character_id = 20
29
+ # config.handlers.talk.docomo_character_id = [nil, 20, 30] # at random in array
29
30
  end
30
31
  ```
31
32
 
@@ -4,7 +4,7 @@ module Lita
4
4
  module Handlers
5
5
  class Talk < Handler
6
6
  config :docomo_api_key, type: String, required: true
7
- config :docomo_character_id, type: Integer, required: false
7
+ config :docomo_character_id, required: false
8
8
 
9
9
  route(/^(.+)/, :talk, command: true, help: {
10
10
  "talk" => "Talk with you if given message didn't match any other handlers."
@@ -46,7 +46,7 @@ module Lita
46
46
  def params(context)
47
47
  {
48
48
  context: context,
49
- t: config.docomo_character_id,
49
+ t: Array(config.docomo_character_id).sample,
50
50
  }.reject do |key, value|
51
51
  value.nil?
52
52
  end
data/lita-talk.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = "lita-talk"
3
- spec.version = "0.1.4"
3
+ spec.version = "0.1.5"
4
4
  spec.authors = ["fukayatsu"]
5
5
  spec.email = ["fukayatsu@gmail.com"]
6
6
  spec.description = "Talk with you if given message didn't match any other handlers."
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lita-talk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - fukayatsu