gitlab_mr_release 1.1.2 → 2.0.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: fce9fdb5d70a8f372a0d8ee7848a5b553062630bc256864dec6e03b04a3bc160
4
- data.tar.gz: 7907f2ceb6b0113726f6228017cab3c4a4a1780f6afdc1bee2e2a02b8c149bde
3
+ metadata.gz: c2f4a0396800f251c595125267b28509027006d975da9698a030b1c5354d4c08
4
+ data.tar.gz: 5429ca601e5a9f2f531ef79d41d4d7754aa34a76caa154fdea74ca33811396e9
5
5
  SHA512:
6
- metadata.gz: 77964b63d42c89d65a4edffb46438c86cc2f709afb5c4105180b03148ce6b7c4447cde6546883ddd808ae497c45adbe8453d7afd56bbb7ef2638a92bde9b5aa7
7
- data.tar.gz: 620b5d8a6244118c48125568b9cc0ae530d0000a05bc206c86ced8fd0b2f8a534dc7df6ac2dd7d1516fa44c7ccf0771671d833567da58284aaf1e3bb3b01448c
6
+ metadata.gz: c239c2b79072f418fda4a22c5ade4c3cd12499278a59a5fb46291efa6dcd6098fc24230b3518405405a358f91bc29bee4ac0de822126c66bf331a808cd2b975c
7
+ data.tar.gz: 43bf4dca0a6fdef7f790bdaf2e2c6e691cb6b5516fd2e5a875a270ca9c6876fd252c5fef56f804695781e1ec6ed2e783722fa1bc54feda15a7ff5eac13bae0a6
@@ -0,0 +1,12 @@
1
+ # c.f. https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
2
+ version: 2
3
+
4
+ updates:
5
+ - package-ecosystem: github-actions
6
+ directory: /
7
+ schedule:
8
+ interval: weekly
9
+ cooldown:
10
+ default-days: 7
11
+ assignees:
12
+ - sue445
@@ -0,0 +1,59 @@
1
+ # Simple workflow for deploying static content to GitHub Pages
2
+ name: Deploy static content to Pages
3
+
4
+ on:
5
+ # Runs on pushes targeting the default branch
6
+ push:
7
+ branches:
8
+ - master
9
+
10
+ # Allows you to run this workflow manually from the Actions tab
11
+ workflow_dispatch:
12
+
13
+ # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
14
+ permissions:
15
+ contents: read
16
+ pages: write
17
+ id-token: write
18
+
19
+ # Allow one concurrent deployment
20
+ concurrency:
21
+ group: "pages"
22
+ cancel-in-progress: true
23
+
24
+ jobs:
25
+ # Single deploy job since we're just deploying
26
+ deploy:
27
+ environment:
28
+ name: github-pages
29
+ url: ${{ steps.deployment.outputs.page_url }}
30
+ runs-on: ubuntu-latest
31
+ steps:
32
+ - name: Checkout
33
+ uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5.0.1
34
+
35
+ - uses: ruby/setup-ruby@8aeb6ff8030dd539317f8e1769a044873b56ea71 # v1.268.0
36
+ with:
37
+ ruby-version: ruby
38
+ bundler-cache: true
39
+
40
+ - run: bundle exec yard
41
+
42
+ - name: Setup Pages
43
+ uses: actions/configure-pages@983d7736d9b0ae728b81ab479565c72886d7745b # v5.0.0
44
+ - name: Upload artifact
45
+ uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4.0.0
46
+ with:
47
+ # Upload entire repository
48
+ path: './doc'
49
+ - name: Deploy to GitHub Pages
50
+ id: deployment
51
+ uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4.0.5
52
+
53
+ - name: Slack Notification (not success)
54
+ uses: act10ns/slack@cfcc30955fe9377f4f55e1079e5419ee1014269f # v2
55
+ if: "! success()"
56
+ continue-on-error: true
57
+ with:
58
+ status: ${{ job.status }}
59
+ webhook-url: ${{ secrets.SLACK_WEBHOOK }}
@@ -0,0 +1,41 @@
1
+ name: Publish gem to rubygems.org
2
+
3
+ on:
4
+ workflow_dispatch:
5
+
6
+ jobs:
7
+ release:
8
+ if: github.repository == 'sue445/gitlab_mr_release'
9
+ runs-on: ubuntu-latest
10
+
11
+ environment:
12
+ name: rubygems.org
13
+ url: https://rubygems.org/gems/gitlab_mr_release
14
+
15
+ permissions:
16
+ contents: write
17
+ id-token: write
18
+
19
+ steps:
20
+ - name: Harden Runner
21
+ uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
22
+ with:
23
+ egress-policy: audit
24
+
25
+ - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
26
+
27
+ - name: Set up Ruby
28
+ uses: ruby/setup-ruby@eaecf785f6a34567a6d97f686bbb7bccc1ac1e5c # v1.237.0
29
+ with:
30
+ bundler-cache: true
31
+ ruby-version: ruby
32
+
33
+ - name: Publish to RubyGems
34
+ uses: rubygems/release-gem@a25424ba2ba8b387abc8ef40807c2c85b96cbe32 # v1.1.1
35
+
36
+ - name: Create GitHub release
37
+ run: |
38
+ tag_name="$(git describe --tags --abbrev=0)"
39
+ gh release create "${tag_name}" --verify-tag --generate-notes
40
+ env:
41
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -16,78 +16,55 @@ jobs:
16
16
  test:
