-
Notifications
You must be signed in to change notification settings - Fork 12k
Angular CLI v8 ng new
generates Angular v7 files
#14603
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
This issue was resolved by removing an errant node-modules folder. It appears that it invokes the local CLI when one exists and one existed in the node-modules folder. Suggested change (from Filipe): "We can detect whether or not the command runs in a workspace and that should bound the mechanism for using the local version." |
I don't know if this picture is accurate, but what it sounds like is that you were in a directory with a node_modules folder that contained v7 of the Angular CLI and when running After removing the node_modules folder, and running the command again, npm used the global version of the Angular CLI (v8) and installed v8 of Angular. If this is accurate, there isn't a bug here, this is just the way node and npm work. |
Maybe it's worth outputting a warning message to set clear expectations. |
|
I have problem where the new project is Angular 6. Global cli is latest.
The directory where I'm using ng new doesn't have any modules installed.
The directory where using ng new command has a lot other Angular project directories, can it be that |
I just ran into this issue for several hours. I had a node_modules directory in the directory I was running |
In some cases orphan `node_modules` could cause the non global CLI to be used to generate a new workspace. Closes angular#14603
In some cases orphan `node_modules` would cause the non global CLI to be used to generate a new workspace. Closes angular#14603
In some cases orphan `node_modules` would cause the non global CLI to be used to generate a new workspace. Closes #14603
In some cases orphan `node_modules` would cause the non global CLI to be used to generate a new workspace. Closes angular#14603
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
🐞 Bug report
Command (mark with an
x
)Is this a regression?
Probably not
Yes, the previous version in which this bug was not present was...Description
A clear and concise description of the problem...The package.json file created with ng new is set to version 7 files instead of version 8 files.
🔬 Minimal Reproduction
🔥 Exception or Error
🌍 Your Environment
Anything else relevant?
The text was updated successfully, but these errors were encountered: