Skip to content

Commit 2175f6d

Browse files
committed
Update dev env into Rails 7
1 parent 8041a74 commit 2175f6d

19 files changed

+404
-176
lines changed

Gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@
33
source "https://rubygems.org"
44

55
gemspec
6-
gem "rails", "~> 7.0.0.alpha"
6+
gem "rails", "~> 7.0.0"

Gemfile.lock

Lines changed: 72 additions & 81 deletions
Original file line numberDiff line numberDiff line change
@@ -7,146 +7,137 @@ PATH
77
GEM
88
remote: https://rubygems.org/
99
specs:
10-
actioncable (7.0.0.alpha2)
11-
actionpack (= 7.0.0.alpha2)
12-
activesupport (= 7.0.0.alpha2)
10+
actioncable (7.0.0)
11+
actionpack (= 7.0.0)
12+
activesupport (= 7.0.0)
1313
nio4r (~> 2.0)
1414
websocket-driver (>= 0.6.1)
15-
actionmailbox (7.0.0.alpha2)
16-
actionpack (= 7.0.0.alpha2)
17-
activejob (= 7.0.0.alpha2)
18-
activerecord (= 7.0.0.alpha2)
19-
activestorage (= 7.0.0.alpha2)
20-
activesupport (= 7.0.0.alpha2)
15+
actionmailbox (7.0.0)
16+
actionpack (= 7.0.0)
17+
activejob (= 7.0.0)
18+
activerecord (= 7.0.0)
19+
activestorage (= 7.0.0)
20+
activesupport (= 7.0.0)
2121
mail (>= 2.7.1)
22-
actionmailer (7.0.0.alpha2)
23-
actionpack (= 7.0.0.alpha2)
24-
actionview (= 7.0.0.alpha2)
25-
activejob (= 7.0.0.alpha2)
26-
activesupport (= 7.0.0.alpha2)
22+
actionmailer (7.0.0)
23+
actionpack (= 7.0.0)
24+
actionview (= 7.0.0)
25+
activejob (= 7.0.0)
26+
activesupport (= 7.0.0)
2727
mail (~> 2.5, >= 2.5.4)
2828
rails-dom-testing (~> 2.0)
29-
actionpack (7.0.0.alpha2)
30-
actionview (= 7.0.0.alpha2)
31-
activesupport (= 7.0.0.alpha2)
29+
actionpack (7.0.0)
30+
actionview (= 7.0.0)
31+
activesupport (= 7.0.0)
3232
rack (~> 2.0, >= 2.2.0)
3333
rack-test (>= 0.6.3)
3434
rails-dom-testing (~> 2.0)
3535
rails-html-sanitizer (~> 1.0, >= 1.2.0)
36-
actiontext (7.0.0.alpha2)
37-
actionpack (= 7.0.0.alpha2)
38-
activerecord (= 7.0.0.alpha2)
39-
activestorage (= 7.0.0.alpha2)
40-
activesupport (= 7.0.0.alpha2)
36+
actiontext (7.0.0)
37+
actionpack (= 7.0.0)
38+
activerecord (= 7.0.0)
39+
activestorage (= 7.0.0)
40+
activesupport (= 7.0.0)
41+
globalid (>= 0.6.0)
4142
nokogiri (>= 1.8.5)
42-
actionview (7.0.0.alpha2)
43-
activesupport (= 7.0.0.alpha2)
43+
actionview (7.0.0)
44+
activesupport (= 7.0.0)
4445
builder (~> 3.1)
4546
erubi (~> 1.4)
4647
rails-dom-testing (~> 2.0)
4748
rails-html-sanitizer (~> 1.1, >= 1.2.0)
48-
activejob (7.0.0.alpha2)
49-
activesupport (= 7.0.0.alpha2)
49+
activejob (7.0.0)
50+
activesupport (= 7.0.0)
5051
globalid (>= 0.3.6)
51-
activemodel (7.0.0.alpha2)
52-
activesupport (= 7.0.0.alpha2)
53-
activerecord (7.0.0.alpha2)
54-
activemodel (= 7.0.0.alpha2)
55-
activesupport (= 7.0.0.alpha2)
56-
activestorage (7.0.0.alpha2)
57-
actionpack (= 7.0.0.alpha2)
58-
activejob (= 7.0.0.alpha2)
59-
activerecord (= 7.0.0.alpha2)
60-
activesupport (= 7.0.0.alpha2)
61-
marcel (~> 1.0.0)
52+
activemodel (7.0.0)
53+
activesupport (= 7.0.0)
54+
activerecord (7.0.0)
55+
activemodel (= 7.0.0)
56+
activesupport (= 7.0.0)
57+
activestorage (7.0.0)
58+
actionpack (= 7.0.0)
59+
activejob (= 7.0.0)
60+
activerecord (= 7.0.0)
61+
activesupport (= 7.0.0)
62+
marcel (~> 1.0)
6263
mini_mime (>= 1.1.0)
63-
activesupport (7.0.0.alpha2)
64+
activesupport (7.0.0)
6465
concurrent-ruby (~> 1.0, >= 1.0.2)
6566
i18n (>= 1.6, < 2)
6667
minitest (>= 5.1)
6768
tzinfo (~> 2.0)
6869
builder (3.2.4)
69-
codecov (0.2.12)
70-
json
71-
simplecov
70+
codecov (0.6.0)
71+
simplecov (>= 0.15, < 0.22)
7272
concurrent-ruby (1.1.9)
7373
crass (1.0.6)
74-
docile (1.3.4)
74+
docile (1.4.0)
7575
erubi (1.10.0)
76-
factory_bot (6.1.0)
76+
factory_bot (6.2.0)
7777
activesupport (>= 5.0.0)
78-
globalid (0.5.2)
78+
globalid (1.0.0)
7979
activesupport (>= 5.0)
80-
i18n (1.8.10)
80+
i18n (1.8.11)
8181
concurrent-ruby (~> 1.0)
82-
json (2.5.1)
83-
loofah (2.12.0)
82+
loofah (2.13.0)
8483
crass (~> 1.0.2)
8584
nokogiri (>= 1.5.9)
8685
mail (2.7.1)
8786
mini_mime (>= 0.1.1)
88-
marcel (1.0.1)
87+
marcel (1.0.2)
8988
method_source (1.0.0)
90-
mini_mime (1.1.1)
89+
mini_mime (1.1.2)
9190
mini_portile2 (2.6.1)
92-
minitest (5.14.4)
91+
minitest (5.15.0)
9392
nio4r (2.5.8)
94-
nokogiri (1.12.4)
93+
nokogiri (1.12.5)
9594
mini_portile2 (~> 2.6.1)
9695
racc (~> 1.4)
9796
pg (1.2.3)
98-
racc (1.5.2)
97+
racc (1.6.0)
9998
rack (2.2.3)
10099
rack-test (1.1.0)
101100
rack (>= 1.0, < 3)
102-
rails (7.0.0.alpha2)
103-
actioncable (= 7.0.0.alpha2)
104-
actionmailbox (= 7.0.0.alpha2)
105-
actionmailer (= 7.0.0.alpha2)
106-
actionpack (= 7.0.0.alpha2)
107-
actiontext (= 7.0.0.alpha2)
108-
actionview (= 7.0.0.alpha2)
109-
activejob (= 7.0.0.alpha2)
110-
activemodel (= 7.0.0.alpha2)
111-
activerecord (= 7.0.0.alpha2)
112-
activestorage (= 7.0.0.alpha2)
113-
activesupport (= 7.0.0.alpha2)
101+
rails (7.0.0)
102+
actioncable (= 7.0.0)
103+
actionmailbox (= 7.0.0)
104+
actionmailer (= 7.0.0)
105+
actionpack (= 7.0.0)
106+
actiontext (= 7.0.0)
107+
actionview (= 7.0.0)
108+
activejob (= 7.0.0)
109+
activemodel (= 7.0.0)
110+
activerecord (= 7.0.0)
111+
activestorage (= 7.0.0)
112+
activesupport (= 7.0.0)
114113
bundler (>= 1.15.0)
115-
railties (= 7.0.0.alpha2)
116-
sprockets-rails (>= 2.0.0)
114+
railties (= 7.0.0)
117115
rails-dom-testing (2.0.3)
118116
activesupport (>= 4.2.0)
119117
nokogiri (>= 1.6)
120118
rails-html-sanitizer (1.4.2)
121119
loofah (~> 2.3)
122-
railties (7.0.0.alpha2)
123-
actionpack (= 7.0.0.alpha2)
124-
activesupport (= 7.0.0.alpha2)
120+
railties (7.0.0)
121+
actionpack (= 7.0.0)
122+
activesupport (= 7.0.0)
125123
method_source
126-
rake (>= 0.13)
124+
rake (>= 12.2)
127125
thor (~> 1.0)
128-
zeitwerk (~> 2.5.0.beta3)
126+
zeitwerk (~> 2.5)
129127
rake (13.0.6)
130128
simplecov (0.21.2)
131129
docile (~> 1.1)
132130
simplecov-html (~> 0.11)
133131
simplecov_json_formatter (~> 0.1)
134132
simplecov-html (0.12.3)
135-
simplecov_json_formatter (0.1.2)
136-
sprockets (4.0.2)
137-
concurrent-ruby (~> 1.0)
138-
rack (> 1, < 3)
139-
sprockets-rails (3.2.2)
140-
actionpack (>= 4.0)
141-
activesupport (>= 4.0)
142-
sprockets (>= 3.0.0)
133+
simplecov_json_formatter (0.1.3)
143134
thor (1.1.0)
144135
tzinfo (2.0.4)
145136
concurrent-ruby (~> 1.0)
146137
websocket-driver (0.7.5)
147138
websocket-extensions (>= 0.1.0)
148139
websocket-extensions (0.1.5)
149-
zeitwerk (2.5.0.beta3)
140+
zeitwerk (2.5.1)
150141

