incentro-cli
v0.9.1
Published
With this CLI you can install a set a framework and a set of libraries of your choice. It provides you with the most popular frameworks such as React, Next, Vue, Angular and the most popular libraries: state managers, styling, linting, CMS's.
Readme
Getting Started
With this CLI you can install a set a framework and a set of libraries of your choice. It provides you with the most popular frameworks such as React, Next, Vue, Angular and the most popular libraries: state managers, styling, linting, CMS's.
Table of content
1.0.1 Quick start
In your terminal window
npx incentro-cli create
You will be prompt with series of questions such as:
? What is the name of your project directory? ›- Navigation with arrows :arrow_right: - to make a single choice :arrow_right:
? Pick your framework …
❯ React
NextJS
Vue
Nuxt
Hydrogen
Shopify-node? Pick your folder structure …
❯ None
Atomic Design- Navigation with checkmarks :white_check_mark: - to make multiple choice pressing white space :white_check_mark:
? Pick your libraries …
✔ Contentful
✔ Storyblok
✔ Eslint
✔ Prettier
✔ Jest
✔ Cypress
✔ Storybook
✔ Sass
✔ Tailwind
✔ Styled Components
✔ Graphql
✔ Apollo Graphql1.0.2 Permissions
It could happen that you have trouble running the npx incentro-cli command. This will most likely be related to the permissions on your device. To fix this, you can run the following command:
chmod +x /opt/homebrew/bin/incentro-cliIf your path is different than opt/homebrew/, you can change the path.
For the tailored start set up we recommend using commander command line.
Use flags which correspond to different options to explicitly specify location, framework or library
For example:
npx incentro-cli -D test-dir -F react -L tailwind eslint
Specify libs after -L flag separated with spaces
You can skip a step if you want
Configuring CMS
With our CLI tool you can install a preferred CMS. If you choose for it you will have to fill in the form providing tokens and space name (for Contentful).
CMS will be installed after the installation of the main framework
? Please provide the following information:
⊙ Contentful space :
⊙ Access token : …
⊙ Preview host : …2.0.2 To know all possible flags
npx incentro-cli help
Usage: index [options] [command]
to create a project combining several options [example: npx incentro-cli -D my_project -F react -L redux tailwind]
Options:
-D, --directory <directory> Project directory
-F, --framework <framework> Framework [react, next]
-S, --structure <structure> Project structure [none, atomic]
-L, --libs <libs...> Selection of all libraries [Eslint, Contentful, Prettier]
-h, --help display help for command
Commands:
create create a new project
list|ls [options] list of available frameworks and libraries2.0.3. Folder structure
You can go with the original folder structure based on your choice or go for an atomic design folder structure.
To read more about atomic design
2.0.4. Available frameworks and libraries
In your terminal window
npx incentro-cli list
Framework options
------------------
React
NextJS
Vue
Nuxt
Hydrogen
Shopify-node
Store management systems
------------------
Redux
React Query
Graphql
Apollo Graphql
Styling system
------------------
Sass
Tailwind
Styled Components
Content management systems
------------------
Contentful
Storyblok
Testing tools
------------------
Jest
Cypress
Storybook
Linting tools
------------------
Eslint
Prettier3.0.1 This CLI is built with
This CLI is built with NodeJS, Enquirer and Commander.
We use "fs" and "fs-extra" libraries to create files and directories, as well as copy and merge files.
Here are some main functions
| Function name | Description |
| ---------------- | --------------------------------------- |
| copyFile() | Copy your file to a destination |
| createFile() | Create a file in a destination |
| createFolder() | Create a folder in a destination |
| mergeFiles() | Can be used to merge two files together |
