diff --git a/docs/generated/devkit/README.md b/docs/generated/devkit/README.md index f0c7e6bd6a250..f6668fe505bdb 100644 --- a/docs/generated/devkit/README.md +++ b/docs/generated/devkit/README.md @@ -119,6 +119,7 @@ It only uses language primitives and immutable objects - [detectPackageManager](../../devkit/documents/detectPackageManager) - [ensurePackage](../../devkit/documents/ensurePackage) - [extractLayoutDirectory](../../devkit/documents/extractLayoutDirectory) +- [findMatchingProjects](../../devkit/documents/findMatchingProjects) - [formatFiles](../../devkit/documents/formatFiles) - [generateFiles](../../devkit/documents/generateFiles) - [getOutputsForTargetAndConfiguration](../../devkit/documents/getOutputsForTargetAndConfiguration) diff --git a/docs/generated/devkit/findMatchingProjects.md b/docs/generated/devkit/findMatchingProjects.md new file mode 100644 index 0000000000000..a1e330c34e5eb --- /dev/null +++ b/docs/generated/devkit/findMatchingProjects.md @@ -0,0 +1,16 @@ +# Function: findMatchingProjects + +▸ **findMatchingProjects**(`patterns?`, `projects`): `string`[] + +Find matching project names given a list of potential project names or globs. + +#### Parameters + +| Name | Type | Default value | Description | +| :--------- | :------------------------------------------------------------------------------------------------ | :------------ | :-------------------------------------------------------------------------------------------------- | +| `patterns` | `string`[] | `[]` | A list of project names or globs to match against. | +| `projects` | `Record`\<`string`, [`ProjectGraphProjectNode`](../../devkit/documents/ProjectGraphProjectNode)\> | `undefined` | A map of [ProjectGraphProjectNode](../../devkit/documents/ProjectGraphProjectNode) by project name. | + +#### Returns + +`string`[] diff --git a/docs/generated/packages/devkit/documents/nx_devkit.md b/docs/generated/packages/devkit/documents/nx_devkit.md index f0c7e6bd6a250..f6668fe505bdb 100644 --- a/docs/generated/packages/devkit/documents/nx_devkit.md +++ b/docs/generated/packages/devkit/documents/nx_devkit.md @@ -119,6 +119,7 @@ It only uses language primitives and immutable objects - [detectPackageManager](../../devkit/documents/detectPackageManager) - [ensurePackage](../../devkit/documents/ensurePackage) - [extractLayoutDirectory](../../devkit/documents/extractLayoutDirectory) +- [findMatchingProjects](../../devkit/documents/findMatchingProjects) - [formatFiles](../../devkit/documents/formatFiles) - [generateFiles](../../devkit/documents/generateFiles) - [getOutputsForTargetAndConfiguration](../../devkit/documents/getOutputsForTargetAndConfiguration) diff --git a/packages/nx/src/devkit-exports.ts b/packages/nx/src/devkit-exports.ts index 12a4cf607c983..310af7a64a13c 100644 --- a/packages/nx/src/devkit-exports.ts +++ b/packages/nx/src/devkit-exports.ts @@ -248,4 +248,9 @@ export { cacheDir } from './utils/cache-directory'; */ export { createProjectFileMapUsingProjectGraph } from './project-graph/file-map-utils'; +/** + * @category Utils + */ +export { findMatchingProjects } from './utils/find-matching-projects'; + export { isDaemonEnabled } from './daemon/client/client';