gitlab-dangerfiles 4.3.2 → 4.5.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
  SHA256:
3
- metadata.gz: d65ff64b94d8714d7a5bb9cf9ebe203d13fcffbc88fe46a093d1f8b1c9921298
4
- data.tar.gz: 86599baa81ee6c00f2bd624ae661f284a38b0b98d0ad64779aa22383816edfce
3
+ metadata.gz: 3371fdf6ddb99f838b75a15726a1750b14f9b56537949c86caae8b9345b9569d
4
+ data.tar.gz: 18eb20e9a7b43ab2b2556cd2a59ae344af3d11a5c003e76ca5fd4a5a5d819331
5
5
  SHA512:
6
- metadata.gz: afc88dc14df24c36463b973803d8ea9026ff35fba9e3e0031b129c3752b10d740d09ebad208fd724e001720f0d11765159fc756d9760c3b64ccfc0abc79b05f7
7
- data.tar.gz: 421b62b93d8a5800f6ab6bbc654df8369ab26788d877a748ce5bd15122bde896c5155a290004cd948c23d4e8643f3f5307c7e9503c7d61f0b8b49a46a5112c01
6
+ metadata.gz: ba10efb103ab0c9355e102de004d512918fb558e6e3a486b1adcc609a9d4b083f714d33b5e595b3f2a210dec8be934bb4d0df3bb9f8d46c95c4557407f79f481
7
+ data.tar.gz: c37a12218910f95359591f91509d99f61e230ecd3022d4886ff03635cddf8455c34bf045a15438e50bdf2688e7f5eafe206a8a2735a08adb13397d4a2eb8491d
data/.gitlab-ci.yml CHANGED
@@ -2,6 +2,9 @@ stages:
2
2
  - test
3
3
  - deploy
4
4
 
5
+ variables:
6
+ DEFAULT_CI_IMAGE: "ruby:${RUBY_VERSION}"
7
+
5
8
  workflow:
6
9
  rules:
7
10
  # For merge requests, create a pipeline.
@@ -11,8 +14,8 @@ workflow:
11
14
  # For tags, create a pipeline.
12
15
  - if: '$CI_COMMIT_TAG'
13
16
 
14
- .default:
15
- image: "ruby:${RUBY_VERSION}"
17
+ default:
18
+ image: "${DEFAULT_CI_IMAGE}"
16
19
  tags:
17
20
  - gitlab-org
18
21
  before_script:
@@ -28,25 +31,22 @@ workflow:
28
31
  - Gemfile.lock
29
32
  policy: pull
30
33
 
31
- test:rspec:
32
- extends: .default
34
+ .default-test-job:
33
35
  stage: test
34
- script:
35
- - bundle exec rspec
36
- # On MRs, ensure that danger works without development dependencies
37
- - '[ -z "$CI_MERGE_REQUEST_IID" ] || BUNDLE_ONLY=default bundle exec danger dry_run'
36
+ needs: []
38
37
  parallel:
39
38
  matrix:
40
39
  - RUBY_VERSION: ['3.0', '3.1', '3.2']
41
40
 
41
+ test:rspec:
42
+ extends: .default-test-job
43
+ script:
44
+ - bundle exec rspec
45
+
42
46
  test:rubocop:
43
- extends: .default
44
- stage: test
47
+ extends: .default-test-job
45
48
  script:
46
49
  - bundle exec rubocop -P -E .
47
- parallel:
48
- matrix:
49
- - RUBY_VERSION: ['3.0', '3.1', '3.2']
50
50
 
51
51
  include:
52
52
  - template: Security/Dependency-Scanning.gitlab-ci.yml
@@ -55,7 +55,9 @@ include:
55
55
  - project: 'gitlab-org/quality/pipeline-common'
56
56
  file:
57
57
  - '/ci/danger-review.yml'
58
- - '/ci/gem-release.yml'
58
+ - component: "gitlab.com/gitlab-org/quality/pipeline-common/gem-release@7.6.1"
59
+ inputs:
60
+ smoke_test_script: "ruby -r 'gitlab-dangerfiles' -e \"puts Gitlab::Dangerfiles::VERSION\""
59
61
 
60
62
  # run security jobs on MRs
61
63
  # see: https://gitlab.com/gitlab-org/gitlab/-/issues/218444#note_478761991
@@ -90,7 +90,7 @@ module Gitlab
90
90
  private
91
91
 
92
92
  def default_markdown_name(username)
93
- "[`#{username}`](https://gitlab.com/#{username})"
93
+ "`@#{username}` [![profile link](https://gitlab.com/gitlab-org/gitlab-svgs/-/raw/main/sprite_icons/user.svg?ref_type=heads)](https://gitlab.com/#{username})"
94
94
  end
95
95
 
96
96
  def process_projects(projects)
@@ -119,12 +119,12 @@ module Gitlab
119
119
 
120
120
  def offset_diff_compared_to_author(author)
121
121
  diff = floored_offset_hours - author.floored_offset_hours
122
- return "same timezone as `@#{author.username}`" if diff == 0
122
+ return "same timezone as author" if diff == 0
123
123
 
124
124
  ahead_or_behind = diff < 0 ? "behind" : "ahead of"
125
125
  pluralized_hours = pluralize(diff.abs, "hour", "hours")
126
126
 
127
- "#{pluralized_hours} #{ahead_or_behind} `@#{author.username}`"
127
+ "#{pluralized_hours} #{ahead_or_behind} author"
128
128
  end
129
129
 
130
130
  def has_capability?(project, category, kind, labels)
@@ -1,5 +1,5 @@
1
1
  module Gitlab
2
2
  module Dangerfiles
3
- VERSION = "4.3.2"
3
+ VERSION = "4.5.1"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitlab-dangerfiles
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.3.2
4
+ version: 4.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - GitLab
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-10-13 00:00:00.000000000 Z
11
+ date: 2023-10-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -263,7 +263,7 @@ metadata:
263
263
  homepage_uri: https://gitlab.com/gitlab-org/ruby/gems/gitlab-dangerfiles
264
264
  source_code_uri: https://gitlab.com/gitlab-org/ruby/gems/gitlab-dangerfiles
265
265
  changelog_uri: https://gitlab.com/gitlab-org/ruby/gems/gitlab-dangerfiles/-/releases
266
- post_install_message:
266
+ post_install_message:
267
267
  rdoc_options: []
268
268
  require_paths:
269
269
  - lib
@@ -278,8 +278,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
278
278
  - !ruby/object:Gem::Version
279
279
  version: '0'
280
280
  requirements: []
281
- rubygems_version: 3.1.6
282
- signing_key:
281
+ rubygems_version: 3.3.26
282
+ signing_key:
283
283
  specification_version: 4
284
284
  summary: This gem provides common Dangerfile and plugins for GitLab projects.
285
285
  test_files: []