DEV Community


Posted on


How to validate cloudformation templates on your computer?

Liquid syntax error: 'raw' tag was never closed

Top comments (1)

ferricoxide profile image
Thomas H Jones II

Even before I get to the point of letting AWS validate my templates, I usually run them through a local de-linter. Either jq or Python's json.tool module works a trick:

  • jq --exit-status . <FILENAME>
  • python -m json.tool <FILENAME>

Takes care of basic syntax checking. Both also work well inside a CI testing-rule (e.g., a .travis.yml file). Which means you can set up a git-trigger to only allow a branch-merge when a basic syntax check passes.

Timeless DEV post...

Git Concepts I Wish I Knew Years Ago

The most used technology by developers is not Javascript.

It's not Python or HTML.

It hardly even gets mentioned in interviews or listed as a pre-requisite for jobs.

I'm talking about Git and version control of course.

One does not simply learn git