@locofy/cli
v0.0.127
Published
Locofy CLI
Maintainers
Readme
Locofy CLI
Locofy CLI is a command-line tool designed to generate code component bundles for your projects and integrate them seamlessly with AI assistance. This README provides comprehensive instructions for installing and using the Locofy CLI.
Details about Locofy Custom components: Locofy Documentation
Installation
npm install @locofy/cli -gAuthentication
Before using the CLI, you need to authenticate with your Locofy account.
Login
Log in to your Locofy account. This will open a browser window for authentication.
locofy loginLogout
Log out of your Locofy account.
locofy logoutSetup
Init
Initialize the Locofy configuration in your project. This creates a locofy.config.json file.
locofy initOptions:
--url <url>: Use a custom API URL (e.g.,locofy init --url https://custom-domain.dev).
Syncing Components
Push
Push your local custom components to Locofy for use in the Builder.
locofy pushCode Generation & Integration
Locofy CLI provides powerful tools to pull, download, and integrate generated code into your codebase.
Pull (Recommended)
The pull command is the all-in-one workflow that retrieves generated code and intelligently integrates it into your project using AI. It combines downloading and integration into a single step.
locofy pull [codeId]Options:
-p, --project <id>: Locofy Project ID.-t, --target <path>: Target project directory (default:.).--resume: Resume an interrupted session.--skip-asking: Allow all permissions/confirmations without asking.
Help
Get detailed help for any command.
locofy pull --helpMaintenance
Clear
Clear all cached information by deleting the .locofy folder. This fixes issues related to corrupted cache or session data.
locofy clearContributing
If you would like to contribute to the development of Locofy CLI, please follow these steps:
- Fork this repository.
- Run commands:
npm run installnpm run link- Create a new branch for your feature or bug fix.
- Make your changes and commit them with descriptive messages.
- Push your changes to your fork.
- Submit a pull request to the
mainbranch of this repository.
