gitlab-triage 1.5.1 → 1.6.0

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
  SHA256:
3
- metadata.gz: de0347bbfc948ca99ab50f995b8805d56736ea54c56bc82ef5b1e9f39369790b
4
- data.tar.gz: 7a4dfc4c621ea20b443f0fbb60ff324f0290a3fdd145a769725494842f05e0d3
3
+ metadata.gz: 85ef311a9c0950dacc0823958bf5a5a61ead1dbc6696599d5a9c1ed9d1cc5ca7
4
+ data.tar.gz: 421ccd2c8d050659990ad07a8493d23bac378224acd94f47997cfaeec3633b04
5
5
  SHA512:
6
- metadata.gz: ae9a12b596fdc6de6d0233093e741cd7ac62ff53872022e526bd102170a79efcef53b49d1bfe063470792df3d1110092547269a5f8cb19ef902751f09b36c80b
7
- data.tar.gz: 10bca6b0176b666cf4eff2faa75e11fc0554099bbdb0e1293f970f497edc4bbb532c773cf425fac6d4c9279274af3c65b2573b8d6d977b024da42698f34d35e6
6
+ metadata.gz: 706a9954e233b3a7c427068194e25a998fd193fd6373f5d82ad2f152935c2ca9ec16fd61301c687fac057b4972ccadfcc34bc52d44821494bd908cd5eae32b6e
7
+ data.tar.gz: 639d905c6dce18d3d1af351897a05800e4cb708a7673dc325887d0b38a58d62c54dc85afdf084705ec713ec9d3d9c06273fc7b8afce5e8644a3fada7193b5d2b
data/README.md CHANGED
@@ -841,15 +841,16 @@ Here's a list of currently available Ruby expression API:
841
841
 
842
842
  ##### API
843
843
 
844
- | Name | Return type | Description |
845
- | ---- | ---- | ---- |
846
- | resource | Hash | The hash containing the raw data of the resource |
847
- | milestone | Milestone | The milestone attached to the resource |
848
- | labels | [Label] | A list of labels, having only names |
849
- | labels_with_details | [Label] | A list of labels which has more information loaded from another API request |
850
- | labels_chronologically | [Label] | Same as `labels_with_details` but sorted chronologically |
851
- | label_events | [LabelEvent] | A list of label events on the resource |
852
- | instance_version | InstanceVersion | The version for the GitLab instance we're triaging with |
844
+ | Name | Return type | Description |
845
+ | ---- | ---- | ---- |
846
+ | resource | Hash | The hash containing the raw data of the resource |
847
+ | author | String | The username of the resource author |
848
+ | milestone | Milestone | The milestone attached to the resource |
849
+ | labels | [Label] | A list of labels, having only names |
850
+ | labels_with_details | [Label] | A list of labels which has more information loaded from another API request |
851
+ | labels_chronologically | [Label] | Same as `labels_with_details` but sorted chronologically |
852
+ | label_events | [LabelEvent] | A list of label events on the resource |
853
+ | instance_version | InstanceVersion | The version for the GitLab instance we're triaging with |
853
854
 
854
855
  ##### Methods for `Milestone`
855
856
 
@@ -45,6 +45,10 @@ module Gitlab
45
45
  @labels_chronologically ||= labels_with_details.sort_by(&:added_at)
46
46
  end
47
47
 
48
+ def author
49
+ @author ||= resource.dig(:author, :username)
50
+ end
51
+
48
52
  def root_id(
49
53
  resource: source_resource,
50
54
  max_levels: MAX_PARENT_LOOKUP)
@@ -1,5 +1,5 @@
1
1
  module Gitlab
2
2
  module Triage
3
- VERSION = '1.5.1'.freeze
3
+ VERSION = '1.6.0'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitlab-triage
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.1
4
+ version: 1.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - GitLab
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-01-17 00:00:00.000000000 Z
11
+ date: 2020-01-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -210,7 +210,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
210
210
  - !ruby/object:Gem::Version
211
211
  version: '0'
212
212
  requirements: []
213
- rubygems_version: 3.0.6
213
+ rubygems_version: 3.0.3
214
214
  signing_key:
215
215
  specification_version: 4
216
216
  summary: GitLab triage automation project.