Skip to content

Commit fe9d943

Browse files
committed
Bump dependencies and use rails minimal installation
1 parent f210c1a commit fe9d943

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+58
-1062
lines changed

.rubocop.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Metrics/LineLength:
1+
Layout/LineLength:
22
Max: 120
33

44
Style/RegexpLiteral:

config.gemspec

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,12 @@ Gem::Specification.new do |s|
3030
s.add_dependency 'deep_merge', '~> 1.2', '>= 1.2.1'
3131
s.add_dependency 'ostruct'
3232

33-
s.add_development_dependency 'rake', '~> 12.0', '>= 12.0.0'
33+
s.add_development_dependency 'rake', '~> 13.0', '>= 13.0.0'
3434

3535
# Testing
3636
s.add_development_dependency 'appraisal', '~> 2.5', '>= 2.5.0'
3737
s.add_development_dependency 'dry-validation', *Config::DryValidationRequirements::VERSIONS
38-
s.add_development_dependency 'rspec', '~> 3.9', '>= 3.9.0'
38+
s.add_development_dependency 'rspec', '~> 3.13', '>= 3.13.2'
3939

4040
# Default RSpec run will test against latest Rails app
4141
unless ENV['APPRAISAL_INITIALIZED'] || ENV['GITHUB_ACTIONS']
@@ -53,10 +53,10 @@ Gem::Specification.new do |s|
5353

5454
if ENV['GITHUB_ACTIONS']
5555
# Code coverage is needed only in CI
56-
s.add_development_dependency 'simplecov', '~> 0.18.5' if RUBY_ENGINE == 'ruby'
56+
s.add_development_dependency 'simplecov', '~> 0.22' if RUBY_ENGINE == 'ruby'
5757
else
5858
# Static code analysis to be used locally
59-
s.add_development_dependency 'mdl', '~> 0.9', '>= 0.9.0'
60-
s.add_development_dependency 'rubocop', '~> 0.85.0'
59+
s.add_development_dependency 'mdl', '~> 0.15', '>= 0.15.0'
60+
s.add_development_dependency 'rubocop', '~> 1.84'
6161
end
6262
end

spec/app/rails_7.2/.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ jobs:
6464
# options: --health-cmd "redis-cli ping" --health-interval 10s --health-timeout 5s --health-retries 5
6565
steps:
6666
- name: Install packages
67-
run: sudo apt-get update && sudo apt-get install --no-install-recommends -y google-chrome-stable curl libjemalloc2 libvips sqlite3
67+
run: sudo apt-get update && sudo apt-get install --no-install-recommends -y google-chrome-stable curl libjemalloc2 sqlite3
6868

6969
- name: Checkout code
7070
uses: actions/checkout@v4

spec/app/rails_7.2/.rubocop.yml

Lines changed: 0 additions & 8 deletions
This file was deleted.

spec/app/rails_7.2/Dockerfile

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@
55
# docker run -d -p 80:80 -p 443:443 --name my-app -e RAILS_MASTER_KEY=<value from config/master.key> my-app
66

77
# Make sure RUBY_VERSION matches the Ruby version in .ruby-version
8-
ARG RUBY_VERSION=3.4.4
8+
ARG RUBY_VERSION=4.0.1
99
FROM docker.io/library/ruby:$RUBY_VERSION-slim AS base
1010

1111
# Rails app lives here
1212
WORKDIR /rails
1313

1414
# Install base packages
1515
RUN apt-get update -qq && \
16-
apt-get install --no-install-recommends -y curl libjemalloc2 libvips sqlite3 && \
16+
apt-get install --no-install-recommends -y curl libjemalloc2 sqlite3 && \
1717
rm -rf /var/lib/apt/lists /var/cache/apt/archives
1818

1919
# Set production environment
@@ -27,21 +27,17 @@ FROM base AS build
2727

2828
# Install packages needed to build gems
2929
RUN apt-get update -qq && \
30-
apt-get install --no-install-recommends -y build-essential git pkg-config && \
30+
apt-get install --no-install-recommends -y build-essential git libyaml-dev pkg-config && \
3131
rm -rf /var/lib/apt/lists /var/cache/apt/archives
3232

