← ClaudeAtlas

rails-load-defaultslisted

Incrementally upgrade Rails `config.load_defaults` by walking through each new_framework_defaults config one at a time. Use this skill whenever the user mentions load_defaults upgrade, new_framework_defaults, framework defaults, or wants to bring their Rails app's default configuration up to match their Rails version. Also trigger when the user mentions a gap between their Rails version and their load_defaults version (e.g., "app is on Rails 7.2 but load_defaults is 6.1"). This skill handles the iterative uncomment-test-commit workflow and the final consolidation into config/application.rb.
ombulabs/claude-code_rails-load-defaults-skill · ★ 17 · AI & Automation · score 78
Install: claude install-skill ombulabs/claude-code_rails-load-defaults-skill
# Rails load_defaults Upgrade Skill This skill guides the incremental upgrade of `config.load_defaults` in a Rails application. The process walks through each config introduced in a new Rails version, one at a time, so the user can test each change in isolation. ## Overview When a Rails app has a `load_defaults` version lower than its Rails version, there are framework default configs that need to be adopted. This skill: 1. Detects the current `load_defaults` version 2. Determines the next target version 3. Generates the `new_framework_defaults_X_Y.rb` initializer with all configs commented 4. Walks through each config one by one, analyzing the codebase to recommend values 5. Waits for the user to test/commit each change before moving to the next 6. Consolidates into `config/application.rb` when all configs are done ## Step 1: Detect Current State Read `config/application.rb` and look for: ```ruby config.load_defaults X.Y ``` Also check if a `config/initializers/new_framework_defaults_*.rb` file already exists (the user may be mid-upgrade). Report to the user: - Current `load_defaults` version - Current Rails version (from Gemfile.lock) - Which version transitions are needed (e.g., 6.1 → 7.0 → 7.1 → 7.2) ## Step 2: Load Version Config Reference Read the appropriate config reference file for the target version: - **5.0**: `configs/5_0.yml` - **5.1**: `configs/5_1.yml` - **5.2**: `configs/5_2.yml` - **6.0**: `configs/6_0.yml` - **6.1**: `configs/6_1.yml` - **7.0**: `