instance method
to_s
Ruby on Rails 7.1.6
Since v7.0.10Signature
to_s()
No documentation comment.
Source
# File railties/lib/rails/generators/app_base.rb, line 402
def to_s
[
(comment.gsub(/^/, "# ").chomp + "\n" if comment),
("# " if commented_out),
"gem \"#{name}\"",
*Array(version).map { |constraint| ", \"#{constraint}\"" },
*options.map { |key, value| ", #{key}: #{value.inspect}" },
].compact.join
end
Defined in railties/lib/rails/generators/app_base.rb line 402
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in Rails::Generators::AppBase::GemfileEntry