cleanup(core): export setDefaultCollection from @nrwl/workspace (#2970)
This commit is contained in:
parent
515cc37ec6
commit
0a70e46b6b
@ -10,6 +10,7 @@ import {
|
|||||||
addDepsToPackageJson,
|
addDepsToPackageJson,
|
||||||
formatFiles,
|
formatFiles,
|
||||||
readJsonInTree,
|
readJsonInTree,
|
||||||
|
setDefaultCollection,
|
||||||
updateJsonInTree,
|
updateJsonInTree,
|
||||||
updateWorkspace,
|
updateWorkspace,
|
||||||
} from '@nrwl/workspace';
|
} from '@nrwl/workspace';
|
||||||
@ -22,7 +23,6 @@ import {
|
|||||||
import { Schema } from './schema';
|
import { Schema } from './schema';
|
||||||
import { E2eTestRunner, UnitTestRunner } from '../../utils/test-runners';
|
import { E2eTestRunner, UnitTestRunner } from '../../utils/test-runners';
|
||||||
import { stripIndents } from '@angular-devkit/core/src/utils/literals';
|
import { stripIndents } from '@angular-devkit/core/src/utils/literals';
|
||||||
import { setDefaultCollection } from '@nrwl/workspace/src/utils/rules/workspace';
|
|
||||||
|
|
||||||
const updateDependencies = addDepsToPackageJson(
|
const updateDependencies = addDepsToPackageJson(
|
||||||
{
|
{
|
||||||
|
|||||||
@ -2,6 +2,7 @@ import { chain, noop, Rule } from '@angular-devkit/schematics';
|
|||||||
import {
|
import {
|
||||||
addPackageWithInit,
|
addPackageWithInit,
|
||||||
formatFiles,
|
formatFiles,
|
||||||
|
setDefaultCollection,
|
||||||
updateJsonInTree,
|
updateJsonInTree,
|
||||||
} from '@nrwl/workspace';
|
} from '@nrwl/workspace';
|
||||||
import {
|
import {
|
||||||
@ -10,7 +11,6 @@ import {
|
|||||||
nxVersion,
|
nxVersion,
|
||||||
} from '../../utils/versions';
|
} from '../../utils/versions';
|
||||||
import { Schema } from './schema';
|
import { Schema } from './schema';
|
||||||
import { setDefaultCollection } from '@nrwl/workspace/src/utils/rules/workspace';
|
|
||||||
|
|
||||||
function updateDependencies(): Rule {
|
function updateDependencies(): Rule {
|
||||||
return updateJsonInTree('package.json', (json) => {
|
return updateJsonInTree('package.json', (json) => {
|
||||||
|
|||||||
@ -3,6 +3,7 @@ import {
|
|||||||
addDepsToPackageJson,
|
addDepsToPackageJson,
|
||||||
addPackageWithInit,
|
addPackageWithInit,
|
||||||
formatFiles,
|
formatFiles,
|
||||||
|
setDefaultCollection,
|
||||||
updateJsonInTree,
|
updateJsonInTree,
|
||||||
} from '@nrwl/workspace';
|
} from '@nrwl/workspace';
|
||||||
import { Schema } from './schema';
|
import { Schema } from './schema';
|
||||||
@ -12,7 +13,6 @@ import {
|
|||||||
nxVersion,
|
nxVersion,
|
||||||
reflectMetadataVersion,
|
reflectMetadataVersion,
|
||||||
} from '../../utils/versions';
|
} from '../../utils/versions';
|
||||||
import { setDefaultCollection } from '@nrwl/workspace/src/utils/rules/workspace';
|
|
||||||
|
|
||||||
export const updateDependencies = addDepsToPackageJson(
|
export const updateDependencies = addDepsToPackageJson(
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,8 +1,11 @@
|
|||||||
import { chain, noop } from '@angular-devkit/schematics';
|
import { chain, noop } from '@angular-devkit/schematics';
|
||||||
import { addDepsToPackageJson, addPackageWithInit } from '@nrwl/workspace';
|
import {
|
||||||
|
addDepsToPackageJson,
|
||||||
|
addPackageWithInit,
|
||||||
|
setDefaultCollection,
|
||||||
|
} from '@nrwl/workspace';
|
||||||
import { nextVersion } from '../../utils/versions';
|
import { nextVersion } from '../../utils/versions';
|
||||||
import { Schema } from './schema';
|
import { Schema } from './schema';
|
||||||
import { setDefaultCollection } from '@nrwl/workspace/src/utils/rules/workspace';
|
|
||||||
import {
|
import {
|
||||||
reactDomVersion,
|
reactDomVersion,
|
||||||
reactVersion,
|
reactVersion,
|
||||||
|
|||||||
@ -2,11 +2,11 @@ import { chain, noop, Rule } from '@angular-devkit/schematics';
|
|||||||
import {
|
import {
|
||||||
addPackageWithInit,
|
addPackageWithInit,
|
||||||
formatFiles,
|
formatFiles,
|
||||||
|
setDefaultCollection,
|
||||||
updateJsonInTree,
|
updateJsonInTree,
|
||||||
} from '@nrwl/workspace';
|
} from '@nrwl/workspace';
|
||||||
import { nxVersion } from '../../utils/versions';
|
import { nxVersion } from '../../utils/versions';
|
||||||
import { Schema } from './schema';
|
import { Schema } from './schema';
|
||||||
import { setDefaultCollection } from '@nrwl/workspace/src/utils/rules/workspace';
|
|
||||||
|
|
||||||
function updateDependencies(): Rule {
|
function updateDependencies(): Rule {
|
||||||
return updateJsonInTree('package.json', (json) => {
|
return updateJsonInTree('package.json', (json) => {
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
import { chain, noop, Rule } from '@angular-devkit/schematics';
|
import { chain, noop, Rule } from '@angular-devkit/schematics';
|
||||||
import {
|
import {
|
||||||
addPackageWithInit,
|
addPackageWithInit,
|
||||||
|
setDefaultCollection,
|
||||||
updateJsonInTree,
|
updateJsonInTree,
|
||||||
updateWorkspace,
|
updateWorkspace,
|
||||||
} from '@nrwl/workspace';
|
} from '@nrwl/workspace';
|
||||||
@ -14,7 +15,6 @@ import {
|
|||||||
typesReactVersion,
|
typesReactVersion,
|
||||||
} from '../../utils/versions';
|
} from '../../utils/versions';
|
||||||
import { JsonObject } from '@angular-devkit/core';
|
import { JsonObject } from '@angular-devkit/core';
|
||||||
import { setDefaultCollection } from '@nrwl/workspace/src/utils/rules/workspace';
|
|
||||||
|
|
||||||
export function updateDependencies(): Rule {
|
export function updateDependencies(): Rule {
|
||||||
return updateJsonInTree('package.json', (json) => {
|
return updateJsonInTree('package.json', (json) => {
|
||||||
|
|||||||
@ -2,6 +2,7 @@ import { chain, noop, Rule } from '@angular-devkit/schematics';
|
|||||||
import {
|
import {
|
||||||
addPackageWithInit,
|
addPackageWithInit,
|
||||||
formatFiles,
|
formatFiles,
|
||||||
|
setDefaultCollection,
|
||||||
updateJsonInTree,
|
updateJsonInTree,
|
||||||
} from '@nrwl/workspace';
|
} from '@nrwl/workspace';
|
||||||
import { Schema } from './schema';
|
import { Schema } from './schema';
|
||||||
@ -9,7 +10,6 @@ import {
|
|||||||
documentRegisterElementVersion,
|
documentRegisterElementVersion,
|
||||||
nxVersion,
|
nxVersion,
|
||||||
} from '../../utils/versions';
|
} from '../../utils/versions';
|
||||||
import { setDefaultCollection } from '@nrwl/workspace/src/utils/rules/workspace';
|
|
||||||
|
|
||||||
function updateDependencies(): Rule {
|
function updateDependencies(): Rule {
|
||||||
return updateJsonInTree('package.json', (json) => {
|
return updateJsonInTree('package.json', (json) => {
|
||||||
|
|||||||
@ -68,6 +68,7 @@ export { formatFiles } from './src/utils/rules/format-files';
|
|||||||
export { deleteFile } from './src/utils/rules/deleteFile';
|
export { deleteFile } from './src/utils/rules/deleteFile';
|
||||||
export * from './src/utils/rules/ng-add';
|
export * from './src/utils/rules/ng-add';
|
||||||
export { updateKarmaConf } from './src/utils/rules/update-karma-conf';
|
export { updateKarmaConf } from './src/utils/rules/update-karma-conf';
|
||||||
|
export { setDefaultCollection } from './src/utils/rules/workspace';
|
||||||
import * as strings from './src/utils/strings';
|
import * as strings from './src/utils/strings';
|
||||||
export { checkAndCleanWithSemver } from './src/utils/version-utils';
|
export { checkAndCleanWithSemver } from './src/utils/version-utils';
|
||||||
export { updatePackagesInPackageJson } from './src/utils/update-packages-in-package-json';
|
export { updatePackagesInPackageJson } from './src/utils/update-packages-in-package-json';
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user