17
17
  runs-on: ubuntu-latest
18
18
 
19
- container: ${{ matrix.ruby }}
20
-
21
19
  strategy:
22
20
  fail-fast: false
23
21
 
24
22
  matrix:
25
23
  ruby:
26
- - ruby:2.2
27
- - ruby:2.3
28
- - ruby:2.4
29
- - ruby:2.5
30
- - ruby:2.6
31
- - ruby:2.7
32
- - ruby:3.0
33
- - rubylang/ruby:master-nightly-bionic
34
- include:
35
- - ruby: rubylang/ruby:master-nightly-bionic
36
- allow_failures: "true"
24
+ - "2.6"
25
+ - "2.7"
26
+ - "3.0"
27
+ - "3.1"
28
+ - "3.2"
29
+ - "3.3"
30
+ - "3.4"
37
31
 
38
32
  steps:
39
- - uses: actions/checkout@v2
33
+ - uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5.0.1
40
34
 
41
- - name: Cache vendor/bundle
42
- uses: actions/cache@v1
43
- id: cache_gem
35
+ - uses: ruby/setup-ruby@8aeb6ff8030dd539317f8e1769a044873b56ea71 # v1.268.0
44
36
  with:
45
- path: vendor/bundle
46
- key: v1-gem-${{ runner.os }}-${{ matrix.ruby }}-${{ github.sha }}
47
- restore-keys: |
48
- v1-gem-${{ runner.os }}-${{ matrix.ruby }}-
49
- continue-on-error: ${{ matrix.allow_failures == 'true' }}
37
+ ruby-version: ${{ matrix.ruby }}
38
+ bundler-cache: true
50
39
 
51
- - name: bundle update
52
- run: |
53
- set -xe
54
- bundle config path vendor/bundle
55
- bundle update --jobs $(nproc) --retry 3
56
- continue-on-error: ${{ matrix.allow_failures == 'true' }}
40
+ - run: bundle update --jobs $(nproc) --retry 3
57
41
 
58
42
  - name: Setup Code Climate Test Reporter
59
- uses: aktions/codeclimate-test-reporter@v1
43
+ uses: aktions/codeclimate-test-reporter@7634aa9ac7883182f583f15ff7b6ff519939dd0a # v1.2.0
60
44
  with:
61
45
  codeclimate-test-reporter-id: ${{ secrets.CC_TEST_REPORTER_ID }}
62
46
  command: before-build
63
- if: matrix.ruby >= 'ruby:2.4'
64
47
  continue-on-error: true
65
48
 
66
- - name: Run test
67
- run: |
68
- set -xe
69
- bundle exec rspec
70
- continue-on-error: ${{ matrix.allow_failures == 'true' }}
49
+ - run: bundle exec rspec
71
50
  timeout-minutes: 1
72
51
 
73
52
  - name: Teardown Code Climate Test Reporter
74
- uses: aktions/codeclimate-test-reporter@v1
53
+ uses: aktions/codeclimate-test-reporter@7634aa9ac7883182f583f15ff7b6ff519939dd0a # v1.2.0
75
54
  with:
