angular-cli: You cannot use the new command inside an Angular CLI project.

OS?

Linux Ubuntu 16.10

Versions.

node: 7.2.0 os: linux x64 @angular/cli: 1.0.0-beta.30

Repro steps.

npm install -g @angular/cli mkdir newApp cd newApp ng new

The log given by the failure.

You cannot use the new command inside an Angular CLI project. But the folder is completely empty.

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Reactions: 3
  • Comments: 17 (5 by maintainers)

Most upvoted comments

Completely removing @angular/cli and reinstalling it seems to have done the trick.

@ASrima rm -r -f // might will probably delete a bunch of things that you don’t expect. It’s a bad idea to advise people to run this command.

@Ionaru can you check if you still have an angular-cli package installed globally? If you, please remove it.

And please verify if there is a mention of angular-cli in you package.json.