semantic_release 1.2.1 → 1.3.0

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: ab408baff3b214c64b1c2ceabc4d2b89cbd36fb6e22d1fd9fcc24eba17e9f67b
4
- data.tar.gz: 161db6943eb86f2109286e52fc561d1c309a25fcf15af87f2d771d306782c428
3
+ metadata.gz: d3f71bfb1b22b3307bf77b825f38245da0a2fdb496a2283a177cce46b4ad06ac
4
+ data.tar.gz: 6d3bc24a2263f8bd9d7f2d473858cd0134bc414e676425fb2b4119f764b89ec7
5
5
  SHA512:
6
- metadata.gz: aadd1a32fa94041e9adb258ed2542bb93588c016b53d987425f3e85527e88b300b51eece3cddc72328a210b5868077101ec1b7e38708ccc740fb64580366effc
7
- data.tar.gz: 5ba80adf3b385336293728b67bbbb7ae5dbf2a927f7c95db3f0499f0a7e24edcf81c0e9894302bcdeb034bf59c4eef3bcf8da81b0c90a03c8f2b3f7ae822d2c0
6
+ metadata.gz: b66514f271a7e5fd91203815f754b05c00b390ce71bfc5fac1b2c2e4809661ef8a4db47d035c7c46e77039d588eae90160df703cf2b80a55273be374656968f5
7
+ data.tar.gz: be07bc941cd8ed5ae69a55fdb442a98a04a58553c68c3f69219bac9fc2662f27902767da0576cb7137ab920484837b3e77088043d6033adfc3974834a18eee0e
data/CHANGELOG.md CHANGED
@@ -1,21 +1,29 @@
1
- ## 1.2.1 (06 February 2025)
1
+ ## v1.3.0 (10 February 2025)
2
2
 
3
- ## 1.2.0 (06 February 2025)
3
+ - feat: Add config option to hide message about building and pushing the .gem file to rubygems.org
4
+ - fix: Prefix version number in changelog files with 'v'
5
+ - ci: Add rake_announcer gem
6
+
7
+ ## v1.2.1 (06 February 2025)
8
+
9
+ - docs: Fix release instructions to clarify that you need to push the tag _and_ run `rake release`
10
+
11
+ ## v1.2.0 (06 February 2025)
4
12
 
5
13
  - feat: Mention 'rake release' in git tag updater output if a gemspec file is present
6
14
  - feat: Stage Gemfile.lock after bumping version.rb if a gemspec file is present
7
15
 
8
- ## 1.1.0 (03 February 2025)
16
+ ## v1.1.0 (03 February 2025)
9
17
 
10
18
  - Add check to prevent re-initialising if semver file already exists
11
19
  - Add configuration options for semver file
12
20
  - Change rake task namespace from `semantic_release` to `release` and make configurable
13
21
 
14
- ## 1.0.1 (02 February 2025)
22
+ ## v1.0.1 (02 February 2025)
15
23
 
16
24
  - Add blank line after version number in changelog
17
25
  - Remove unnecessary files from gem
18
26
 
19
- ## 1.0.0 (02 February 2025)
27
+ ## v1.0.0 (02 February 2025)
20
28
 
21
29
  - Initial release
data/README.md CHANGED
@@ -48,6 +48,7 @@ The name of the rake task and other options are configurable like so:
48
48
  require "semantic_release/rake_task"
49
49
  SemanticRelease::RakeTask.new(:semver) do |config|
50
50
  config.semver_file = "semver.json"
51
+ config.disable_rubygems_message = true
51
52
  end
52
53
  ```
53
54
 
@@ -2,10 +2,11 @@
2
2
 
3
3
  module SemanticRelease
4
4
  class Configuration
5
- attr_accessor :semver_file
5
+ attr_accessor :semver_file, :disable_rubygems_message
6
6
 
7
7
  def initialize
8
8
  @semver_file = ".semver"
9
+ @disable_rubygems_message = false
9
10
  end
10
11
  end
11
12
  end
@@ -11,6 +11,10 @@ module SemanticRelease
11
11
  Semver.load(semver_file).to_s
12
12
  end
13
13
 
14
+ def self.current_version_tag
15
+ "v#{current_version}"
16
+ end
17
+
14
18
  def self.semver_file
15
19
  SemanticRelease.configuration.semver_file
16
20
  end
@@ -18,7 +18,7 @@ module SemanticRelease
18
18
  heading_marker = filepath.end_with?(".rdoc") ? "==" : "##"
19
19
  content = File.read(filepath)
20
20
  File.open(filepath, "w") do |f|
21
- f.puts("#{heading_marker} #{current_version} (#{Time.now.strftime("%d %B %Y")})\n\n")
21
+ f.puts("#{heading_marker} #{current_version_tag} (#{Time.now.strftime("%d %B %Y")})\n\n")
22
22
  f.print(content)
23
23
  end
24
24
  end
@@ -3,16 +3,21 @@
3
3
  module SemanticRelease
4
4
  module Updaters
5
5
  class GitTag < BaseUpdater
6
+ # rubocop:disable Style/GuardClause
6
7
  def self.update
7
- tag = "v#{current_version}"
8
- msg = "Increment version to v#{current_version}"
8
+ tag = current_version_tag
9
+ msg = "Increment version to #{tag}"
9
10
 
10
11
  `git add #{semver_file} && git commit -m '#{msg}' && git tag #{tag} -a -m '#{Time.now}'`
11
12
 
12
13
  branch = `git rev-parse --abbrev-ref HEAD`.chomp
13
14
  puts "To push the new tag, use 'git push origin #{branch} --tags'"
14
- puts "To push build and push the .gem file to rubygems.org use, 'bundle exec rake release'" if gemspec_present?
15
+
16
+ if gemspec_present? && !SemanticRelease.configuration.disable_rubygems_message
17
+ puts "To build and push the .gem file to rubygems.org use, 'bundle exec rake release'"
18
+ end
15
19
  end
20
+ # rubocop:enable Style/GuardClause
16
21
  end
17
22
  end
18
23
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SemanticRelease
4
- VERSION = "1.2.1"
4
+ VERSION = "1.3.0"
5
5
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: semantic_release
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.1
4
+ version: 1.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Bull
8
8
  bindir: exe
9
9
  cert_chain: []
10
- date: 2025-02-06 00:00:00.000000000 Z
10
+ date: 2025-02-10 00:00:00.000000000 Z
11
11
  dependencies: []
12
12
  description: |
13
13
  This gem helps you to manage the version number of your application or library. It provides Rake tasks to