Skip to content
On this page

Getting Started

This section will help you learn how to use Magic-cli. If you already have an existing project and would like to keep project inside the project, start from Step 2.

TIP

Magic CLI is in Maintenance Mode Now!

In a recent update, we've refactored some of the functionality using clack, and we're going to develop some additional commands in the future, so stay tuned

Here are some screenshots:

Step. 1: Install Magic

Node Version Requirement

Magic CLI requires Node.js version above (v12+ recommended). You can manage multiple versions of Node on the same machine with n, nvm or nvm-windows.

To install the new package, use one of the following commands.

sh
$ npm install -g @vbs/magic-cli-core
# OR
$ yarn global add @vbs/magic-cli-core
# OR
$ pnpm install --global @vbs/magic-cli-core

If you are using zi,you can run the following command

sh
$ zi -g @vbs/magic-cli-core

TIP

When NPM installs packages such as electron and puppeter, they will download the corresponding binary files through the postinstall script. For some unknown reasons, this process may be slow or unavailable in some networks. You can copy the following configuration to . Bashrc or . Zshrc, using npmmirror Com. The data is from binary mirror config.

You can check you have the right version with this command:

sh
magic --version

Step. 2: Checkout Magic works normally

You can use the following command to show Magic's features

sh
magic -h

Then you will see the following results:

Upgrading

To upgrade the global Magic CLI package, you need to run:

sh
npm update -g  @vbs/magic-cli-core

# OR
yarn global upgrade --latest  @vbs/magic-cli-core

# OR
pnpm update -g  @vbs/magic-cli-core

MIT Licensed