Skip to content

Commit d58cc4c

Browse files
committed
not-very-tested 6.0
1 parent 3ffa580 commit d58cc4c

File tree

11 files changed

+157
-69
lines changed

11 files changed

+157
-69
lines changed

Gemfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
source 'https://rubygems.org'
22

3-
ruby '2.6.9'
3+
ruby '2.7.6'
44

55
# Please keep the gems (as well as within a group) sorted
66
# in alphabetical order.
77

8-
gem 'acts-as-taggable-on', '~> 6.0.0'
8+
gem 'acts-as-taggable-on', '~> 7.0.0'
99
gem 'barometer'
1010
gem 'bootsnap', require: false
1111
gem 'bootstrap-datepicker-rails'
@@ -47,7 +47,7 @@ gem 'puma'
4747
gem 'rake', '< 13.0'
4848
gem 'rack-attack'
4949
gem 'rack-mini-profiler'
50-
gem 'rails', '5.2.8'
50+
gem 'rails', '6.0.5.1'
5151
gem 'record_tag_helper', '~> 1.0'
5252
gem 'react-rails', '~> 2.3.0'
5353
gem 'recap', '~> 1.0.0'

Gemfile.lock

Lines changed: 64 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -2,52 +2,65 @@ GEM
22
remote: https://rubygems.org/
33
remote: https://rails-assets.org/
44
specs:
5-
actioncable (5.2.8)
6-
actionpack (= 5.2.8)
5+
actioncable (6.0.5.1)
6+
actionpack (= 6.0.5.1)
77
nio4r (~> 2.0)
88
websocket-driver (>= 0.6.1)
9-
actionmailer (5.2.8)
10-
actionpack (= 5.2.8)
11-
actionview (= 5.2.8)
12-
activejob (= 5.2.8)
9+
actionmailbox (6.0.5.1)
10+
actionpack (= 6.0.5.1)
11+
activejob (= 6.0.5.1)
12+
activerecord (= 6.0.5.1)
13+
activestorage (= 6.0.5.1)
14+
activesupport (= 6.0.5.1)
15+
mail (>= 2.7.1)
16+
actionmailer (6.0.5.1)
17+
actionpack (= 6.0.5.1)
18+
actionview (= 6.0.5.1)
19+
activejob (= 6.0.5.1)
1320
mail (~> 2.5, >= 2.5.4)
1421
rails-dom-testing (~> 2.0)
15-
actionpack (5.2.8)
16-
actionview (= 5.2.8)
17-
activesupport (= 5.2.8)
22+
actionpack (6.0.5.1)
23+
actionview (= 6.0.5.1)
24+
activesupport (= 6.0.5.1)
1825
rack (~> 2.0, >= 2.0.8)
1926
rack-test (>= 0.6.3)
2027
rails-dom-testing (~> 2.0)
21-
rails-html-sanitizer (~> 1.0, >= 1.0.2)
22-
actionview (5.2.8)
23-
activesupport (= 5.2.8)
28+
rails-html-sanitizer (~> 1.0, >= 1.2.0)
29+
actiontext (6.0.5.1)
30+
actionpack (= 6.0.5.1)
31+
activerecord (= 6.0.5.1)
32+
activestorage (= 6.0.5.1)
33+
activesupport (= 6.0.5.1)
34+
nokogiri (>= 1.8.5)
35+
actionview (6.0.5.1)
36+
activesupport (= 6.0.5.1)
2437
builder (~> 3.1)
2538
erubi (~> 1.4)
2639
rails-dom-testing (~> 2.0)
27-
rails-html-sanitizer (~> 1.0, >= 1.0.3)
28-
activejob (5.2.8)
29-
activesupport (= 5.2.8)
40+
rails-html-sanitizer (~> 1.1, >= 1.2.0)
41+
activejob (6.0.5.1)
42+
activesupport (= 6.0.5.1)
3043
globalid (>= 0.3.6)
31-
activemodel (5.2.8)
32-
activesupport (= 5.2.8)
33-
activerecord (5.2.8)
34-
activemodel (= 5.2.8)
35-
activesupport (= 5.2.8)
36-
arel (>= 9.0)
37-
activestorage (5.2.8)
38-
actionpack (= 5.2.8)
39-
activerecord (= 5.2.8)
40-
marcel (~> 1.0.0)
41-
activesupport (5.2.8)
44+
activemodel (6.0.5.1)
45+
activesupport (= 6.0.5.1)
46+
activerecord (6.0.5.1)
47+
activemodel (= 6.0.5.1)
48+
activesupport (= 6.0.5.1)
49+
activestorage (6.0.5.1)
50+
actionpack (= 6.0.5.1)
51+
activejob (= 6.0.5.1)
52+
activerecord (= 6.0.5.1)
53+
marcel (~> 1.0)
54+
activesupport (6.0.5.1)
4255
concurrent-ruby (~> 1.0, >= 1.0.2)
4356
i18n (>= 0.7, < 2)
4457
minitest (~> 5.1)
4558
tzinfo (~> 1.1)
46-
acts-as-taggable-on (6.0.0)
47-
activerecord (~> 5.0)
59+
zeitwerk (~> 2.2, >= 2.2.2)
60+
acts-as-taggable-on (7.0.0)
61+
activerecord (>= 5.0, < 6.2)
4862
addressable (2.8.0)
4963
public_suffix (>= 2.0.2, < 5.0)
50-
arel (9.0.0)
5164
aws-eventstream (1.2.0)
5265
aws-partitions (1.610.0)
5366
aws-sdk-core (3.131.3)
@@ -101,7 +114,7 @@ GEM
101114
net-sftp (>= 2.0.0)
102115
net-ssh (>= 2.0.14)
103116
net-ssh-gateway (>= 1.1.0)
104-
capybara (3.36.0)
117+
capybara (3.37.1)
105118
addressable
106119
matrix
107120
mini_mime (>= 0.1.3)
@@ -312,18 +325,20 @@ GEM
312325
rack
313326
rack-test (2.0.2)
314327
rack (>= 1.3)
315-
rails (5.2.8)
316-
actioncable (= 5.2.8)
317-
actionmailer (= 5.2.8)
318-
actionpack (= 5.2.8)
319-
actionview (= 5.2.8)
320-
activejob (= 5.2.8)
321-
activemodel (= 5.2.8)
322-
activerecord (= 5.2.8)
323-
activestorage (= 5.2.8)
324-
activesupport (= 5.2.8)
328+
rails (6.0.5.1)
329+
actioncable (= 6.0.5.1)
330+
actionmailbox (= 6.0.5.1)
331+
actionmailer (= 6.0.5.1)
332+
actionpack (= 6.0.5.1)
333+
actiontext (= 6.0.5.1)
334+
actionview (= 6.0.5.1)
335+
activejob (= 6.0.5.1)
336+
activemodel (= 6.0.5.1)
337+
activerecord (= 6.0.5.1)
338+
activestorage (= 6.0.5.1)
339+
activesupport (= 6.0.5.1)
325340
bundler (>= 1.3.0)
326-
railties (= 5.2.8)
341+
railties (= 6.0.5.1)
327342
sprockets-rails (>= 2.0.0)
328343
rails-assets-axios (0.27.2)
329344
rails-assets-bootstrap-tagsinput (0.8.0)
@@ -350,12 +365,12 @@ GEM
350365
rails_stdout_logging
351366
rails_serve_static_assets (0.0.5)
352367
rails_stdout_logging (0.0.5)
353-
railties (5.2.8)
354-
actionpack (= 5.2.8)
355-
activesupport (= 5.2.8)
368+
railties (6.0.5.1)
369+
actionpack (= 6.0.5.1)
370+
activesupport (= 6.0.5.1)
356371
method_source
357372
rake (>= 0.8.7)
358-
thor (>= 0.19.0, < 2.0)
373+
thor (>= 0.20.3, < 2.0)
359374
rake (12.3.3)
360375
rb-fsevent (0.11.1)
361376
rb-inotify (0.10.1)
@@ -485,12 +500,13 @@ GEM
485500
chronic (>= 0.6.3)
486501
xpath (3.2.0)
487502
nokogiri (~> 1.8)
503+
zeitwerk (2.6.0)
488504

489505
PLATFORMS
490506
ruby
491507

492508
DEPENDENCIES
493-
acts-as-taggable-on (~> 6.0.0)
509+
acts-as-taggable-on (~> 7.0.0)
494510
aws-sdk-s3 (~> 1.103)
495511
barometer
496512
bootsnap
@@ -537,7 +553,7 @@ DEPENDENCIES
537553
puma
538554
rack-attack
539555
rack-mini-profiler
540-
rails (= 5.2.8)
556+
rails (= 6.0.5.1)
541557
rails-assets-axios!
542558
rails-assets-bootstrap-tagsinput!
543559
rails-assets-jquery-timeago!
@@ -568,7 +584,7 @@ DEPENDENCIES
568584
whenever
569585

570586
RUBY VERSION
571-
ruby 2.6.9p207
587+
ruby 2.7.6p219
572588

573589
BUNDLED WITH
574590
1.17.3

bin/setup

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
#!/usr/bin/env ruby
22
require 'fileutils'
3-
include FileUtils
43

54
# path to your application root.
65
APP_ROOT = File.expand_path('..', __dir__)
@@ -9,24 +8,25 @@ def system!(*args)
98
system(*args) || abort("\n== Command #{args} failed ==")
109
end
1110

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

1616
puts '== Installing dependencies =='
1717
system! 'gem install bundler --conservative'
1818
system('bundle check') || system!('bundle install')
1919

20-
# Install JavaScript dependencies if using Yarn
20+
# Install JavaScript dependencies
2121
# system('bin/yarn')
2222

2323
# puts "\n== Copying sample files =="
2424
# unless File.exist?('config/database.yml')
25-
# cp 'config/database.yml.sample', 'config/database.yml'
25+
# FileUtils.cp 'config/database.yml.sample', 'config/database.yml'
2626
# end
2727

2828
puts "\n== Preparing database =="
29-
system! 'bin/rails db:setup'
29+
system! 'bin/rails db:prepare'
3030

3131
puts "\n== Removing old logs and tempfiles =="
3232
system! 'bin/rails log:clear tmp:clear'

config/application.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ class Application < Rails::Application
2323
# had to delete this for rails 5.1
2424
# config.active_record.raise_in_transactional_callbacks = true
2525

26+
# allow deserializing YAML for Symbol
27+
config.active_record.yaml_column_permitted_classes = [Symbol, ActiveSupport::HashWithIndifferentAccess]
28+
2629
config.assets.initialize_on_precompile = false
2730

2831
config.middleware.use Rack::Attack

config/environments/development.rb

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
# Run rails dev:cache to toggle caching.
1717
if Rails.root.join('tmp', 'caching-dev.txt').exist?
1818
config.action_controller.perform_caching = true
19+
config.action_controller.enable_fragment_cache_logging = true
1920

