Shipping Components
The ship command is the core of the Tricox lifecycle. It analyzes your code, snapshots your files, and secures them in the registry.
Basic Usage
Pass the path to your entry component (e.g., a React component or an index file).
Command Flags
| Flag | Description |
|---|---|
| -n, --name | Explicit component name (default: filename) |
| -m, --message | Version message (git-style) |
| -v, --version | Override auto-versioning (e.g., 2.0.0) |
| --public | Make component available to the public gallery |
How it Works (Under the Hood)
1Static Graph Analysis
Tricox parses your code using a custom Babel AST explorer. It recursively finds all local imports and includes them in the component "Vessel". It also detects external NPM dependencies for auto-installation later.
2Content-Addressed Storage
Every file is hashed using SHA-1. If you ship a component where only one file changed, Tricox only uploads the changed file, saving bandwidth and space.
Smart Versioning
By default, Tricox uses SemVer auto-incrementing. If it detects no changes since the last upload, it will skip the version creation and inform you that your local code is already in the registry.