3333
# Install application gems
3434
COPY Gemfile Gemfile.lock ./
3535
RUN bundle install && \
36-
rm -rf ~/.bundle/ "${BUNDLE_PATH}"/ruby/*/cache "${BUNDLE_PATH}"/ruby/*/bundler/gems/*/.git && \
37-
bundle exec bootsnap precompile --gemfile
36+
rm -rf ~/.bundle/ "${BUNDLE_PATH}"/ruby/*/cache "${BUNDLE_PATH}"/ruby/*/bundler/gems/*/.git
3837

3938
# Copy application code
4039
COPY . .
4140

42-
# Precompile bootsnap code for faster boot times
43-
RUN bundle exec bootsnap precompile app/ lib/
44-
4541
# Precompiling assets for production without requiring secret RAILS_MASTER_KEY
4642
RUN SECRET_KEY_BASE_DUMMY=1 ./bin/rails assets:precompile
4743

spec/app/rails_7.2/Gemfile

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,21 @@
11
source "https://rubygems.org"
22

33
# Bundle edge Rails instead: gem "rails", github: "rails/rails", branch: "main"
4-
gem "rails", "~> 7.2.2", ">= 7.2.2.1"
4+
gem "rails", "~> 7.2.3"
55
# The original asset pipeline for Rails [https://github.com/rails/sprockets-rails]
66
gem "sprockets-rails"
77
# Use sqlite3 as the database for Active Record
88
gem "sqlite3", ">= 1.4"
99
# Use the Puma web server [https://github.com/puma/puma]
1010
gem "puma", ">= 5.0"
11-
# Use JavaScript with ESM import maps [https://github.com/rails/importmap-rails]
12-
gem "importmap-rails"
13-
# Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev]
14-
gem "turbo-rails"
15-
# Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev]
16-
gem "stimulus-rails"
17-
# Build JSON APIs with ease [https://github.com/rails/jbuilder]
18-
gem "jbuilder"
19-
# Use Redis adapter to run Action Cable in production
20-
# gem "redis", ">= 4.0.1"
21-
22-
# Use Kredis to get higher-level data types in Redis [https://github.com/rails/kredis]
23-
# gem "kredis"
24-
25-
# Use Active Model has_secure_password [https://guides.rubyonrails.org/active_model_basics.html#securepassword]
26-
# gem "bcrypt", "~> 3.1.7"
2711

2812
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
2913
gem "tzinfo-data", platforms: %i[ windows jruby ]
3014

31-
# Reduces boot times through caching; required in config/boot.rb
32-
gem "bootsnap", require: false
33-
34-
# Use Active Storage variants [https://guides.rubyonrails.org/active_storage_overview.html#transforming-images]
35-
# gem "image_processing", "~> 1.2"
36-
3715
group :development, :test do
3816
# See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem
3917
gem "debug", platforms: %i[ mri windows ], require: "debug/prelude"
4018

4119
# Static analysis for security vulnerabilities [https://brakemanscanner.org/]
4220
gem "brakeman", require: false
43-
44-
# Omakase Ruby styling [https://github.com/rails/rubocop-rails-omakase/]
45-
gem "rubocop-rails-omakase", require: false
46-
end
47-
48-
group :development do
49-
# Use console on exceptions pages [https://github.com/rails/web-console]
50-
gem "web-console"
51-
end
52-
53-
group :test do
54-
# Use system testing [https://guides.rubyonrails.org/testing.html#system-testing]
55-
gem "capybara"
56-
gem "selenium-webdriver"
5721
end

spec/app/rails_7.2/app/channels/application_cable/channel.rb

Lines changed: 0 additions & 4 deletions
This file was deleted.

spec/app/rails_7.2/app/channels/application_cable/connection.rb

Lines changed: 0 additions & 4 deletions
This file was deleted.

spec/app/rails_7.2/app/jobs/application_job.rb

Lines changed: 0 additions & 7 deletions
This file was deleted.

spec/app/rails_7.2/app/mailers/application_mailer.rb

Lines changed: 0 additions & 4 deletions
This file was deleted.

0 commit comments

Comments
 (0)