changelog-notifier 1.5.0 → 1.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 +4 -4
- data/CHANGELOG.md +5 -2
- data/Gemfile.lock +1 -1
- data/lib/changelog/notifier/adapters/active_record.rb +4 -0
- data/lib/changelog/notifier/adapters/base.rb +4 -0
- data/lib/changelog/notifier/adapters/slack.rb +4 -0
- data/lib/changelog/notifier/entrypoints/capistrano.rb +6 -2
- data/lib/changelog/notifier/version.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 154e3876df8735262e4d2cf193e53085ea4aae8cc95f0b978278d1ccdf167099
|
|
4
|
+
data.tar.gz: e5ea0010059b2f2ddaa0cfed90f8ace817c30331e01ecba84238a6087fe27cf9
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ca82865286d8ccb44100d257b819e40a46757450d07218c20b2018caaeaab6148204397960adaa104624ade8eba1850ae050b87d028bb06b971dd5a266d1c945
|
|
7
|
+
data.tar.gz: 7cb19c2999a972ecc5d7507d77d0306aaeccf8ab40c92213bf3f67b63152633f704b1e1c40793b8fa9d5ca41385795736e12cc4a50ca909c965fdaa00bcdee0a
|
data/CHANGELOG.md
CHANGED
|
@@ -6,7 +6,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
## [1.5.1] - 2021-05-25
|
|
10
|
+
### Fixed
|
|
11
|
+
- Prevents calling the `publish!` adapter's method with unconfigured adapters
|
|
10
12
|
|
|
11
13
|
## [1.5.0] - 2020-10-18
|
|
12
14
|
### Added
|
|
@@ -40,7 +42,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
40
42
|
- Slack adapter to post the changelog to a Slack channel
|
|
41
43
|
- Slack formatter
|
|
42
44
|
|
|
43
|
-
[Unreleased]: https://gitlab.com/zedtux/changelog-notifier/-/compare/v1.5.
|
|
45
|
+
[Unreleased]: https://gitlab.com/zedtux/changelog-notifier/-/compare/v1.5.1...master
|
|
46
|
+
[1.5.1]: https://gitlab.com/zedtux/changelog-notifier/-/compare/v1.5.0...v1.5.1
|
|
44
47
|
[1.5.0]: https://gitlab.com/zedtux/changelog-notifier/-/compare/v1.4.0...v1.5.0
|
|
45
48
|
[1.4.0]: https://gitlab.com/zedtux/changelog-notifier/-/compare/v1.3.0...v1.4.0
|
|
46
49
|
[1.3.0]: https://gitlab.com/zedtux/changelog-notifier/-/compare/v1.2.0...v1.3.0
|
data/Gemfile.lock
CHANGED
|
@@ -7,6 +7,10 @@ module Changelog
|
|
|
7
7
|
# Creates an ActiveRecord with the changelog
|
|
8
8
|
#
|
|
9
9
|
class ActiveRecord < Base
|
|
10
|
+
def configured?
|
|
11
|
+
@model.to_s.empty? == false
|
|
12
|
+
end
|
|
13
|
+
|
|
10
14
|
def publish!(release_note_hash, version)
|
|
11
15
|
formatted_release_note = format_release_note_hash(release_note_hash)
|
|
12
16
|
|
|
@@ -9,6 +9,10 @@ module Changelog
|
|
|
9
9
|
# Slack adapter sends the release note in a Slack channel.
|
|
10
10
|
#
|
|
11
11
|
class Slack < Base
|
|
12
|
+
def configured?
|
|
13
|
+
@webhook_url.to_s.empty? == false
|
|
14
|
+
end
|
|
15
|
+
|
|
12
16
|
def publish!(release_note_hash, version)
|
|
13
17
|
formatted_release_note = format_release_note_hash(release_note_hash)
|
|
14
18
|
|
|
@@ -100,8 +100,12 @@ module Changelog
|
|
|
100
100
|
[
|
|
101
101
|
Changelog::Notifier::Adapters::ActiveRecord,
|
|
102
102
|
Changelog::Notifier::Adapters::Slack
|
|
103
|
-
].each do |
|
|
104
|
-
adapter.new(@capistrano)
|
|
103
|
+
].each do |adapter_class|
|
|
104
|
+
adapter = adapter_class.new(@capistrano)
|
|
105
|
+
|
|
106
|
+
next unless adapter.configured?
|
|
107
|
+
|
|
108
|
+
adapter.publish!(@release_note_hash, @version)
|
|
105
109
|
end
|
|
106
110
|
rescue StandardError => error
|
|
107
111
|
@capistrano.error error.message
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: changelog-notifier
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.5.
|
|
4
|
+
version: 1.5.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Guillaume Hain
|
|
8
|
-
autorequire:
|
|
8
|
+
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2021-05-25 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: titleize
|
|
@@ -70,7 +70,7 @@ metadata:
|
|
|
70
70
|
homepage_uri: https://gitlab.com/zedtux/changelog-notifier
|
|
71
71
|
source_code_uri: https://gitlab.com/zedtux/changelog-notifier
|
|
72
72
|
changelog_uri: https://gitlab.com/zedtux/changelog-notifier/-/blob/master/CHANGELOG.md
|
|
73
|
-
post_install_message:
|
|
73
|
+
post_install_message:
|
|
74
74
|
rdoc_options: []
|
|
75
75
|
require_paths:
|
|
76
76
|
- lib
|
|
@@ -85,8 +85,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
85
85
|
- !ruby/object:Gem::Version
|
|
86
86
|
version: '0'
|
|
87
87
|
requirements: []
|
|
88
|
-
rubygems_version: 3.
|
|
89
|
-
signing_key:
|
|
88
|
+
rubygems_version: 3.1.4
|
|
89
|
+
signing_key:
|
|
90
90
|
specification_version: 4
|
|
91
91
|
summary: Sends current version's release note from your CHANGELOG.md file
|
|
92
92
|
test_files: []
|