76
55
  codeclimate-test-reporter-id: ${{ secrets.CC_TEST_REPORTER_ID }}
77
56
  command: after-build
78
- if: matrix.ruby >= 'ruby:2.4' && always()
57
+ if: always()
79
58
  continue-on-error: true
80
59
 
81
60
  - name: Slack Notification (not success)
82
- uses: lazy-actions/slatify@master
61
+ uses: act10ns/slack@cfcc30955fe9377f4f55e1079e5419ee1014269f # v2
83
62
  if: "! success()"
84
63
  continue-on-error: true
85
64
  with:
86
- job_name: ${{ format('*build* ({0})', matrix.ruby) }}
87
- type: ${{ job.status }}
88
- icon_emoji: ":octocat:"
89
- url: ${{ secrets.SLACK_WEBHOOK }}
90
- token: ${{ secrets.GITHUB_TOKEN }}
65
+ status: ${{ job.status }}
66
+ webhook-url: ${{ secrets.SLACK_WEBHOOK }}
67
+ matrix: ${{ toJson(matrix) }}
91
68
 
92
69
  notify:
93
70
  needs:
@@ -97,12 +74,9 @@ jobs:
97
74
 
98
75
  steps:
99
76
  - name: Slack Notification (success)
100
- uses: lazy-actions/slatify@master
77
+ uses: act10ns/slack@cfcc30955fe9377f4f55e1079e5419ee1014269f # v2
101
78
  if: always()
102
79
  continue-on-error: true
103
80
  with:
