1.0.13 • Published 3 years ago

coffeeformation v1.0.13

Weekly downloads
52
License
Apache-2.0
Repository
github
Last release
3 years ago

Coffeeformation :coffee::factory:

A Coffeescript DSL to describe your AWS CloudFormation stacks. CloudFormation already allows you to describe your infrastructure using JSON or YAML data. Coffeeformation takes the next step by enabling code structures like file includes, comments, helper functions, and loops.

The tool

Coffeeformation is available as a lightweight command line tool published to npm. Installation is straightforward:

npm install -g coffeeformation

There are a couple subcommands:

  • coffeeform compile evaluates the specified files (*.coffee by default) in the current directory and, for those containing a valid CoffeeFormation stack, generates matching CloudFormation JSON output files. This is the default mode, so there's a shorthand: simply coffeeform.
  • coffeeform decompile is the opposite: It will take your existing CloudFormation JSON files (*.cf, *.json) in the current directory and output valid Coffeeformation files. This lets you get started with Coffeeformation easily, by immediately converting your existing JSON templates into readable coffeescript syntax.

    Once you decompile a folder of stacks, simply edit the generated files and run coffeeform compile going forward to sync the changes back to the CloudFormation JSON.

Filenames starting with an underscore are skipped when processing the current directory. For example, you can have a _vpc.coffee file with shared VPC mapping data, and use require('./_vpc') in a neighboring Coffeeform stack to include that data.

You can also provide an explicit list of files to either subcommand. This overrides the directory scan for more advanced usage.

For available options and more CLI help, run coffeeform --help.

1.0.13

3 years ago

1.0.12

3 years ago

1.0.11

4 years ago

1.0.10

6 years ago

1.0.9

6 years ago

1.0.8

6 years ago

1.0.7

7 years ago

1.0.6

7 years ago

1.0.5

8 years ago

1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago