@gwigz/slua-create
v0.6.0
Published
Scaffold new TSTL-powered SLua projects
Readme
@gwigz/slua-create
Scaffold new TSTL-powered SLua projects.
Usage
npx @gwigz/slua-create
# or
pnpm dlx @gwigz/slua-create
# or
bunx @gwigz/slua-createYou can also pass a directory as the first argument:
npx @gwigz/slua-create my-project
# or
pnpm dlx @gwigz/slua-create my-project
# or
bunx @gwigz/slua-create my-projectOptions
-t, --template <single|multi> project template (default: single)
-e, --extras <list> comma-separated extras, or "none"; repeatable
--git / --no-git initialize a git repository (default: git)
--install / --no-install install dependencies (default: install)
-y, --yes accept defaults for all unanswered prompts
-h, --help show this help
-v, --version show versionAny option answered by a flag is skipped when prompting. With --yes (or when
not attached to a terminal, e.g. in CI) no prompts are shown, and the
directory argument is required:
npx @gwigz/slua-create my-project -y -t multi -e config,yield --no-gitTemplates
- Single script provides one
main.ts, that outputs a single script - Multi-script provides a custom
build.tsthat can build mutiple scripts
Extras
| Extra | Description | | ----------------- | ------------------------------------------------------------------------------------------------------------------------------------------------ | | JSX templates | @gwigz/jsx-inline | | Config module | @gwigz/slua-modules/config | | Utilities module | @gwigz/slua-modules/utilities | | Yield module | @gwigz/slua-modules/yield | | StyLua formatting | Lua output formatting via StyLua | | Linting | TypeScript linting via oxlint with @gwigz/slua-oxlint-config | | Formatting | TypeScript formatting via oxfmt |
Documentation
Full API reference and usage examples are available at slua.gwigz.link/docs/create.
