@ angular / cli is not the Angular framework. It is a library so you can generate angular projects from the command line:
sudo npm i -g @angular/cli
Leave the executable ng
available. Then you can generate a project by running
ng new miproyecto
This will create a folder miproyecto
within which there is a scaffold of an Angular application. You enter that folder, you execute npm install
and you already have a functional application on which you can start making your additions and modifications.
On the other hand, if you clone the link repo you will not actually have the ng
command on your line of command, but you can only run it within your local copy of that repo doing first npm install
and then npm run ng
, which is not ideal. Better use the path with sudo npm i -g @angular/cli
. If you do not have sudo privileges, you can configure npm so that the globally installed packages are installed in your local folder.
For this you must also add the route of those packages to your $ PATH (for example /home/junior_molina/.npm-packages/bin
).