Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bundler] Adding frozen string literal comment to generated files #30

Open
diegous opened this issue Oct 27, 2020 · 0 comments
Open

[Bundler] Adding frozen string literal comment to generated files #30

diegous opened this issue Oct 27, 2020 · 0 comments

Comments

@diegous
Copy link

diegous commented Oct 27, 2020

Problem

When running bundle gem my_gem several files are created, none of which include # frozen_string_literal: true which is a default requirement of some linters like rubocop.

Solution

Include that line by default in generated ruby files (e.g. ), or add a flag to indicate the comment is desired in the new gem.

Some of the files that could include this line:

  • my_gem/lib/my_gem.rb
  • my_gem/lib/my_gem/version.rb
  • my_gem/spec/my_gem_spec.rb
  • my_gem/spec/spec_helper.rb

Note: This is a really small change, and might not even consider it an improvement so if there isn't too much support for this we can simply close it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant