Skip to content

Commit

Permalink
feat(core): warn when falling back to angular cli (#14247)
Browse files Browse the repository at this point in the history
  • Loading branch information
Coly010 committed Jan 12, 2023
1 parent 2dc72e0 commit 064ef0f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/nx/bin/init-local.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { execSync } from 'child_process';

import { commandsObject } from '../src/command-line/nx-commands';
import { WorkspaceTypeAndRoot } from '../src/utils/find-workspace-root';
import { stripIndents } from '../src/utils/strip-indents';

/**
* Nx is being run inside a workspace.
Expand All @@ -19,6 +20,10 @@ export function initLocal(workspace: WorkspaceTypeAndRoot) {
require('nx/src/utils/perf-logging');

if (workspace.type !== 'nx' && shouldDelegateToAngularCLI()) {
console.warn(
stripIndents`Using Nx to run Angular CLI commands is deprecated and will be removed in a future version.
To run Angular CLI commands, use \`ng\`.`
);
handleAngularCLIFallbacks(workspace);
return;
}
Expand Down

1 comment on commit 064ef0f

@vercel
Copy link

@vercel vercel bot commented on 064ef0f Jan 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

nx-dev – ./

nx.dev
nx-dev-git-master-nrwl.vercel.app
nx-dev-nrwl.vercel.app
nx-five.vercel.app

Please sign in to comment.