2021
config.cache_store = :memory_store
2122
config.public_file_server.headers = {
@@ -27,7 +28,7 @@
2728
config.cache_store = :null_store
2829
end
2930

30-
# Store uploaded files on the local file system (see config/storage.yml for options)
31+
# Store uploaded files on the local file system (see config/storage.yml for options).
3132
config.active_storage.service = :local
3233

3334
# Don't care if the mailer can't send.
@@ -52,7 +53,7 @@
5253
# Suppress logger output for asset requests.
5354
config.assets.quiet = true
5455

55-
# Raises error for missing translations
56+
# Raises error for missing translations.
5657
# config.action_view.raise_on_missing_translations = true
5758

5859
# Use an evented file watcher to asynchronously detect changes in source code,

config/environments/test.rb

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1+
# The test environment is used exclusively to run your application's
2+
# test suite. You never need to work with it otherwise. Remember that
3+
# your test database is "scratch space" for the test suite and is wiped
4+
# and recreated between test runs. Don't rely on the data there!
5+
16
Rails.application.configure do
27
# Settings specified here will take precedence over those in config/application.rb.
38

4-
# The test environment is used exclusively to run your application's
5-
# test suite. You never need to work with it otherwise. Remember that
6-
# your test database is "scratch space" for the test suite and is wiped
7-
# and recreated between test runs. Don't rely on the data there!
89
config.cache_classes = true
910

1011
# Do not eager load code on boot. This avoids loading your whole application
@@ -21,14 +22,15 @@
2122
# Show full error reports and disable caching.
2223
config.consider_all_requests_local = true
2324
config.action_controller.perform_caching = false
25+
config.cache_store = :null_store
2426

2527
# Raise exceptions instead of rendering exception templates.
2628
config.action_dispatch.show_exceptions = false
2729

2830
# Disable request forgery protection in test environment.
2931
config.action_controller.allow_forgery_protection = false
3032

31-
# Store uploaded files on the local file system in a temporary directory
33+
# Store uploaded files on the local file system in a temporary directory.
3234
config.active_storage.service = :test
3335

3436
config.action_mailer.perform_caching = false
@@ -41,6 +43,6 @@
4143
# Print deprecation notices to the stderr.
4244
config.active_support.deprecation = :stderr
4345

44-
# Raises error for missing translations
46+
# Raises error for missing translations.
4547
# config.action_view.raise_on_missing_translations = true
4648
end

config/initializers/content_security_policy.rb

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111
# policy.object_src :none
1212
# policy.script_src :self, :https
1313
# policy.style_src :self, :https
14+
# # If you are using webpack-dev-server then specify webpack-dev-server host
15+
# policy.connect_src :self, :https, "http://localhost:3035", "ws://localhost:3035" if Rails.env.development?
1416

1517
# # Specify URI for violation reports
1618
# # policy.report_uri "/csp-violation-report-endpoint"
@@ -19,6 +21,9 @@
1921
# If you are using UJS then enable automatic nonce generation
2022
# Rails.application.config.content_security_policy_nonce_generator = -> request { SecureRandom.base64(16) }
2123

24+
# Set the nonce only to specific directives
25+
# Rails.application.config.content_security_policy_nonce_directives = %w(script-src)
26+
2227
# Report CSP violations to a specified URI
2328
# For further information see the following documentation:
2429
# https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy-Report-Only
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Be sure to restart your server when you modify this file.
2+
#
3+
# This file contains migration options to ease your Rails 6.0 upgrade.
4+
#
5+
# Once upgraded flip defaults one by one to migrate to the new default.
6+
#
7+
# Read the Guide for Upgrading Ruby on Rails for more info on each option.
8+
9+
# Don't force requests from old versions of IE to be UTF-8 encoded.
10+
# Rails.application.config.action_view.default_enforce_utf8 = false
11+
12+
# Embed purpose and expiry metadata inside signed and encrypted
13+
# cookies for increased security.
14+
#
15+
# This option is not backwards compatible with earlier Rails versions.
16+
# It's best enabled when your entire app is migrated and stable on 6.0.
17+
# Rails.application.config.action_dispatch.use_cookies_with_metadata = true
18+
19+
# Change the return value of `ActionDispatch::Response#content_type` to Content-Type header without modification.
20+
# Rails.application.config.action_dispatch.return_only_media_type_on_content_type = false
21+
22+
# Return false instead of self when enqueuing is aborted from a callback.
23+
# Rails.application.config.active_job.return_false_on_aborted_enqueue = true
24+
25+
# Send Active Storage analysis and purge jobs to dedicated queues.
26+
# Rails.application.config.active_storage.queues.analysis = :active_storage_analysis
27+
# Rails.application.config.active_storage.queues.purge = :active_storage_purge
28+
29+
# When assigning to a collection of attachments declared via `has_many_attached`, replace existing
30+
# attachments instead of appending. Use #attach to add new attachments without replacing existing ones.
31+
# Rails.application.config.active_storage.replace_on_assign_to_many = true
32+
33+
# Use ActionMailer::MailDeliveryJob for sending parameterized and normal mail.
34+
#
35+
# The default delivery jobs (ActionMailer::Parameterized::DeliveryJob, ActionMailer::DeliveryJob),
36+
# will be removed in Rails 6.1. This setting is not backwards compatible with earlier Rails versions.
37+
# If you send mail in the background, job workers need to have a copy of
38+
# MailDeliveryJob to ensure all delivery jobs are processed properly.
39+
# Make sure your entire app is migrated and stable on 6.0 before using this setting.
40+
# Rails.application.config.action_mailer.delivery_job = "ActionMailer::MailDeliveryJob"
41+
42+
# Enable the same cache key to be reused when the object being cached of type
43+
# `ActiveRecord::Relation` changes by moving the volatile information (max updated at and count)
44+
# of the relation's cache key into the cache version to support recycling cache key.
45+
# Rails.application.config.active_record.collection_cache_versioning = true

0 commit comments

Comments
 (0)