Skip to content

Commit 6cfb9c5

Browse files
authored
Drop support for ruby 2.4.x (#407)
* updated gemspec ruby version to >2.4, updated README * removing checks for ruby 2.4 in travis scripts * removed ruby 2.4 from github actions * updated CHANGELOG with relevant info * updated ruby version in gemspec * set the target ruby version in rubocop to 2.5 * removed the redudant begin since ruby 2.5
1 parent b7a5ea8 commit 6cfb9c5

File tree

8 files changed

+14
-19
lines changed

8 files changed

+14
-19
lines changed

.github/workflows/main.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ jobs:
2929
fail-fast: false
3030
matrix:
3131
ruby-version:
32-
- '2.4'
3332
- '2.5'
3433
- '2.6'
3534
- '2.7'
@@ -63,7 +62,6 @@ jobs:
6362
fail-fast: false
6463
matrix:
6564
ruby-version:
66-
- '2.4'
6765
- '2.5'
6866
- '2.6'
6967
- '2.7'
@@ -96,7 +94,6 @@ jobs:
9694
fail-fast: false
9795
matrix:
9896
ruby-version:
99-
- '2.4'
10097
- '2.5'
10198
- '2.6'
10299
- '2.7'
@@ -129,7 +126,6 @@ jobs:
129126
fail-fast: false
130127
matrix:
131128
ruby-version:
132-
- '2.4'
133129
- '2.5'
134130
- '2.6'
135131
- '2.7'

.rubocop.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ AllCops:
55
- 'tmp/**/*'
66
- 'vendor/**/*'
77
- 'gemfiles/*'
8-
TargetRubyVersion: 2.4
8+
TargetRubyVersion: 2.5
99

1010
Metrics/BlockLength:
1111
Enabled: false

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# main [(unreleased)](https://github.com/whitesmith/rubycritic/compare/v4.7.0...main)
22

3+
* [CHANGE] Drop support for Ruby 2.4.x (by [@rishijain][])
4+
35
# v4.7.0 / 2022-05-06 [(commits)](https://github.com/whitesmith/rubycritic/compare/v4.6.1...v4.7.0)
46

57
* [CHANGE] Run test suite with Ruby 3.1 (by [@etagwerker][])

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,6 @@ See [formatters](docs/formatters.md)
235235

236236
RubyCritic is supporting Ruby versions:
237237

238-
* 2.4
239238
* 2.5
240239
* 2.6
241240
* 2.7

rubycritic.gemspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Gem::Specification.new do |spec|
1414
spec.summary = 'RubyCritic is a Ruby code quality reporter'
1515
spec.homepage = 'https://github.com/whitesmith/rubycritic'
1616
spec.license = 'MIT'
17-
spec.required_ruby_version = '>= 2.4.0'
17+
spec.required_ruby_version = '>= 2.5.0'
1818

1919
spec.files = [
2020
'CHANGELOG.md',

test/test_helper.rb

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -29,17 +29,15 @@ def capture_output_streams
2929

3030
def with_cloned_fs
3131
FakeFS do
32-
begin
33-
FakeFS::FileSystem.clone(PathHelper.project_path)
32+
FakeFS::FileSystem.clone(PathHelper.project_path)
3433

35-
# reek schema is required to init reek
36-
FakeFS::FileSystem.clone(PathHelper.reek_schema_path)
34+
# reek schema is required to init reek
35+
FakeFS::FileSystem.clone(PathHelper.reek_schema_path)
3736

38-
Dir.chdir(PathHelper.project_path)
39-
yield
40-
ensure
41-
FakeFS::FileSystem.clear
42-
end
37+
Dir.chdir(PathHelper.project_path)
38+
yield
39+
ensure
40+
FakeFS::FileSystem.clear
4341
end
4442
end
4543

travis_scripts/before_script.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/bin/bash
22
set -ev
3-
if [ "${TRAVIS_RUBY_VERSION}" != "2.4" ] && [ "${TRAVIS_RUBY_VERSION}" != "3.0" ]; then
3+
if [ "${TRAVIS_RUBY_VERSION}" != "3.0" ]; then
44
bundle exec appraisal install
55
fi

travis_scripts/script.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
#!/bin/bash
22
set -ev
33
echo "Using Ruby v${TRAVIS_RUBY_VERSION}"
4-
if [ "${TRAVIS_RUBY_VERSION}" = "2.4" ] || [ "${TRAVIS_RUBY_VERSION}" = "3.0" ]; then
4+
if [ "${TRAVIS_RUBY_VERSION}" = "3.0" ]; then
55
bundle exec rake test
66
else
77
bundle exec appraisal rake test
8-
fi
8+
fi

0 commit comments

Comments
 (0)