A Command Line Interface for CEAN
This provides you a simple command line interface for application scaffolding. One of the advantages of using the CLI is that all the dependencie are installed locally with the CLI tool instead installing them globally to your Node.js installation.
A Linux/Unix/MacOS environment with Node.js, Npm, Make, Git and GCC has to be installed, e.g.:
sudo apt-get install gcc sudo apt-get install git sudo apt-get make sudo apt-get nodejs sudo apt-get nodejs-legacy sudo apt-get npm
From a release
npm install cean-cli
This installs 'cean-cli' to the folder '$HOME/node_modules/cean-cli'.
Via the source code
Check out the code:
git clone https://github.com/dmaier-couchbase/cean.git
Change the directory to:
Run the installation script:
How to use
The Cean CLI is bypassing specific commands. More details can be found here generator-cean.
The command 'start' is referring to 'grunt'. The commands 'create' and 'add' are referring to 'yo'.
The following examples assume that you have added the 'cean-cli' folder to your execution PATH
#Add to the end of your $HOME/.profile export PATH=$HOME/node_modules/cean-cli:$PATH
and that you are in an application directory of your choice:
Create a new application
The following command can be used to create a new application:
cean-cli create myapp
The following shows how to use sub-generators:
cean-cli add angular-controller TestCtrl myapp cean-cli add angular-view test cean-cli add angular-route test.html TestCtrl
Start the application