This tool is used to make various tasks easier for developers working on Vanilla Forums core or addons.
Current functionalities include:
- Building frontend assets (scripts, stylesheets, and images)
- Generating cache files for addons
- Converting addons' info arrays to json
See the vanilla-cli docs for documentation about the different commands.
See our Installation Docs and our Quickstart Guide.r
- From the command line:
vanilla --help
or
vanilla SOME_COMMAND --help
- From other php applications:
require('{{VANILLA_CLI_DIRECTORY}}/vendor/autoload.php');
$cli = new \Vanilla\Cli\Cli();
try {
$cli->run($args); // Must be: array('vanilla', '{{COMMAND_NAME}}'[, options...])
} catch (Exception $e) {
...
}
More detailed usage documentation can be found at our official vanilla-cli docs.
- Getting Started
- Build Tools
- Addon Utilities
- Build Tool Quickstart Guide
- Build Process - Core
- Build Process - 1.0
- Build Process - Legacy
- How Bundling Works
Some of the node.js build processes have unit and integration tests. Be sure that these pass before making pull requests. To run the tests:
The NodeTools tests are run using jest.
$ cd src/NodeTools
$ yarn install
$ yarn test
# Or
$ yarn test --watch
During local development you main want to run a debugger. This is supported for the primary PHP process.
Ensure you IDE is properly configured for XDebug
.
How to setup PHPStorm for XDebug
Just export XDEBUG_CONFIG
from your shell, set up your IDE to listen for XDebug, and run your vanilla command.
export XDEBUG_CONFIG="idekey=PHPSTORM"
vanilla some-command --some-argument