-
Notifications
You must be signed in to change notification settings - Fork 10
v0.0.3 Commands
Log in to the Fleetbase registry. This command authenticates you with the Fleetbase registry by saving your credentials to your local .npmrc file.
flb login [options]-
-u, --username <username>: Username for the registry. -
-p, --password <password>: Password for the registry. -
-e, --email <email>: Email associated with your account. -
-r, --registry <registry>: Registry URL (default:https://registry.fleetbase.io). -
--scope <scope>: Scope for the registry (optional). -
--quotes <quotes>: Quotes option fornpm-cli-login(optional). -
--config-path <configPath>: Path to the npm config file (optional).
Log in with username, password, and email:
flb login -u your_username -p 'your_password' -e [email protected]Log in with a specific registry and scope:
flb login -u your_username -p 'your_password' -e [email protected] -r https://registry.fleetbase.io --scope '@fleetbase'- Ensure that special characters in your password are properly escaped or enclosed in quotes.
- The command updates your local
.npmrcfile with authentication details. - Handle your credentials securely and be cautious with password storage.
Create a bundle of your Fleetbase extension. This command packages your extension into a compressed archive suitable for distribution or uploading.
flb bundle [options]-
-p, --path <path>: Path of the Fleetbase extension (default:.). -
--upload: After bundling, upload the bundle to the Fleetbase registry using your authentication token. -
--auth-token <token>: Auth token for uploading the bundle (used with--uploadoption). -
-r, --registry <registry>: Registry URL (default:https://registry.fleetbase.io).
Create a bundle of the extension in the current directory:
flb bundleCreate a bundle and upload it to the registry:
flb bundle --uploadSpecify a custom path for the extension and upload:
flb bundle -p ./extensions/my-extension --upload --auth-token YOUR_AUTH_TOKEN- The command creates a
.tar.gzarchive of your extension, excluding certain directories likenode_modulesandserver_vendor. - If the
--uploadoption is used, the bundle will be uploaded after creation. - Ensure you have the necessary authentication token when using the
--uploadoption.
Upload a Fleetbase extension bundle to the Fleetbase registry. This command packages your extension and uploads it for distribution.
flb bundle-upload [bundleFile] [options]-
[bundleFile]: Path to the bundle file to upload. If not provided, it will look for the bundle in the current directory. -
-p, --path <path>: Path where the bundle is located (default:.). -
--auth-token <token>: Auth token for uploading the bundle. If not provided, the token will be read from the.npmrcfile. -
-r, --registry <registry>: Registry URL (default:https://registry.fleetbase.io).
Upload a bundle in the current directory:
flb bundle-uploadUpload a specific bundle file:
flb bundle-upload path/to/your-extension-bundle.tar.gzUpload a bundle with a specified auth token:
flb bundle-upload --auth-token YOUR_AUTH_TOKEN- The bundle should be created using the
flb bundlecommand. - The upload process handles the bundle as a
multipart/form-datarequest.
Bump the version of the Fleetbase extension. This command updates the version number in your extension's manifest files (extension.json, package.json, composer.json).
flb version-bump [options]-
-p, --path <path>: Path of the Fleetbase extension (default:.). -
--major: Bump major version (e.g.,1.0.0→2.0.0). -
--minor: Bump minor version (e.g.,1.0.0→1.1.0). -
--patch: Bump patch version (e.g.,1.0.0→1.0.1). This is the default if no flag is provided. -
--pre-release [identifier]: Add a pre-release identifier (e.g.,1.0.0→1.0.0-beta).
Bump the patch version (default behavior):
flb version-bumpBump the minor version:
flb version-bump --minorBump the major version:
flb version-bump --majorAdd a pre-release identifier:
flb version-bump --pre-release beta- The command updates version numbers in the specified files and formats them according to Semantic Versioning (SemVer).
- Ensure you commit your changes to version control after bumping the version.
- The default behavior increments the patch version if no flags are provided.
Scaffold a new Fleetbase extension. This command creates a new extension project with the necessary files and structure.
flb scaffold [options]-
--name <name>: Name of the extension. -
--description <description>: Description of the extension. -
--author <author>: Author's name. -
--email <email>: Author's email. -
-p, --path <path>: Path where the extension will be created (default: current directory). -
--repository <repository>: Git repository URL (optional).
Scaffold a new extension with basic information:
flb scaffold --name "My Extension" --description "An awesome Fleetbase extension" --author "John Doe" --email "[email protected]"Specify a custom path for the extension:
flb scaffold --name "My Extension" -p ./extensions/my-extension- The command initializes a new extension project by cloning the starter extension repository.
- Fill in the provided options to customize your new extension.
- After scaffolding, navigate to the extension directory and begin development.
-
Authentication: Use
flb loginto authenticate with the Fleetbase registry before performing actions like uploading bundles or publishing extensions. - Version Control: It's recommended to use a version control system like Git to manage your extension's source code.
- Publishing Extensions: After uploading your bundle, you can publish your extension to make it available to others (if applicable).
-
Help Command: Use
flb --helpto display help information about available commands.