Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcoder04 committed Dec 19, 2022
1 parent 66dd786 commit 33eb3c9
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 5 deletions.
14 changes: 11 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@

NAME = nspire-merge

SHELL = /bin/sh
RM = rm
PREFIX ?= /usr/local

deps:
pip install Pillow

install:
install -Dm755 ./nspire-merge "$(DESTDIR)$(PREFIX)/bin/nspire-merge"
install -Dm755 $(NAME) "$(DESTDIR)$(PREFIX)/bin/$(NAME)"
install -Dm644 $(NAME).1 "$(DESTDIR)$(PREFIX)/share/man/man1/$(NAME).1"

uninstall:
$(RM) "$(DESTDIR)$(PREFIX)/bin/nspire-merge"

$(RM) "$(DESTDIR)$(PREFIX)/bin/$(NAME)"
$(RM) "$(DESTDIR)$(PREFIX)/share/man/man1/$(NAME).1"
22 changes: 20 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

# nspire-merge

This Python script merges multiple Lua source files and images into one file for
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
Expand Down Expand Up @@ -36,5 +36,23 @@ and import images manually.

## Installation

`sudo make install` installs this script to `/usr/local/bin`.
### 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`.
37 changes: 37 additions & 0 deletions nspire-merge.1
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
.TH "nspire-merge" "1"

.SH "NAME"
.PP
nspire-merge - merging multiple Lua source files and images into one Lua file for TI-Nspire projects

.SH "SYNOPSIS"
.PP
shclrz [OPTIONS] [INPUT FILES ...]

.SH "OPTIONS"
.SS "-h, --help"
.PP
Print help.
.SS "--resources [RESOURCES]"
.PP
Load images from this folder (default "res/").
.SS "--out [OUT]
.PP
Specify file to write the output to (default "out.lua").
.SS "--strip"
.PP
Strips blank lines and comments.
.SS "--api-version [API VERSION]"
Specifies API version (default '2.2').

.SH "EXAMPLES"
.SS "nspire-merge --out myproject.lua -- main.lua gui.lua"
.PP
Generates "myproject.lua" from "main.lua" and "gui.lua" (in this order) and images from "res/".
.SS "nspire-merge --api-version 2.1 --strip -- *.lua"
.PP
Generates "out.lua" from all Lua files in the folder, strips all blank lines and comments from it and sets the API version to "2.1".

.SH "AUTHOR"
.PP
alexcoder04 (\fIhttps://github.com/alexcoder04/nspire-merge\fP)

0 comments on commit 33eb3c9

Please sign in to comment.