So, I've finished making the autoprogram templater. I'll comment it better and clean up the code later, but it works as intended right now so I'm uploading it.
TODO: add more error messages and warnings and stuff for template syntax errors
TODO: general cleanup. (more comments, less stupid code, remove references to nonexistent methods.)
TODO: support parsing hex files to support writing to hex rom.
TODO: add support for basic escape characters like \n
TODO: allow (0){ ... } declarations.
TODO: have a check for endless recursive template calling. e.g. check for stoopid definitions.
usage: binScripter.py (sourcefile) (templatefile) (outputfile)
basic syntax etc:
Here's the code:
(v1.5) https://github.com/MagicalGentleman/binScripter
(This is a python 3 program)
TODO: add more error messages and warnings and stuff for template syntax errors
TODO: general cleanup. (more comments, less stupid code, remove references to nonexistent methods.)
TODO: support parsing hex files to support writing to hex rom.
TODO: add support for basic escape characters like \n
TODO: allow (0){ ... } declarations.
TODO: have a check for endless recursive template calling. e.g. check for stoopid definitions.
usage: binScripter.py (sourcefile) (templatefile) (outputfile)
basic syntax etc:
Here's the code:
(v1.5) https://github.com/MagicalGentleman/binScripter
(This is a python 3 program)