I noticed that IntelliJ has syntax for "set", "if" and "foreach" statements to build file templates.
http://www.jetbrains.com/idea/webhelp/file-and-code-templates.html. However, it doesn't seem like this is possible with live templates. Am I doing something wrong, or do they just not have this support?
Basically I'm looking for the same functionality as TextMate's snippets. It would be nice to create a script that would generate or transform text exactly how I want using tools like bash, perl, python or php (but I'd settle for #if and #foreach if that's possible too). And it looks like the IntelliJ TextMate plugin doesn't support this either, so is there any other plugin that would accomplish this?
I figured out the answer to this. It looks like you can use Groovy scripts in live templates with the
groovyScript("groovy code")predefined function