lita-rally 1.2.1 → 1.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/lita/handlers/rally.rb +22 -6
- data/lita-rally.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a04824dbbaf2ac95c88a4e94eab2076060ea7ff2
|
4
|
+
data.tar.gz: 40b3282b4c2620c20a08e1bd3c4e3b126dd5e42e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2a18099cf16f8202fa98d2b938521a67abfe4ee57fa13d38940350930226ec4efcdbb0e5b99d9dff9e6f99a9afb82670b9640fc315515f962ff67de263eabc1a
|
7
|
+
data.tar.gz: 4ba8c14552b582f8759b868934e956d7bd6d4545ab1db2ecfa336070bebfeabc800f074d5a8ccb8795674aafea01ba37dfe4f68d678694939305993b2b2417d9
|
data/lib/lita/handlers/rally.rb
CHANGED
@@ -215,16 +215,32 @@ module Lita
|
|
215
215
|
end
|
216
216
|
|
217
217
|
def rally_assign(response)
|
218
|
-
|
219
|
-
|
220
|
-
|
218
|
+
if config.hipchat_token
|
219
|
+
if config.read_only
|
220
|
+
response.reply('Rally plugin is operating in Read-Only mode, ' \
|
221
|
+
'ask your chat-ops admin to disable it.')
|
222
|
+
return
|
223
|
+
end
|
224
|
+
|
225
|
+
type = response.matches[0][0].downcase
|
226
|
+
id = response.matches[0][1]
|
227
|
+
owner = response.matches[0][2]
|
221
228
|
|
222
|
-
|
229
|
+
mention = owner.nil? ? response.user.mention_name : owner
|
223
230
|
|
224
|
-
|
231
|
+
user = rally_find_user(hipchat_find_user(mention))
|
225
232
|
|
226
|
-
|
233
|
+
response.reply(update_object(type, id, 'owner', user, options = {}))
|
227
234
|
|
235
|
+
update_object(type, id, 'Notes',
|
236
|
+
"<br />assigned ownership to #{user} by " \
|
237
|
+
"#{response.user.name} on " \
|
238
|
+
"#{Time.now.strftime('%Y-%m-%dT%H:%M:%S%z')}",
|
239
|
+
append: true)
|
240
|
+
else
|
241
|
+
response.reply('This is a HipChat only function, please provide '\
|
242
|
+
'hipchat_token to use this function.')
|
243
|
+
end
|
228
244
|
rescue Exception => e
|
229
245
|
response.reply("Error during assignment: #{e}")
|
230
246
|
end
|
data/lita-rally.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lita-rally
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Richard Li
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-09-
|
11
|
+
date: 2015-09-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: lita
|