railties 6.0.0.beta3 → 6.0.2.rc2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +139 -8
- data/RDOC_MAIN.rdoc +3 -4
- data/README.rdoc +1 -1
- data/lib/rails/api/task.rb +1 -0
- data/lib/rails/application.rb +6 -3
- data/lib/rails/application/bootstrap.rb +2 -10
- data/lib/rails/application/configuration.rb +45 -1
- data/lib/rails/application/default_middleware_stack.rb +1 -0
- data/lib/rails/application/dummy_erb_compiler.rb +18 -0
- data/lib/rails/application/finisher.rb +44 -1
- data/lib/rails/autoloaders.rb +14 -2
- data/lib/rails/command/base.rb +4 -0
- data/lib/rails/command/environment_argument.rb +7 -4
- data/lib/rails/commands/console/console_command.rb +6 -0
- data/lib/rails/commands/credentials/USAGE +1 -1
- data/lib/rails/commands/credentials/credentials_command.rb +17 -3
- data/lib/rails/commands/dbconsole/dbconsole_command.rb +19 -7
- data/lib/rails/commands/dev/dev_command.rb +4 -2
- data/lib/rails/commands/encrypted/USAGE +28 -0
- data/lib/rails/commands/encrypted/encrypted_command.rb +1 -0
- data/lib/rails/commands/initializers/initializers_command.rb +7 -0
- data/lib/rails/commands/notes/notes_command.rb +1 -1
- data/lib/rails/commands/runner/runner_command.rb +7 -3
- data/lib/rails/commands/server/server_command.rb +8 -6
- data/lib/rails/engine.rb +35 -36
- data/lib/rails/engine/configuration.rb +3 -2
- data/lib/rails/gem_version.rb +2 -2
- data/lib/rails/generators.rb +2 -0
- data/lib/rails/generators/app_base.rb +5 -5
- data/lib/rails/generators/app_name.rb +2 -2
- data/lib/rails/generators/base.rb +4 -0
- data/lib/rails/generators/database.rb +1 -1
- data/lib/rails/generators/erb/scaffold/templates/_form.html.erb.tt +6 -3
- data/lib/rails/generators/erb/scaffold/templates/show.html.erb.tt +8 -0
- data/lib/rails/generators/generated_attribute.rb +36 -10
- data/lib/rails/generators/named_base.rb +1 -1
- data/lib/rails/generators/rails/app/app_generator.rb +1 -0
- data/lib/rails/generators/rails/app/templates/Gemfile.tt +4 -4
- data/lib/rails/generators/rails/app/templates/app/javascript/packs/application.js.tt +8 -0
- data/lib/rails/generators/rails/app/templates/bin/setup.tt +3 -2
- data/lib/rails/generators/rails/app/templates/config/databases/jdbcsqlite3.yml.tt +1 -1
- data/lib/rails/generators/rails/app/templates/config/databases/sqlite3.yml.tt +1 -1
- data/lib/rails/generators/rails/app/templates/config/environments/development.rb.tt +2 -0
- data/lib/rails/generators/rails/app/templates/config/environments/production.rb.tt +2 -0
- data/lib/rails/generators/rails/app/templates/config/environments/test.rb.tt +10 -4
- data/lib/rails/generators/rails/app/templates/config/initializers/content_security_policy.rb.tt +3 -0
- data/lib/rails/generators/rails/app/templates/config/initializers/new_framework_defaults_6_0.rb.tt +12 -0
- data/lib/rails/generators/rails/app/templates/config/puma.rb.tt +3 -0
- data/lib/rails/generators/rails/app/templates/gitignore.tt +1 -0
- data/lib/rails/generators/rails/app/templates/package.json.tt +3 -3
- data/lib/rails/generators/rails/app/templates/public/robots.txt +1 -1
- data/lib/rails/generators/rails/app/templates/ruby-version.tt +1 -1
- data/lib/rails/generators/rails/assets/assets_generator.rb +7 -0
- data/lib/rails/generators/rails/db/system/change/change_generator.rb +12 -2
- data/lib/rails/generators/rails/plugin/plugin_generator.rb +0 -15
- data/lib/rails/generators/rails/plugin/templates/gitignore.tt +1 -0
- data/lib/rails/generators/rails/scaffold_controller/scaffold_controller_generator.rb +14 -0
- data/lib/rails/generators/rails/scaffold_controller/templates/api_controller.rb.tt +1 -1
- data/lib/rails/generators/rails/scaffold_controller/templates/controller.rb.tt +1 -1
- data/lib/rails/generators/test_unit/model/templates/fixtures.yml.tt +2 -2
- data/lib/rails/generators/test_unit/scaffold/scaffold_generator.rb +7 -2
- data/lib/rails/info.rb +1 -1
- data/lib/rails/mailers_controller.rb +6 -3
- data/lib/rails/source_annotation_extractor.rb +19 -6
- data/lib/rails/tasks.rb +1 -0
- data/lib/rails/tasks/zeitwerk.rake +66 -0
- metadata +18 -13
- data/lib/rails/generators/rails/app/templates/bin/update.tt +0 -33
@@ -1,33 +0,0 @@
|
|
1
|
-
require 'fileutils'
|
2
|
-
|
3
|
-
# path to your application root.
|
4
|
-
APP_ROOT = File.expand_path('..', __dir__)
|
5
|
-
|
6
|
-
def system!(*args)
|
7
|
-
system(*args) || abort("\n== Command #{args} failed ==")
|
8
|
-
end
|
9
|
-
|
10
|
-
FileUtils.chdir APP_ROOT do
|
11
|
-
# This script is a way to update your development environment automatically.
|
12
|
-
# Add necessary update steps to this file.
|
13
|
-
|
14
|
-
puts '== Installing dependencies =='
|
15
|
-
system! 'gem install bundler --conservative'
|
16
|
-
system('bundle check') || system!('bundle install')
|
17
|
-
<% unless options.skip_javascript? -%>
|
18
|
-
|
19
|
-
# Install JavaScript dependencies
|
20
|
-
# system('bin/yarn')
|
21
|
-
<% end -%>
|
22
|
-
<% unless options.skip_active_record? -%>
|
23
|
-
|
24
|
-
puts "\n== Updating database =="
|
25
|
-
system! 'rails db:migrate'
|
26
|
-
<% end -%>
|
27
|
-
|
28
|
-
puts "\n== Removing old logs and tempfiles =="
|
29
|
-
system! 'rails log:clear tmp:clear'
|
30
|
-
|
31
|
-
puts "\n== Restarting application server =="
|
32
|
-
system! 'rails restart'
|
33
|
-
end
|