151142
PLATFORMS
152143
ruby
@@ -156,7 +147,7 @@ DEPENDENCIES
156147
codecov
157148
factory_bot
158149
pg
159-
rails (~> 7.0.0.alpha)
150+
rails (~> 7.0.0)
160151
simplecov
161152

162153
BUNDLED WITH

bin/rails

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
#!/usr/bin/env ruby
2-
# frozen_string_literal: true
3-
42
# This command will automatically be run when you run "rails" with Rails gems
53
# installed from the root of your application.
64

75
ENGINE_ROOT = File.expand_path("..", __dir__)
8-
ENGINE_PATH = File.expand_path("../lib/action_store/engine", __dir__)
6+
ENGINE_PATH = File.expand_path("../lib/action/store/engine", __dir__)
7+
APP_PATH = File.expand_path("../test/dummy/config/application", __dir__)
98

109
# Set up gems listed in the Gemfile.
1110
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)

test/dummy/bin/rails

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/usr/bin/env ruby
2-
APP_PATH = File.expand_path('../config/application', __dir__)
3-
require_relative '../config/boot'
4-
require 'rails/commands'
2+
APP_PATH = File.expand_path("../config/application", __dir__)
3+
require_relative "../config/boot"
4+
require "rails/commands"

test/dummy/bin/rake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/usr/bin/env ruby
2-
require_relative '../config/boot'
3-
require 'rake'
2+
require_relative "../config/boot"
3+
require "rake"
44
Rake.application.run

