ndless-nspire / Luna

Create TNS files from Lua and XML
Other
57 stars 13 forks source link

Add support for Python scripts #22

Closed Legimet closed 1 month ago

Legimet commented 2 months ago

I've added support for Python scripts. You can add multiple Python files. The first one specified will be the one that shows up when the TNS document is opened.

Should I add some code to validate the filename? I believe the part before the .py extension cannot exceed 237 characters, and must be a valid Python identifier (only alphanumeric/underscore characters, can't start with a digit, can't be a reserved word).

Vogtinator commented 1 month ago

Code looks good, I also verified that the output of ndless/calcbin remains identical.

I actually wanted to squash merge instead of rebase merge, but that shouldn't matter much anyway :shrug:

adriweb commented 1 month ago

Just mentioning here that thanks to this PR, I've now added support for TI-Nspire CX II python scripts to TI-Planet's Project Builder, thanks :)