Can I use something like templates with bash?

Bash does not have any native way to use templates. However, depending on your actual goals, just evaluating the file with a new bash or shell instance could do the trick.

This is further discussed on the TemplateFiles page

BashFAQ/110 (last edited 2013-03-18 18:07:40 by 12)