From 0cdd637d423b9bc761cf68bbc4d1f5a41ca1fc7d Mon Sep 17 00:00:00 2001 From: Kenyon Ralph Date: Mon, 4 Sep 2023 17:00:41 -0700 Subject: [PATCH] rake tasks: fix regexp escaping The second dot should be a literal dot, not any character. --- lib/voxpupuli/release/rake_tasks.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/voxpupuli/release/rake_tasks.rb b/lib/voxpupuli/release/rake_tasks.rb index ea386ec..4cb274c 100644 --- a/lib/voxpupuli/release/rake_tasks.rb +++ b/lib/voxpupuli/release/rake_tasks.rb @@ -31,7 +31,7 @@ def self.tag_pattern end def self.future_release - if metadata['version'].match?(/^\d+\.\d+.\d+$/) + if metadata['version'].match?(/^\d+\.\d+\.\d+$/) format(tag_pattern, metadata['version']) else # Not formatted like a release, might be a pre-release and the future @@ -52,7 +52,7 @@ def self.future_release m = Blacksmith::Modulefile.new v = m.version - unless v.match?(/^\d+\.\d+.\d+$/) + unless v.match?(/^\d+\.\d+\.\d+$/) raise "Refusing to release an RC or build-release (#{v}).\n" + 'Please set a semver *release* version.' end