diff --git a/packages/nx/src/utils/nx-cloud-utils.ts b/packages/nx/src/utils/nx-cloud-utils.ts index e0db798d57817..5b33d7435ec07 100644 --- a/packages/nx/src/utils/nx-cloud-utils.ts +++ b/packages/nx/src/utils/nx-cloud-utils.ts @@ -1,14 +1,10 @@ import { NxJsonConfiguration } from '../config/nx-json'; export function isNxCloudUsed(nxJson: NxJsonConfiguration): boolean { - if (process.env.NX_NO_CLOUD === 'true') { + if (process.env.NX_NO_CLOUD === 'true' || nxJson.neverConnectToCloud) { return false; } - if (nxJson.neverConnectToCloud) { - return true; - } - return ( !!process.env.NX_CLOUD_ACCESS_TOKEN || !!nxJson.nxCloudAccessToken ||