[ ] I've added tests (if it's a bug, feature or enhancement)
[ ] I've adjusted the documentation (if it's a feature or enhancement)
[ ] The test suite passes (run bundle exec rspec to verify this)
Summary
When creating a project with no plugin (i.e. using terraspace new project --plugin none infra) the Gemfile for the project contains a line with no name for the gem which makes it unparsable and stops the build process.
This PR wraps the plugin line with ERB if/end statements to avoid inserting the line if there is no plugin or if it wasn't found on the system.
Context
How to Test
Run terraspace new project --plugin none infra and check that infra/Gemfile doesn't contain a line with just gem
I couldn't build a local version to test this myself before creating this PR.
But I'll happily include a testcase to check the fix with some guidance as I haven't written a lot of Ruby.
This is a 🐞 bug fix.
bundle exec rspec
to verify this)Summary
When creating a project with no plugin (i.e. using
terraspace new project --plugin none infra
) the Gemfile for the project contains a line with no name for the gem which makes it unparsable and stops the build process.This PR wraps the plugin line with ERB
if/end
statements to avoid inserting the line if there is no plugin or if it wasn't found on the system.Context
How to Test
Run
terraspace new project --plugin none infra
and check that infra/Gemfile doesn't contain a line with justgem
I couldn't build a local version to test this myself before creating this PR. But I'll happily include a testcase to check the fix with some guidance as I haven't written a lot of Ruby.Version Changes