| JANET-PM(1) | General Commands Manual | JANET-PM(1) |
NAME
janet-pm - the Janet Project Manager, a build tool for Janet
SYNOPSIS
janet-pm [--flag ...] [--option=value ...] command args...
DESCRIPTION
Run from a directory containing a project.janet file to perform operations on a project, or from anywhere to do operations on the global module cache (modpath). Commands that need write permission to the modpath are considered privileged commands - in some environments they may require super user privileges. Other project-level commands need to have a ./project.janet file in the current directory.
DOCUMENTATION
GLOBAL COMMANDS
- help
- Show this help text.
- install [repo...]
- Install remote bundles, and any required dependencies.
- clear-cache
- Clear the cache of saved remote dependencies.
- list-pkgs [search]
- List packages in the remote package listing that contain the string search. If no search pattern is given, prints the entire package listing.
- env name
- Create an environment with which one can install Janet dependencies and scripts in an isolated manner.
- new-project [name]
- Create a new Janet project in a directory `name`.
- new-simple-project [name]
- Create a new Janet project that can be installed and distributed without spork in a directory `name`.
- new-c-project [name]
- Create a new C+Janet project in a directory `name`.
- new-exe-project [name]
- new-exe-project name Create a new project for an executable in a directory `name`.
PER-PROJECT COMMANDS
- deps
- Install dependencies for the current project.
- install [repos...]
- Install artifacts of the current project. Shorthand for `janet --install .`
- uninstall [repos...]
- Uninstall the current project's artifacts. Shorthand for `janet --uninstall {current-project-name}`
- prune
- Remove any bundles that have no dependents and are marked for auto-remove.
- build
- Build all artifacts of the project. The build configuration is determined by JANET_BUILD_TYPE, and the location of artifacts will by in the JANET_BUILD_DIR directory.
- clean
- Remove any generated files or artifacts. Calls the `(clean)` hook.
- test
- Run tests. Tests should be .janet files in the test/ directory relative to project.janet. Will patch the module paths to load built native code without installing it. Shorthand for `run check`.
- quickbin [entry] [output]
- Create an executable file from a script, statically linking in any dependencies found while compiling the script. The script should contain a main function that will serve as the main function for the generated executable.
- save-lockfile [destination]
- Save all currently installed bundles to a lockfile.
- load-lockfile [source]
- Install all bundles in the given lockfile.
ENVIRONMENT VARIABLES
janet-pm inherits all of the environment variables used by janet, as well some of its own. Many of these are only used in support of building bundles that use a project.janet.
JANET_BUILD_DIR
JANET_BUILD_TYPE
JANET_CURL
JANET_GIT
JANET_OFFLINE
JANET_PKGLIST
JANET_PREFIX
JANET_TAR
JANET_TOOLCHAIN
VERBOSE
WORKERS