Repository: rails/rails
File: railties/lib/rails/generators/app_base.rb (Ruby)

Code before:
          GemfileEntry.floats "turbo-rails", "Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev]"

        stimulus_rails_entry =
          GemfileEntry.floats "stimulus-rails", "Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev]"

        [ turbo_rails_entry, stimulus_rails_entry ]
      end

      def using_importmap?
        !options.skip_javascript? && options[:javascript] == "importmap"
      end

      def using_js_runtime?
        !options.skip_javascript? && (!using_importmap? || (options[:css] && !%w[tailwind sass].include?(options[:css])))
      end

      def using_node?
        using_js_runtime? && !%w[bun].include?(options[:javascript])
      end

      def using_bun?
        using_js_runtime? && %w[bun].include?(options[:javascript])
      end

      def capture_command(command, pattern = nil)
        output = `#{command}`
        if pattern
          output[pattern]
        else
          output
        end
      rescue SystemCallError
        nil
      end

      def node_version
        if using_node?
          ENV.fetch("NODE_VERSION") do
            capture_command("node --version", /\d+\.\d+\.\d+/) || NODE_LTS_VERSION
          end
        end
      end

      def dockerfile_yarn_version
        capture_command("yarn --version", /\d+\.\d+\.\d+/) || "latest"
      end

      def yarn_through_corepack?
        using_node? and "#{dockerfile_yarn_version}" >= "2"
      end


Review comment (suggestion):
This is not correct. You can use the `tailwindcss-rails` gem without using CSS Bundling, and this change will not include the `tailwind.css` file that is generated after Tailwind does the build.

Code after:
          GemfileEntry.floats "turbo-rails", "Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev]"

        stimulus_rails_entry =
          GemfileEntry.floats "stimulus-rails", "Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev]"

        [ turbo_rails_entry, stimulus_rails_entry ]
      end

      def using_importmap?
        !options.skip_javascript? && options[:javascript] == "importmap"
      end

      def using_js_runtime?
        !options.skip_javascript? && (!using_importmap? || (options[:css] && !%w[tailwind sass].include?(options[:css])))
      end

      def using_node?
        using_js_runtime? && !%w[bun].include?(options[:javascript])
      end

      def using_bun?
        using_js_runtime? && %w[bun].include?(options[:javascript])
      end

      def using_css_bundling?
        options[:skip_asset_pipeline] || options[:css]
      end

      def capture_command(command, pattern = nil)
        output = `#{command}`
        if pattern
          output[pattern]
        else
          output
        end
      rescue SystemCallError
        nil
      end

      def node_version
        if using_node?
          ENV.fetch("NODE_VERSION") do
            capture_command("node --version", /\d+\.\d+\.\d+/) || NODE_LTS_VERSION
          end
        end
      end

      def dockerfile_yarn_version
        capture_command("yarn --version", /\d+\.\d+\.\d+/) || "latest"
      end