Skip to content

Commit 8761d67

Browse files
committed
Fix running individual app:update commands
They require the app to be loaded as it calls Rails.application in the generator config.
1 parent be9aa73 commit 8761d67

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

railties/lib/rails/commands/app/update_command.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,22 +24,26 @@ def perform
2424

2525
desc "configs", "Update config files in the application config/ directory", hide: true
2626
def configs
27+
require_application!
2728
app_generator.create_boot_file
2829
app_generator.update_config_files
2930
end
3031

3132
desc "bin", "Add or update executables in the application bin/ directory", hide: true
3233
def bin
34+
require_application!
3335
app_generator.update_bin_files
3436
end
3537

3638
desc "public_directory", "Add or update files in the application public/ directory", hide: true
3739
def public_directory
40+
require_application!
3841
app_generator.create_public_files
3942
end
4043

4144
desc "active_storage", "Run the active_storage:update command", hide: true
4245
def active_storage
46+
require_application!
4347
app_generator.update_active_storage
4448
end
4549

0 commit comments

Comments
 (0)