3 ms·
I considered that just the other day. Ended up using cpp instead.
by e40 4y ago
I considered that just the other day. Ended up using cpp instead.
- imglorp 4y agoAnother simple option is envsubst which does one thing well.
- nick__m 4y agoI used envsubst when I can but as far as I know you cannot do loop using envsubst. When you use the c preprocessor or php, m4, etc..., you can.
- imglorp 4y agoNah, that's what I meant. It does $-expansion and that's it. If you need conditionals and loop you need templates and macros like others are saying: m4, cpp, handlebars, whatever. I use it as a low-brain template engine to do only that.
- morelisp 4y agoI use envsubst a lot, but without - and + forms it's hard to say it does it well.