https://github.com/alexcoder04/nspire-merge
Merging Lua source files and resources for TI-Nspire projects
https://github.com/alexcoder04/nspire-merge
calculator lua nspire nspired-lua python ti-nspire ti-nspire-calculators
Last synced: about 1 year ago
JSON representation
Merging Lua source files and resources for TI-Nspire projects
- Host: GitHub
- URL: https://github.com/alexcoder04/nspire-merge
- Owner: alexcoder04
- License: mit
- Created: 2021-12-30T13:33:46.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2022-12-19T10:20:13.000Z (over 3 years ago)
- Last Synced: 2025-02-09T08:23:12.852Z (about 1 year ago)
- Topics: calculator, lua, nspire, nspired-lua, python, ti-nspire, ti-nspire-calculators
- Language: Python
- Homepage:
- Size: 8.79 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# nspire-merge
This Python script merges multiple Lua source files and images into one Lua file for
TI-Nspire projects.
This project is inspired by [DaveDuck321](https://github.com/DaveDuck321)'s
[TI-Resource-Merge](https://github.com/DaveDuck321/TI-Resource-Merge) (MIT license)
and uses its image conversion mechanism, however the rest was re-written from
scratch to provide a more stable CLI interface and more options.
The generated file can be either pasted into TI Student Software or be compiled
using [Luna](https://github.com/ndless-nspire/Luna).
## Usage
```text
usage: nspire-merge [-h] [--resources RESOURCES] [--out OUT] [--strip] [--api-version API_VERSION] input_files [input_files ...]
positional arguments:
input_files specify input files
options:
-h, --help show this help message and exit
--resources RESOURCES
load images from folder (default 'res/')
--out OUT write output to file (default 'out.lua')
--strip strip out blank lines and comments
--api-version API_VERSION
specify api version (default '2.2')
```
**Note:** api version `2.2` is the last version that supports inline-images. For
newer versions, you would need to paste the code into the TI Student Software
and import images manually.
## Installation
### Requirements
- `PIL` / `Pillow`
Can be installed using `make deps`.
### Installing through the AUR on Arch Linux
This project is available on the AUR as [`nspire-merge`](https://aur.archlinux.org/packages/nspire-merge).
Either install it manually or use an AUR helper of your choice.
### Install using `make`
Install the script to `/usr/local/bin`:
> `sudo make install`
### Uninstalling
`sudo make uninstall` or `sudo rm -vi /usr/local/bin/nspire-merge /usr/local/share/man/man1/nspire-merge`.