104
- job_name: '*build*'
105
- type: ${{ job.status }}
106
- icon_emoji: ":octocat:"
107
- url: ${{ secrets.SLACK_WEBHOOK }}
108
- token: ${{ secrets.GITHUB_TOKEN }}
81
+ status: ${{ job.status }}
82
+ webhook-url: ${{ secrets.SLACK_WEBHOOK }}
data/.yardopts ADDED
@@ -0,0 +1,2 @@
1
+ --markup markdown
2
+ --no-private
data/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  ## Unreleased
2
- [full changelog](http://github.com/sue445/gitlab_mr_release/compare/v1.1.2...master)
2
+ [full changelog](http://github.com/sue445/gitlab_mr_release/compare/v2.0.1...master)
3
+
4
+ ## [v2.0.1](https://github.com/sue445/gitlab_mr_release/releases/tag/v2.0.1)
5
+ [full changelog](http://github.com/sue445/gitlab_mr_release/compare/v2.0.0...v2.0.1)
6
+
7
+ * Release gem from GitHub Actions
8
+ * https://github.com/sue445/gitlab_mr_release/pull/92
9
+
10
+ ## v2.0.0
11
+ [full changelog](http://github.com/sue445/gitlab_mr_release/compare/v1.1.2...v2.0.0)
12
+
13
+ * Fix deprecation warning at `ERB.new` and requires Ruby 2.6+
14
+ * https://github.com/sue445/gitlab_mr_release/pull/84
3
15
 
4
16
  ## v1.1.2
5
17
  [full changelog](http://github.com/sue445/gitlab_mr_release/compare/v1.1.1...v1.1.2)
data/Gemfile CHANGED
@@ -3,25 +3,7 @@ source 'https://rubygems.org'
3
3
  # Specify your gem's dependencies in gitlab_mr_release.gemspec
4
4
  gemspec
5
5
 
6
- if Gem::Version.create(RUBY_VERSION) < Gem::Version.create("2.2.2")
7
- group :development do
8
- # NOTE: activesupport 5.x supports only ruby 2.2.2+
9
- gem "activesupport", "< 5.0.0", group: :test
10
- end
11
- end
12
-
13
- if Gem::Version.create(RUBY_VERSION) < Gem::Version.create("2.3.0")
14
- # NOTE: httparty v0.19.0+ requires Ruby 2.3+
15
- gem "httparty", "< 0.19.0"
16
- end
17
-
18
- if Gem::Version.create(RUBY_VERSION) < Gem::Version.create("2.5.0")
19
- # NOTE: unparser v0.3.0+ requires Ruby 2.5+
20
- gem "unparser", "< 0.3.0"
21
- end
22
-
23
- if Gem::Version.create(RUBY_VERSION) < Gem::Version.create("2.4.0")
24
- # String#unpack1 is available since ruby 2.4, but gitlab gem uses String#unpack1 ...
25
- # c.f. https://github.com/NARKOZ/gitlab/commit/d9ef580#diff-84e3ba49bf244c6684f7d26a3312adc4R81
26
- gem "gitlab", "< 4.14.0"
6
+ if Gem::Version.create(RUBY_VERSION) < Gem::Version.create("2.7.0")
7
+ # term-ansicolor 1.9.0+ doesn't work on Ruby < 2.7
8
+ gem "term-ansicolor", "< 1.9.0"
27
9
  end
data/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  Release MergeRequest generator for [GitLab](https://about.gitlab.com/)
4
4
 
5
5
  [![Gem Version](https://badge.fury.io/rb/gitlab_mr_release.svg)](https://badge.fury.io/rb/gitlab_mr_release)
6
- [![Build Status](https://github.com/sue445/gitlab_mr_release/workflows/test/badge.svg?branch=master)](https://github.com/sue445/gitlab_mr_release/actions?query=workflow%3Atest)
6
+ [![test](https://github.com/sue445/gitlab_mr_release/actions/workflows/test.yml/badge.svg)](https://github.com/sue445/gitlab_mr_release/actions/workflows/test.yml)
7
7
  [![Code Climate](https://codeclimate.com/github/sue445/gitlab_mr_release/badges/gpa.svg)](https://codeclimate.com/github/sue445/gitlab_mr_release)
8
8
  [![Coverage Status](https://coveralls.io/repos/sue445/gitlab_mr_release/badge.svg?branch=master&service=github)](https://coveralls.io/github/sue445/gitlab_mr_release?branch=master)
9
9
 
@@ -11,7 +11,7 @@ This is inspired by the [git-pr-release](https://github.com/motemen/git-pr-relea
11
11
 
12
12
  ## Requirements
13
13
 
14
- * Ruby v2.1+
14
+ * Ruby v2.6+
15
15
  * GitLab v8.17.0+
16
16
  * GitLab API v4+
17
17
 
@@ -14,9 +14,12 @@ Gem::Specification.new do |spec|
14
14
  spec.homepage = "https://github.com/sue445/gitlab_mr_release"
15
15
  spec.license = "MIT"
16
16
 
17
+ spec.required_ruby_version = ">= 2.6.0"
18
+
17
19
  spec.metadata["homepage_uri"] = spec.homepage
18
20
  spec.metadata["source_code_uri"] = spec.homepage
19
21
  spec.metadata["changelog_uri"] = "#{spec.homepage}/blob/master/CHANGELOG.md"
22
+ spec.metadata["documentation_uri"] = "https://sue445.github.io/gitlab_mr_release/"
20
23
  spec.metadata["rubygems_mfa_required"] = "true"
21
24
 
22
25
  spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
@@ -30,11 +33,12 @@ Gem::Specification.new do |spec|
30
33
 
31
34
  spec.add_development_dependency "activesupport"
32
35
  spec.add_development_dependency "bundler", ">= 1.10"
33
- spec.add_development_dependency "coveralls"
36
+ spec.add_development_dependency "ostruct"
34
37
  spec.add_development_dependency "rake"
35
38
  spec.add_development_dependency "rspec"
36
39
  spec.add_development_dependency "rspec-parameterized"
37
- spec.add_development_dependency "simplecov"
40
+ spec.add_development_dependency "term-ansicolor", "!= 1.11.1" # ref. https://github.com/flori/term-ansicolor/issues/41
38
41
  spec.add_development_dependency "unparser", ">= 0.4.5"
39
42
  spec.add_development_dependency "webmock", ">= 3.0.0"
43
+ spec.add_development_dependency "yard"
40
44
  end
@@ -37,7 +37,7 @@ module GitlabMrRelease
37
37
 
38
38
  def generate_description(iids, template)
39
39
  merge_requests = Gitlab.merge_requests(@project_name, iids: iids)
40
- ERB.new(template, nil, "-").result(binding).strip
40
+ ERB.new(template, trim_mode: "-").result(binding).strip
41
41
  end
42
42
 
43
43
  def create_merge_request(source_branch:, target_branch:, title:, template:, labels:)
@@ -1,3 +1,3 @@
1
1
  module GitlabMrRelease
2
- VERSION = "1.1.2"
2
+ VERSION = "2.0.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitlab_mr_release
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - sue445
8
- autorequire:
9
8
  bindir: exe
10
9
  cert_chain: []
11
- date: 2021-11-19 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: dotenv
@@ -81,7 +80,7 @@ dependencies:
81
80
  - !ruby/object:Gem::Version
82
81
  version: '1.10'
83
82
  - !ruby/object:Gem::Dependency
84
- name: coveralls
83
+ name: ostruct
85
84
  requirement: !ruby/object:Gem::Requirement
86
85
  requirements:
87
86
  - - ">="
@@ -137,19 +136,19 @@ dependencies:
137
136
  - !ruby/object:Gem::Version
138
137
  version: '0'
139
138
  - !ruby/object:Gem::Dependency
140
- name: simplecov
139
+ name: term-ansicolor
141
140
  requirement: !ruby/object:Gem::Requirement
142
141
  requirements:
143
- - - ">="
142
+ - - "!="
144
143
  - !ruby/object:Gem::Version
145
- version: '0'
144
+ version: 1.11.1
146
145
  type: :development
147
146
  prerelease: false
148
147
  version_requirements: !ruby/object:Gem::Requirement
149
148
  requirements:
150
- - - ">="
149
+ - - "!="
151
150
  - !ruby/object:Gem::Version
152
- version: '0'
151
+ version: 1.11.1
153
152
  - !ruby/object:Gem::Dependency
154
153
  name: unparser
155
154
  requirement: !ruby/object:Gem::Requirement
@@ -178,6 +177,20 @@ dependencies:
178
177
  - - ">="
179
178
  - !ruby/object:Gem::Version
180
179
  version: 3.0.0
180
+ - !ruby/object:Gem::Dependency
181
+ name: yard
182
+ requirement: !ruby/object:Gem::Requirement
183
+ requirements:
184
+ - - ">="
185
+ - !ruby/object:Gem::Version
186
+ version: '0'
187
+ type: :development
188
+ prerelease: false
189
+ version_requirements: !ruby/object:Gem::Requirement
190
+ requirements:
191
+ - - ">="
192
+ - !ruby/object:Gem::Version
193
+ version: '0'
181
194
  description: Release MergeRequest generator for GitLab
182
195
  email:
183
196
  - sue445@sue445.net
@@ -186,11 +199,14 @@ executables:
186
199
  extensions: []
187
200
  extra_rdoc_files: []
188
201
  files:
189
- - ".coveralls.yml"
190
202
  - ".env.gitlab.example"
203
+ - ".github/dependabot.yml"
204
+ - ".github/workflows/pages.yml"
205
+ - ".github/workflows/release_gem.yml"
191
206
  - ".github/workflows/test.yml"
192
207
  - ".gitignore"
193
208
  - ".rspec"
209
+ - ".yardopts"
194
210
  - CHANGELOG.md
195
211
  - Gemfile
196
212
  - LICENSE.txt
@@ -214,8 +230,8 @@ metadata:
214
230
  homepage_uri: https://github.com/sue445/gitlab_mr_release
215
231
  source_code_uri: https://github.com/sue445/gitlab_mr_release
216
232
  changelog_uri: https://github.com/sue445/gitlab_mr_release/blob/master/CHANGELOG.md
233
+ documentation_uri: https://sue445.github.io/gitlab_mr_release/
217
234
  rubygems_mfa_required: 'true'
218
- post_install_message:
219
235
  rdoc_options: []
220
236
  require_paths:
221
237
  - lib
@@ -223,15 +239,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
223
239
  requirements:
224
240
  - - ">="
225
241
  - !ruby/object:Gem::Version
226
- version: '0'
242
+ version: 2.6.0
227
243
  required_rubygems_version: !ruby/object:Gem::Requirement
228
244
  requirements:
229
245
  - - ">="
230
246
  - !ruby/object:Gem::Version
231
247
  version: '0'
232
248
  requirements: []
233
- rubygems_version: 3.2.22
234
- signing_key:
249
+ rubygems_version: 3.6.7
235
250
  specification_version: 4
236
251
  summary: Release MergeRequest generator for GitLab
237
252
  test_files: []
data/.coveralls.yml DELETED
@@ -1 +0,0 @@
1
- repo_token: pA8VrMwrNTyChkaDFsIF08GmfC4a0jIz2