Template Generator:
Usage
Use this for generating a file on some template.
Before start using please change the please mention your template folder path in the config.py file.
For adding template in your template file, use the template extension. For example py1.template is a template file.
Commands :
- For listing all templates use
-lflag.
templategen -l
- For generating a file from a template use
-tflag for template name then the file name. for example:
templategen -t py1 test.py
- For adding a template use
-aflag for template name then the file name. for example:
templategen -a py1 test.py
The above command create a template named
py1.templatein your template folder withtest.pycontent.Use
--helpfor help.
templategen --help
Installation :
chmod +x main.py
sudo ln -s (pwd)/main.py /usr/bin/templategen
- This works for both
fishandbashshell.