reissue 0.4.4 → 0.4.5
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 -16
- data/README.md +12 -0
- data/Rakefile +0 -1
- data/lib/reissue/fragment_handler/git_fragment_handler.rb +6 -3
- data/lib/reissue/version.rb +1 -1
- data/lib/reissue.rb +27 -4
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: cbf7f6743d0d3f7d9cc6ae1d2daa7b60debf47a437473a01a23d18e50450b3ed
|
|
4
|
+
data.tar.gz: 545d45ca3354aa70cba0b3bb01ba5b653d62b26b6c9ee37dd4c398f1384e7fee
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: f7f3a5b754e4d9189f1ca8452510129e1b4550dcf9dba385b9d92af1e6dc2e648582d356483648f7e2a9ea766b1efec87e118a9c34def1800e2201f28997ffb9
|
|
7
|
+
data.tar.gz: dd3518eebf74b5280eca612148cb8782d591f195e4f8d7f31ba314c7e5ec109c2bcd55aecf91128ac9d22802a36f1feb63671c644835a350f041fa1ca16f1b94
|
data/CHANGELOG.md
CHANGED
|
@@ -5,28 +5,17 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](http://keepachangelog.com/)
|
|
6
6
|
and this project adheres to [Semantic Versioning](http://semver.org/).
|
|
7
7
|
|
|
8
|
-
## [0.4.
|
|
9
|
-
|
|
10
|
-
### Changed
|
|
11
|
-
|
|
12
|
-
- Derive TRAILER_REGEX from VALID_SECTIONS to eliminate duplication (32b963e)
|
|
13
|
-
- Updated example Rakefile to include version trailer configuration (4f2a254)
|
|
14
|
-
- Replace Qlty with native SimpleCov coverage reporting in CI (764d6ba)
|
|
8
|
+
## [0.4.5] - 2025-11-21
|
|
15
9
|
|
|
16
10
|
### Added
|
|
17
11
|
|
|
18
|
-
-
|
|
19
|
-
-
|
|
20
|
-
-
|
|
21
|
-
- Release flow integration documentation and verification tests (e038230)
|
|
22
|
-
- Version bumping documentation to README.md (4f2a254)
|
|
23
|
-
- Version trailer examples and usage guide (4f2a254)
|
|
24
|
-
- PR comments showing code coverage percentage and threshold status (bfa4619)
|
|
25
|
-
- ChatNotifier to update slack about CI runs (55dfeb8)
|
|
12
|
+
- NOTIFY_APP_NAME ENV var for CI runs in 5700751d (e2c75ff)
|
|
13
|
+
- Support for alphanumery patch version tag matching in 5c17ce36 (e2c75ff)
|
|
14
|
+
- Info in the README about adding trailers in development of Reissue (68117e0)
|
|
26
15
|
|
|
27
16
|
### Fixed
|
|
28
17
|
|
|
29
|
-
-
|
|
18
|
+
- Duplicate changelog entries with incorrect release dates. (1e03b68)
|
|
30
19
|
|
|
31
20
|
## [0.4.4] - 2025-10-17
|
|
32
21
|
|
data/README.md
CHANGED
|
@@ -286,6 +286,18 @@ Version trailers are case-insensitive:
|
|
|
286
286
|
|
|
287
287
|
After checking out the repo, run `bin/setup` to install dependencies. Then run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt.
|
|
288
288
|
|
|
289
|
+
### Using Git Trailers for Changelog Entries
|
|
290
|
+
|
|
291
|
+
Reissue builds its changelog from git trailers. When making commits, add trailers that adhere to the Keep a Changelog format.
|
|
292
|
+
|
|
293
|
+
```bash
|
|
294
|
+
git commit -m "Add breaking API changes
|
|
295
|
+
|
|
296
|
+
Added: New Reissue API
|
|
297
|
+
Changed: API of Reissue switched from foo to bar
|
|
298
|
+
Version: major"
|
|
299
|
+
```
|
|
300
|
+
|
|
289
301
|
## Releasing This Gem
|
|
290
302
|
|
|
291
303
|
1. Run `rake build:checksum` to build the gem and generate checksums
|
data/Rakefile
CHANGED
|
@@ -103,10 +103,13 @@ module Reissue
|
|
|
103
103
|
commits
|
|
104
104
|
end
|
|
105
105
|
|
|
106
|
+
# Find the most recent semantic version tag (v*.*.*) by tag creation date across all branches
|
|
107
|
+
# This ensures we exclude commits that are already in ANY tagged release, not just the current branch
|
|
108
|
+
# Supports both numeric (v1.2.3) and alphanumeric (v2025.10.C) version tags
|
|
109
|
+
#
|
|
110
|
+
# @return [String, nil] The most recent version tag or nil if no tags found
|
|
106
111
|
def find_last_tag
|
|
107
|
-
|
|
108
|
-
# This ensures we exclude commits that are already in ANY tagged release, not just the current branch
|
|
109
|
-
tag = `git for-each-ref --sort=-creatordate --format='%(refname:short)' 'refs/tags/v[0-9]*.[0-9]*.[0-9]*' --count=1 2>/dev/null`.strip
|
|
112
|
+
tag = `git for-each-ref --sort=-creatordate --format='%(refname:short)' 'refs/tags/v[0-9]*.[0-9]*.[a-zA-Z0-9]*' --count=1 2>/dev/null`.strip
|
|
110
113
|
tag.empty? ? nil : tag
|
|
111
114
|
end
|
|
112
115
|
|
data/lib/reissue/version.rb
CHANGED
data/lib/reissue.rb
CHANGED
|
@@ -70,13 +70,36 @@ module Reissue
|
|
|
70
70
|
unreleased_version = changelog["versions"].find { |v| v["date"] == "Unreleased" }
|
|
71
71
|
|
|
72
72
|
if unreleased_version
|
|
73
|
-
#
|
|
73
|
+
# Remove the unreleased version from the changelog to avoid duplication
|
|
74
|
+
# when we call update (which does unshift)
|
|
75
|
+
changelog["versions"].delete(unreleased_version)
|
|
76
|
+
|
|
77
|
+
# Write the modified changelog (with unreleased version removed) back to file
|
|
78
|
+
# This is necessary because update() re-parses from the file
|
|
79
|
+
changelog_updater.instance_variable_set(:@changelog, changelog)
|
|
80
|
+
changelog_updater.write(changelog_file, retain_changelogs: false)
|
|
81
|
+
|
|
82
|
+
# Get fragment changes
|
|
83
|
+
handler = FragmentHandler.for(fragment)
|
|
84
|
+
fragment_changes = handler.read
|
|
85
|
+
|
|
86
|
+
# Merge existing changes with fragment changes, deduplicating entries
|
|
87
|
+
merged_changes = (unreleased_version["changes"] || {}).dup
|
|
88
|
+
fragment_changes.each do |section, entries|
|
|
89
|
+
merged_changes[section] ||= []
|
|
90
|
+
# Only add entries that don't already exist
|
|
91
|
+
entries.each do |entry|
|
|
92
|
+
merged_changes[section] << entry unless merged_changes[section].include?(entry)
|
|
93
|
+
end
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
# Update with merged data (this will unshift the version back into the array)
|
|
74
97
|
changelog_updater.update(
|
|
75
98
|
unreleased_version["version"],
|
|
76
99
|
date: "Unreleased",
|
|
77
|
-
changes:
|
|
78
|
-
fragment:
|
|
79
|
-
version_limit: changelog["versions"].size
|
|
100
|
+
changes: merged_changes,
|
|
101
|
+
fragment: nil, # Don't read fragments again since we already merged them
|
|
102
|
+
version_limit: changelog["versions"].size + 1 # +1 because we removed one
|
|
80
103
|
)
|
|
81
104
|
changelog_updater.write(changelog_file, retain_changelogs: false)
|
|
82
105
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: reissue
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.4.
|
|
4
|
+
version: 0.4.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Jim Gay
|
|
@@ -67,7 +67,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
67
67
|
- !ruby/object:Gem::Version
|
|
68
68
|
version: '0'
|
|
69
69
|
requirements: []
|
|
70
|
-
rubygems_version: 3.
|
|
70
|
+
rubygems_version: 3.7.2
|
|
71
71
|
specification_version: 4
|
|
72
72
|
summary: Keep your versions and changelogs up to date and prepared for release.
|
|
73
73
|
test_files: []
|