Nuts and Bolts

Everyone has opinions and thoughts. Here are some of ours.

Continuously Generate CloudFormation Templates with Lono and Guard

When using lono if you sometimes forgot to regenerate the templates after making changes you can use lono with guard to never have to remember again.

Setup lono and guard

If you have created a lono project with the lono new command then the Guardfile should have already been set up for you. Then all you have to do is run:

bundle exec guard

If you manually set up the lono project, then you can have to install the gem and setup the Guardfile. Add guard-lono to your Gemfile and run bundle. Then set up the Guardfile by running the following.

guard init lono
bundle exec guard

Watching lono and guard

Once guard is running you should see something like this:

$ bundle exec guard
[1] guard(main)>

As you edit and save any files in the templates or config folders, the lono generate command will automatically run 😊 Here’s what it looks like after I’ve saved some files twice: