cleanup(core): move lock-file utils to root nx level (#13245)
This commit is contained in:
parent
b88dc35aa5
commit
b2b161cb8d
@ -1,5 +1,5 @@
|
||||
import { readFileSync, writeFileSync } from 'fs-extra';
|
||||
import { detectPackageManager, PackageManager } from '../package-manager';
|
||||
import { detectPackageManager, PackageManager } from '../utils/package-manager';
|
||||
import {
|
||||
parseYarnLockFile,
|
||||
pruneYarnLockFile,
|
||||
@ -19,13 +19,13 @@ import {
|
||||
transitiveDependencyPnpmLookup,
|
||||
} from './pnpm';
|
||||
import { LockFileData } from './lock-file-type';
|
||||
import { workspaceRoot } from '../workspace-root';
|
||||
import { workspaceRoot } from '../utils/workspace-root';
|
||||
import { join } from 'path';
|
||||
import { hashExternalNodes, hashString, mapExternalNodes } from './utils';
|
||||
import {
|
||||
ProjectGraph,
|
||||
ProjectGraphExternalNode,
|
||||
} from '../../config/project-graph';
|
||||
} from '../config/project-graph';
|
||||
import { existsSync } from 'fs';
|
||||
|
||||
const YARN_LOCK_PATH = join(workspaceRoot, 'yarn.lock');
|
||||
@ -15,7 +15,6 @@ import {
|
||||
lockFileV2YargsAndDevkitOnly,
|
||||
} from './__fixtures__/npm.lock';
|
||||
import { vol } from 'memfs';
|
||||
import { readJsonFile } from '../fileutils';
|
||||
|
||||
jest.mock('fs', () => require('memfs').fs);
|
||||
|
||||
@ -1,9 +1,9 @@
|
||||
import { existsSync } from 'fs';
|
||||
import { satisfies } from 'semver';
|
||||
import { readJsonFile } from '../fileutils';
|
||||
import { output } from '../output';
|
||||
import { joinPathFragments } from '../path';
|
||||
import { workspaceRoot } from '../workspace-root';
|
||||
import { readJsonFile } from '../utils/fileutils';
|
||||
import { output } from '../utils/output';
|
||||
import { joinPathFragments } from '../utils/path';
|
||||
import { workspaceRoot } from '../utils/workspace-root';
|
||||
import { LockFileData, PackageDependency } from './lock-file-type';
|
||||
import {
|
||||
sortObject,
|
||||
@ -1,15 +1,15 @@
|
||||
import { defaultHashing } from '../../hasher/hashing-impl';
|
||||
import { defaultHashing } from '../hasher/hashing-impl';
|
||||
import {
|
||||
LockFileData,
|
||||
PackageDependency,
|
||||
PackageVersions,
|
||||
} from './lock-file-type';
|
||||
import { workspaceRoot } from '../workspace-root';
|
||||
import { workspaceRoot } from '../utils/workspace-root';
|
||||
import { existsSync, readFileSync } from 'fs';
|
||||
import {
|
||||
ProjectGraph,
|
||||
ProjectGraphExternalNode,
|
||||
} from '../../config/project-graph';
|
||||
} from '../config/project-graph';
|
||||
|
||||
/**
|
||||
* Simple sort function to ensure keys are ordered alphabetically
|
||||
@ -25,7 +25,6 @@ import { getRootTsConfigPath } from '../utils/typescript';
|
||||
import {
|
||||
ProjectFileMap,
|
||||
ProjectGraph,
|
||||
ProjectGraphExternalNode,
|
||||
ProjectGraphProcessorContext,
|
||||
} from '../config/project-graph';
|
||||
import { readJsonFile } from '../utils/fileutils';
|
||||
@ -45,7 +44,7 @@ import {
|
||||
lockFileHash,
|
||||
mapLockFileDataToPartialGraph,
|
||||
parseLockFile,
|
||||
} from '../utils/lock-file/lock-file';
|
||||
} from '../lock-file/lock-file';
|
||||
|
||||
export async function buildProjectGraph() {
|
||||
const projectConfigurations = readAllWorkspaceConfiguration();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user