grammarly/rocker

throw error via rocker template

sudohalt opened this issue · 2 comments

There should be a template function that exits and throws an error. For example:

{{ if eq .id "a" }}
"config.file=a.xml"
{{ else if eq .id "b" }} 
"config.file=b.xml"
{{ else }}
  {{ error "invalid id" }} 

@sudohalt I made PoC for your issue. If you still need it, feel free to make some tests :)

Thanks for requesting. Unfortunately, we are discontinuing this project. See the notice here: https://github.com/grammarly/rocker/blob/master/README.md

Closing this issue as we are not able to implement it. Sorry.