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