paint-brush
Meta CLI Creation Using Create New CLIby@dabit3
778 reads
778 reads

Meta CLI Creation Using Create New CLI

by Nader DabitJune 10th, 2017
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

To get started, check out the repo <a href="https://github.com/dabit3/create-new-cli" target="_blank">here</a>.

People Mentioned

Mention Thumbnail

Companies Mentioned

Mention Thumbnail
Mention Thumbnail
featured image - Meta CLI Creation Using Create New CLI
Nader Dabit HackerNoon profile picture

I’m pretty excited to be introducing a new project I have been working on called [create-new-cli.](https://github.com/dabit3/create-new-cli)

To get started, check out the repo here.

With the rise in the popularity of projects like Create React App, Angular CLI, and Ionic CLI, as well as the productivity these CLIS bring to the table, there should be an easy way for developers to create their own CLI using boilerplates and also to introduce them to the world of CLI creation.

With Create New CLI, you can easily create your own CLI with just a couple of commands and a base project, and then add on to and polish your CLI using the generated project.

To get started, check out this video or follow the directions below.

To create your own CLI:

  1. Install create-new-cli globally

npm i -g create-new-cli

2. type create-new-cli and follow the commands

create-new-cli

In the above step, we will create a name and a command for our cli. The name will be the folder created for our project, and the command will be what the application is registered as in the npm registry, which will be the name field in our newly created package.json.

We will reference these two items as <YourProjectName> and <your-project-command> in the following steps.

3. CD into newly created project directory

cd <YourProjectName>

4. Publish to npm (or link to test locally)

npm publish OR npm link

5. Install new cli globally on your own machine (skip this step if you ran npm link)

npm i -g <your-project-command>

6. Create new application using your new CLI

<your-project-command> MyAppName

I hope to see people build a lot of cool stuff with this!

My Name is Nader Dabit . I am a software consultant and trainer and the founder of React Native Training where we teach developers at top companies around the world how to quickly get up and running with React Native.

If you like React and React Native, checkout out our podcast — React Native Radio on Devchat.tv.

Also, check out my book, React Native in Action now available from Manning Publications

If you enjoyed this article, please recommend and share it! Thanks for your time