test/dummy/bin/setup

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,33 @@
11
#!/usr/bin/env ruby
2-
require 'pathname'
3-
require 'fileutils'
4-
include FileUtils
2+
require "fileutils"
53

64
# path to your application root.
7-
APP_ROOT = Pathname.new File.expand_path('../../', __FILE__)
5+
APP_ROOT = File.expand_path("..", __dir__)
86

97
def system!(*args)
108
system(*args) || abort("\n== Command #{args} failed ==")
119
end
1210

13-
chdir APP_ROOT do
14-
# This script is a starting point to setup your application.
11+
FileUtils.chdir APP_ROOT do
12+
# This script is a way to set up or update your development environment automatically.
13+
# This script is idempotent, so that you can run it at any time and get an expectable outcome.
1514
# Add necessary setup steps to this file.
1615

17-
puts '== Installing dependencies =='
18-
system! 'gem install bundler --conservative'
19-
system('bundle check') || system!('bundle install')
16+
puts "== Installing dependencies =="
17+
system! "gem install bundler --conservative"
18+
system("bundle check") || system!("bundle install")
2019

2120
# puts "\n== Copying sample files =="
22-
# unless File.exist?('config/database.yml')
23-
# cp 'config/database.yml.sample', 'config/database.yml'
21+
# unless File.exist?("config/database.yml")
22+
# FileUtils.cp "config/database.yml.sample", "config/database.yml"
2423
# end
2524

2625
puts "\n== Preparing database =="
27-
system! 'bin/rails db:setup'
26+
system! "bin/rails db:prepare"
2827

2928
puts "\n== Removing old logs and tempfiles =="
30-
system! 'bin/rails log:clear tmp:clear'
29+
system! "bin/rails log:clear tmp:clear"
3130

3231
puts "\n== Restarting application server =="
33-
system! 'bin/rails restart'
32+
system! "bin/rails restart"
3433
end

test/dummy/config/application.rb

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,22 @@
1-
require_relative 'boot'
1+
require_relative "boot"
22

3-
require 'rails/all'
3+
require "rails/all"
44

5+
# Require the gems listed in Gemfile, including any gems
6+
# you've limited to :test, :development, or :production.
57
Bundler.require(*Rails.groups)
6-
require "action-store"
78

89
module Dummy
910
class Application < Rails::Application
10-
# Settings in config/environments/* take precedence over those specified here.
11-
# Application configuration should go into files in config/initializers
12-
# -- all .rb files in that directory are automatically loaded.
11+
# Initialize configuration defaults for originally generated Rails version.
12+
config.load_defaults 5.0
13+
14+
# Configuration for the application, engines, and railties goes here.
15+
#
16+
# These settings can be overridden in specific environments using the files
17+
# in config/environments, which are processed later.
18+
#
19+
# config.time_zone = "Central Time (US & Canada)"
20+
# config.eager_load_paths << Rails.root.join("extras")
1321
end
1422
end
15-

test/dummy/config/boot.rb

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
# Set up gems listed in the Gemfile.
2-
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../../Gemfile', __dir__)
1+
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)
32

4-
require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE'])
5-
$LOAD_PATH.unshift File.expand_path('../../../lib', __dir__)
3+
require "bundler/setup" # Set up gems listed in the Gemfile.

test/dummy/config/cable.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
development:
2+
adapter: async
3+
4+
test:
5+
adapter: test
6+
7+
production:
8+
adapter: redis
9+
url: <%= ENV.fetch("REDIS_URL") { "redis://localhost:6379/1" } %>
10+
channel_prefix: dummy_production

0 commit comments

Comments
 (0)