Docs for version v0.6.x.
Nodecaf CLI contains a series of useful tools and code generation for the use of Nodecaf Framework. Using Nodecaf CLI you'll be able to:
- Run your application via command line or containers.
- Generate a basic Nodecaf project structure.
npm i -g nodecaf-cli
If you have found any problems with this module, please:
- Open an issue.
- Describe what happened and how.
- Also in the issue text, reference the label
~bug
.
We will make sure to take a look when time allows us.
If you wish to get that awesome feature or have some advice for us, please:
- Open an issue.
- Describe your ideas.
- Also in the issue text, reference the label
~proposal
.
If you have spotted any enhancements to be made and is willing to get your hands dirty about it, fork us and submit your merge request so we can collaborate effectively.
Check a brief description of how to use the available commands.
-
-v --version
: Outputs the currently installed version of Nodecaf CLI. -
-h --help
: Outputs the complete command reference.
nodecaf run
Executes the Nodecaf app installed in the specified directory.
Options
-
-c --conf [file]
: Conf file path (supports multiple eg.:-c ./foo.toml -c ./bar.toml
)
Arguments
-
APP_PATH
: The path to your app's module directory or main js file.
nodecaf init
Generates a base Nodecaf project file structure in the current
directory.
Options
-
--bare
: When present will generate only js files -
--bin
: When present will generate a npm binary file to run the app -
-r --reload
: When present will trigger a full app reload when files change. Don't use in production! -
-c --conf json|yml|toml
: Type of config file to be used in the project -
-p --path [directory]
: Project root directory (defaults to working dir) -
--mongo
: When present will install and generate code for mongo integration -
--redis
: When present will install and generate code for redis integration -
--docker node22|slim
: Which Docker Image variant to use in the generated Dockerfile. Defaults to regular image
Arguments
-
APP_NAME
: The name to be used for the app all across the generated files.