From 34a9f975168d1bde71aa05f98f3f324eb8c061bc Mon Sep 17 00:00:00 2001 From: ihabadham Date: Mon, 29 Sep 2025 19:09:03 +0300 Subject: [PATCH 1/3] Fix node_package rake task for workspace structure MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use yarn yalc publish instead of yalc publish to work with private workspace root introduced in PR #1830. �� Generated with Claude Code Co-Authored-By: Claude --- rakelib/node_package.rake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rakelib/node_package.rake b/rakelib/node_package.rake index b6e2d71574..2f617a61e5 100644 --- a/rakelib/node_package.rake +++ b/rakelib/node_package.rake @@ -7,7 +7,7 @@ namespace :node_package do task :build do puts "Building Node Package and running 'yalc publish'" - sh "yarn run build && yalc publish" + sh "yarn run build && yarn yalc publish" end end From 330ba112225dc7792826797ebfdfce450fa0393a Mon Sep 17 00:00:00 2001 From: ihabadham Date: Mon, 29 Sep 2025 19:09:45 +0300 Subject: [PATCH 2/3] Fix shakapacker_examples rake task issues MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Add missing space in rails_options concatenation - Use npm install instead of yarn to match Shakapacker's default 🤖 Generated with Claude Code Co-Authored-By: Claude --- rakelib/shakapacker_examples.rake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rakelib/shakapacker_examples.rake b/rakelib/shakapacker_examples.rake index c17f2f8e0a..ade3d61ed8 100644 --- a/rakelib/shakapacker_examples.rake +++ b/rakelib/shakapacker_examples.rake @@ -29,7 +29,7 @@ namespace :shakapacker_examples do # rubocop:disable Metrics/BlockLength task example_type.gen_task_name_short => example_type.clobber_task_name do puts "Running shakapacker_examples:#{example_type.gen_task_name_short}" mkdir_p(example_type.dir) - example_type.rails_options += "--skip-javascript" + example_type.rails_options += " --skip-javascript" sh_in_dir(examples_dir, "rails new #{example_type.name} #{example_type.rails_options}") sh_in_dir(example_type.dir, "touch .gitignore") sh_in_dir(example_type.dir, @@ -38,7 +38,7 @@ namespace :shakapacker_examples do # rubocop:disable Metrics/BlockLength bundle_install_in(example_type.dir) sh_in_dir(example_type.dir, "rake shakapacker:install") sh_in_dir(example_type.dir, example_type.generator_shell_commands) - sh_in_dir(example_type.dir, "yarn") + sh_in_dir(example_type.dir, "npm install") end end From 944476821a07d3b36a93dc5b1e78aebcd25bd0eb Mon Sep 17 00:00:00 2001 From: ihabadham Date: Mon, 29 Sep 2025 19:43:24 +0300 Subject: [PATCH 3/3] Refactor: append --skip-javascript inline instead of mutating rails_options MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Follows coderabbit's suggestion to avoid mutating the @rails_options instance variable, preventing potential option duplication issues. - More functional/immutable approach - Cleaner and more explicit intent - Prevents potential future bugs from state mutation 🤖 Generated with Claude Code Co-Authored-By: Claude --- rakelib/shakapacker_examples.rake | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/rakelib/shakapacker_examples.rake b/rakelib/shakapacker_examples.rake index ade3d61ed8..165bbfc0d2 100644 --- a/rakelib/shakapacker_examples.rake +++ b/rakelib/shakapacker_examples.rake @@ -29,8 +29,7 @@ namespace :shakapacker_examples do # rubocop:disable Metrics/BlockLength task example_type.gen_task_name_short => example_type.clobber_task_name do puts "Running shakapacker_examples:#{example_type.gen_task_name_short}" mkdir_p(example_type.dir) - example_type.rails_options += " --skip-javascript" - sh_in_dir(examples_dir, "rails new #{example_type.name} #{example_type.rails_options}") + sh_in_dir(examples_dir, "rails new #{example_type.name} #{example_type.rails_options} --skip-javascript") sh_in_dir(example_type.dir, "touch .gitignore") sh_in_dir(example_type.dir, "echo \"gem 'react_on_rails', path: '#{relative_gem_root}'\" >> #{example_type.gemfile}")