From aa234ab7193f12d4c38f61d89cffbe19655c9a6f Mon Sep 17 00:00:00 2001 From: Teal <git@teal.is> Date: Tue, 4 Mar 2025 17:05:02 +0100 Subject: [PATCH] Update to Ruby 3.4.1, add Rubocop --- .rubocop.yml | 5 +++++ .tool-versions | 2 +- Gemfile | 14 +++++++++----- Gemfile.lock | 45 ++++++++++++++++++++++++++++++++++++++++++++- 4 files changed, 59 insertions(+), 7 deletions(-) create mode 100644 .rubocop.yml diff --git a/.rubocop.yml b/.rubocop.yml new file mode 100644 index 0000000..3306cb8 --- /dev/null +++ b/.rubocop.yml @@ -0,0 +1,5 @@ +inherit_gem: { rubocop-rails-omakase: rubocop.yml } +require: + - rubocop-capybara +AllCops: + NewCops: enable diff --git a/.tool-versions b/.tool-versions index 5aa8e0c..041df9a 100644 --- a/.tool-versions +++ b/.tool-versions @@ -1 +1 @@ -ruby 3.3.6 +ruby 3.4.1 diff --git a/Gemfile b/Gemfile index dd87ab2..5f73573 100644 --- a/Gemfile +++ b/Gemfile @@ -1,6 +1,6 @@ source "https://rubygems.org" -ruby "3.3.6" +ruby "3.4.1" gem "rails", "~> 8.0.1" @@ -17,14 +17,18 @@ gem "puma", ">= 5.0" gem "redis", ">= 4.0.1" # Windows does not include zoneinfo files, so bundle the tzinfo-data gem -gem "tzinfo-data", platforms: %i[ windows jruby ] +gem "tzinfo-data", platforms: %i[windows jruby] # Reduces boot times through caching; required in config/boot.rb gem "bootsnap", require: false group :development, :test do # See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem - gem "debug", platforms: %i[ mri windows ] + gem "debug", platforms: %i[mri windows] + + gem "rubocop-rails-omakase", "~> 1.1" + + gem "rubocop-capybara", "~> 2.21" end group :development do @@ -50,8 +54,8 @@ gem "httparty", "> 0" gem "tailwindcss-rails", "~> 3.1" -gem "turbo-rails", "~> 2.0" gem "stimulus-rails", "~> 1.3" +gem "turbo-rails", "~> 2.0" gem "importmap-rails", "~> 2.0" @@ -59,6 +63,6 @@ gem "icalendar", "~> 2.10" gem "telegram-bot-ruby", "~> 2.0" -gem 'devise', '~> 4.9' +gem "devise", "~> 4.9" gem "crono", "~> 2.1" diff --git a/Gemfile.lock b/Gemfile.lock index d111a79..e3cbb44 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -74,6 +74,7 @@ GEM uri (>= 0.13.1) addressable (2.8.7) public_suffix (>= 2.0.2, < 7.0) + ast (2.4.2) base64 (0.2.0) bcrypt (3.1.20) benchmark (0.4.0) @@ -165,6 +166,8 @@ GEM rdoc (>= 4.0.0) reline (>= 0.4.2) json (2.9.1) + language_server-protocol (3.17.0.4) + lint_roller (1.1.0) logger (1.6.5) loofah (2.24.0) crass (~> 1.0.2) @@ -202,6 +205,10 @@ GEM racc (~> 1.4) orm_adapter (0.5.0) ostruct (0.6.1) + parallel (1.26.3) + parser (3.3.7.1) + ast (~> 2.4.1) + racc psych (5.2.2) date stringio @@ -246,6 +253,7 @@ GEM rake (>= 12.2) thor (~> 1.0, >= 1.2.2) zeitwerk (~> 2.6) + rainbow (3.1.1) rake (13.2.1) rdoc (6.10.0) psych (>= 4.0.0) @@ -260,6 +268,36 @@ GEM actionpack (>= 5.2) railties (>= 5.2) rexml (3.4.0) + rubocop (1.73.2) + json (~> 2.3) + language_server-protocol (~> 3.17.0.2) + lint_roller (~> 1.1.0) + parallel (~> 1.10) + parser (>= 3.3.0.2) + rainbow (>= 2.2.2, < 4.0) + regexp_parser (>= 2.9.3, < 3.0) + rubocop-ast (>= 1.38.0, < 2.0) + ruby-progressbar (~> 1.7) + unicode-display_width (>= 2.4.0, < 4.0) + rubocop-ast (1.38.1) + parser (>= 3.3.1.0) + rubocop-capybara (2.21.0) + rubocop (~> 1.41) + rubocop-performance (1.24.0) + lint_roller (~> 1.1) + rubocop (>= 1.72.1, < 2.0) + rubocop-ast (>= 1.38.0, < 2.0) + rubocop-rails (2.30.3) + activesupport (>= 4.2.0) + lint_roller (~> 1.1) + rack (>= 1.1) + rubocop (>= 1.72.1, < 2.0) + rubocop-ast (>= 1.38.0, < 2.0) + rubocop-rails-omakase (1.1.0) + rubocop (>= 1.72) + rubocop-performance (>= 1.24) + rubocop-rails (>= 2.30) + ruby-progressbar (1.13.0) rubyzip (2.4.1) securerandom (0.4.1) selenium-webdriver (4.28.0) @@ -306,6 +344,9 @@ GEM railties (>= 6.0.0) tzinfo (2.0.6) concurrent-ruby (~> 1.0) + unicode-display_width (3.1.4) + unicode-emoji (~> 4.0, >= 4.0.4) + unicode-emoji (4.0.4) uri (1.0.2) useragent (0.16.11) warden (1.2.9) @@ -341,6 +382,8 @@ DEPENDENCIES puma (>= 5.0) rails (~> 8.0.1) redis (>= 4.0.1) + rubocop-capybara (~> 2.21) + rubocop-rails-omakase (~> 1.1) selenium-webdriver solid_queue (~> 1.1) sprockets-rails (> 0) @@ -353,7 +396,7 @@ DEPENDENCIES web-console (> 0) RUBY VERSION - ruby 3.3.6p108 + ruby 3.4.1p0 BUNDLED WITH 2.6.2 -- GitLab