Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@ AllCops:
Exclude:
# These have been copied from the Rails repo
- test/unit/behaviors/*
# Don't second guess the generated schemas
- test/dummy/*
# Don't rubocop generated files
- test/dummy/**/*
- bin/*
- '**/tmp/**/*'
- '**/vendor/**/*'
- '**/node_modules/**/*'
Expand Down
2 changes: 1 addition & 1 deletion bin/irb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)
bundle_binstub = File.expand_path("bundle", __dir__)

if File.file?(bundle_binstub)
if File.read(bundle_binstub, 300).include?("This file was generated by Bundler")
if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
load(bundle_binstub)
else
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
Expand Down
2 changes: 0 additions & 2 deletions bin/rails
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

# This command will automatically be run when you run "rails" with Rails gems
# installed from the root of your application.

Expand Down
2 changes: 1 addition & 1 deletion bin/rake
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)
bundle_binstub = File.expand_path("bundle", __dir__)

if File.file?(bundle_binstub)
if File.read(bundle_binstub, 300).include?("This file was generated by Bundler")
if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
load(bundle_binstub)
else
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
Expand Down
2 changes: 1 addition & 1 deletion bin/rdbg
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)
bundle_binstub = File.expand_path("bundle", __dir__)

if File.file?(bundle_binstub)
if File.read(bundle_binstub, 300).include?("This file was generated by Bundler")
if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
load(bundle_binstub)
else
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
Expand Down
4 changes: 0 additions & 4 deletions bin/release
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@ fi

printf "module SolidCache\n VERSION = \"$VERSION\"\nend\n" > ./lib/solid_cache/version.rb
bundle
for gemfile in gemfiles/rails_*.gemfile
do
echo BUNDLE_GEMFILE=$gemfile bundle
done
git add Gemfile.lock lib/solid_cache/version.rb
git commit -m "Bump version for $VERSION"
git push
Expand Down
2 changes: 1 addition & 1 deletion bin/rubocop
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)
bundle_binstub = File.expand_path("bundle", __dir__)

if File.file?(bundle_binstub)
if File.read(bundle_binstub, 300).include?("This file was generated by Bundler")
if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
load(bundle_binstub)
else
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
Expand Down
2 changes: 0 additions & 2 deletions test/dummy/Rakefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.

Expand Down
2 changes: 0 additions & 2 deletions test/dummy/app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
# frozen_string_literal: true

class ApplicationController < ActionController::Base
end
2 changes: 0 additions & 2 deletions test/dummy/app/jobs/application_job.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

class ApplicationJob < ActiveJob::Base
# Automatically retry jobs that encountered a deadlock
# retry_on ActiveRecord::Deadlocked
Expand Down
2 changes: 0 additions & 2 deletions test/dummy/app/models/application_record.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

class ApplicationRecord < ActiveRecord::Base
primary_abstract_class
end
Empty file.
2 changes: 0 additions & 2 deletions test/dummy/bin/rails
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

APP_PATH = File.expand_path("../config/application", __dir__)
require_relative "../config/boot"
require "rails/commands"
2 changes: 0 additions & 2 deletions test/dummy/bin/rake
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

require_relative "../config/boot"
require "rake"
Rake.application.run
2 changes: 0 additions & 2 deletions test/dummy/bin/setup
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

require "fileutils"

# path to your application root.
Expand Down
2 changes: 0 additions & 2 deletions test/dummy/config.ru
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# This file is used by Rack-based servers to start the application.

require_relative "config/environment"
Expand Down
2 changes: 0 additions & 2 deletions test/dummy/config/application.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

require_relative "boot"

require "rails/all"
Expand Down
2 changes: 0 additions & 2 deletions test/dummy/config/boot.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

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

Expand Down
2 changes: 0 additions & 2 deletions test/dummy/config/environment.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# Load the Rails application.
require_relative "application"

Expand Down
2 changes: 0 additions & 2 deletions test/dummy/config/environments/development.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

require "active_support/core_ext/integer/time"

Rails.application.configure do
Expand Down
3 changes: 0 additions & 3 deletions test/dummy/config/environments/test.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

require "active_support/core_ext/integer/time"

# The test environment is used exclusively to run your application's
Expand Down Expand Up @@ -35,7 +33,6 @@
# Disable request forgery protection in test environment.
config.action_controller.allow_forgery_protection = false


# Print deprecation notices to the stderr.
config.active_support.deprecation = :stderr

Expand Down
2 changes: 0 additions & 2 deletions test/dummy/config/initializers/assets.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# Be sure to restart your server when you modify this file.

# Version of your assets, change this if you want to expire all your assets.
Expand Down
1 change: 0 additions & 1 deletion test/dummy/config/initializers/content_security_policy.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# frozen_string_literal: true
# Be sure to restart your server when you modify this file.

# Define an application-wide content security policy.
Expand Down
2 changes: 0 additions & 2 deletions test/dummy/config/initializers/filter_parameter_logging.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# Be sure to restart your server when you modify this file.

# Configure parameters to be filtered from the log file. Use this to limit dissemination of
Expand Down
1 change: 0 additions & 1 deletion test/dummy/config/initializers/inflections.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# frozen_string_literal: true
# Be sure to restart your server when you modify this file.

# Add new inflection rules using the following format. Inflections
Expand Down
1 change: 0 additions & 1 deletion test/dummy/config/initializers/permissions_policy.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# frozen_string_literal: true
# Define an application-wide HTTP permissions policy. For further
# information see https://developers.google.com/web/updates/2018/06/feature-policy
#
Expand Down
2 changes: 0 additions & 2 deletions test/dummy/config/puma.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# Puma can serve each request in a thread from an internal thread pool.
# The `threads` method setting takes two numbers: a minimum and maximum.
# Any libraries that use thread pools should be configured to match
Expand Down
2 changes: 0 additions & 2 deletions test/dummy/config/routes.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

Rails.application.routes.draw do
mount SolidCache::Engine => "/solid_cache"
end
3 changes: 1 addition & 2 deletions test/dummy/db/primary_shard_one_schema.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition.
Expand All @@ -19,4 +17,5 @@
t.datetime "created_at", null: false
t.index ["key"], name: "index_solid_cache_entries_on_key", unique: true
end

end
3 changes: 1 addition & 2 deletions test/dummy/db/primary_shard_two_schema.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition.
Expand All @@ -19,4 +17,5 @@
t.datetime "created_at", null: false
t.index ["key"], name: "index_solid_cache_entries_on_key", unique: true
end

end
3 changes: 1 addition & 2 deletions test/dummy/db/schema.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition.
Expand All @@ -19,4 +17,5 @@
t.datetime "created_at", null: false
t.index ["key"], name: "index_solid_cache_entries_on_key", unique: true
end

end
3 changes: 1 addition & 2 deletions test/dummy/db/secondary_shard_one_schema.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition.
Expand All @@ -19,4 +17,5 @@
t.datetime "created_at", null: false
t.index ["key"], name: "index_solid_cache_entries_on_key", unique: true
end

end
3 changes: 1 addition & 2 deletions test/dummy/db/secondary_shard_two_schema.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

# This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition.
Expand All @@ -19,4 +17,5 @@
t.datetime "created_at", null: false
t.index ["key"], name: "index_solid_cache_entries_on_key", unique: true
end

end