kblomqvist / yasha

A command-line tool to render Jinja templates for great good
MIT License
243 stars 23 forks source link

YASHA_PATH environment variable for referenced templates #29

Open kblomqvist opened 6 years ago

kblomqvist commented 6 years ago

It might be handy to be able to set a path for referenced templates across all templates.

export YASHA_PATH=~/.yasha
nano ~/.yasha/base_template.j2
yasha -o output.txt template.j2
kblomqvist commented 6 years ago

Should we look for extensions.py from YASHA_PATH, instead of supporting YASHA_EXTENSIONS (#27).

@dfee what do you think about this? Would this be helpful?

kblomqvist commented 6 years ago

Well actually PATH should be able to contain several paths, like $HOME/.yasha:/usr/local/yasha.