Skip to content

Commit

Permalink
feat(misc): update minimatch version used across packages (#21207)
Browse files Browse the repository at this point in the history
  • Loading branch information
leosvelperez committed Jan 18, 2024
1 parent e4e7f54 commit f98a16f
Show file tree
Hide file tree
Showing 29 changed files with 40 additions and 43 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@
"metro-config": "0.76.8",
"metro-resolver": "0.76.8",
"mini-css-extract-plugin": "~2.4.7",
"minimatch": "3.0.5",
"minimatch": "9.0.3",
"next-sitemap": "^3.1.10",
"ng-packagr": "~17.0.0",
"node-fetch": "^2.6.7",
Expand Down
2 changes: 1 addition & 1 deletion packages/angular/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"find-cache-dir": "^3.3.2",
"ignore": "^5.0.4",
"magic-string": "~0.30.2",
"minimatch": "3.0.5",
"minimatch": "9.0.3",
"semver": "7.5.3",
"tslib": "^2.3.0",
"webpack": "^5.80.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/angular/src/generators/stories/stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import { getProjectEntryPoints } from '../utils/storybook-ast/entry-point';
import { getE2EProject } from './lib/get-e2e-project';
import { getModuleFilePaths } from '../utils/storybook-ast/module-info';
import type { StoriesGeneratorOptions } from './schema';
import minimatch = require('minimatch');
import { minimatch } from 'minimatch';
import { nxVersion } from '../../utils/versions';

export async function angularStoriesGenerator(
Expand Down
2 changes: 1 addition & 1 deletion packages/jest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
"jest-config": "^29.4.1",
"jest-resolve": "^29.4.1",
"jest-util": "^29.4.1",
"minimatch": "3.0.5",
"minimatch": "9.0.3",
"resolve.exports": "1.1.0",
"tslib": "^2.3.0",
"@nx/devkit": "file:../devkit",
Expand Down
2 changes: 1 addition & 1 deletion packages/jest/src/plugins/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import { projectGraphCacheDirectory } from 'nx/src/utils/cache-directory';
import { calculateHashForCreateNodes } from '@nx/devkit/src/utils/calculate-hash-for-create-nodes';
import { getGlobPatternsFromPackageManagerWorkspaces } from 'nx/plugins/package-json-workspaces';
import { combineGlobPatterns } from 'nx/src/utils/globs';
import * as minimatch from 'minimatch';
import { minimatch } from 'minimatch';

export interface JestPluginOptions {
targetName?: string;
Expand Down
2 changes: 1 addition & 1 deletion packages/js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"tsconfig-paths": "^4.1.2",
"ignore": "^5.0.4",
"js-tokens": "^4.0.0",
"minimatch": "3.0.5",
"minimatch": "9.0.3",
"ora": "5.3.0",
"semver": "7.5.3",
"source-map-support": "0.5.19",
Expand Down
2 changes: 1 addition & 1 deletion packages/js/src/utils/assets/copy-assets-handler.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as minimatch from 'minimatch';
import { minimatch } from 'minimatch';
import * as path from 'path';
import * as fse from 'fs-extra';
import ignore from 'ignore';
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"js-yaml": "4.1.0",
"jsonc-parser": "3.2.0",
"lines-and-columns": "~2.0.3",
"minimatch": "3.0.5",
"minimatch": "9.0.3",
"npm-run-path": "^4.0.1",
"open": "^8.4.0",
"semver": "7.5.3",
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/src/command-line/graph/graph.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { createHash } from 'crypto';
import { existsSync, readFileSync, statSync, writeFileSync } from 'fs';
import { copySync, ensureDirSync } from 'fs-extra';
import * as http from 'http';
import * as minimatch from 'minimatch';
import { minimatch } from 'minimatch';
import { URL } from 'node:url';
import * as open from 'open';
import {
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/src/generators/utils/glob.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ describe('glob', () => {
tree.write('3.txt', '3');
fs.writeFile('4.md', '4');

const withTree = glob(tree, ['*.txt']).sort();
const withTree = glob(tree, ['**/*.txt']).sort();

expect(withTree).toMatchInlineSnapshot(`
[
Expand Down
4 changes: 1 addition & 3 deletions packages/nx/src/generators/utils/glob.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
import { minimatch } from 'minimatch';
import { Tree } from '../tree';
import { combineGlobPatterns } from '../../utils/globs';
import { workspaceRoot } from '../../utils/workspace-root';
import { globWithWorkspaceContext } from '../../utils/workspace-context';

import minimatch = require('minimatch');

/**
* Performs a tree-aware glob search on the files in a workspace. Able to find newly
* created files and hides deleted files before the updates are committed to disk.
Expand Down
3 changes: 1 addition & 2 deletions packages/nx/src/generators/utils/project-configuration.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { minimatch } from 'minimatch';
import { basename, join, relative } from 'path';

import {
Expand All @@ -24,8 +25,6 @@ import { readNxJson } from './nx-json';

import type { Tree } from '../tree';

import minimatch = require('minimatch');

export { readNxJson, updateNxJson } from './nx-json';

/**
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/src/hasher/node-task-hasher-impl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { Task, TaskGraph } from '../config/task-graph';
import { hashArray, hashObject } from './file-hasher';
import { getOutputsForTargetAndConfiguration } from '../tasks-runner/utils';
import { workspaceRoot } from '../utils/workspace-root';
import * as minimatch from 'minimatch';
import { minimatch } from 'minimatch';
import { join } from 'path';
import { hashFile } from '../native';
import { findAllProjectNodeDependencies } from '../utils/project-graph-utils';
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/src/hasher/task-hasher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { DaemonClient } from '../daemon/client/client';
import { hashArray } from './file-hasher';
import { NodeTaskHasherImpl } from './node-task-hasher-impl';
import { InputDefinition } from '../config/workspace-json-project-json';
import * as minimatch from 'minimatch';
import { minimatch } from 'minimatch';
import { NativeTaskHasherImpl } from './native-task-hasher-impl';
import { workspaceRoot } from '../utils/workspace-root';
import { NxWorkspaceFilesExternals } from '../native';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { TouchedProjectLocator } from '../affected-project-graph-models';
import minimatch = require('minimatch');
import { minimatch } from 'minimatch';
import { workspaceRoot } from '../../../utils/workspace-root';
import { getNxRequirePaths } from '../../../utils/installation-directory';
import { join } from 'path';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as minimatch from 'minimatch';
import { minimatch } from 'minimatch';
import { TouchedProjectLocator } from '../affected-project-graph-models';
import { NxJsonConfiguration } from '../../../config/nx-json';
import {
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/src/project-graph/file-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import {
} from './utils/project-configuration-utils';
import { NxJsonConfiguration } from '../config/nx-json';
import { getDefaultPluginsSync } from '../utils/nx-plugin.deprecated';
import minimatch = require('minimatch');
import { minimatch } from 'minimatch';
import { CreateNodesResult } from '../devkit-exports';
import { CreatePackageJsonProjectsNextToProjectJson } from '../plugins/project-json/build-nodes/package-json-next-to-project-json';
import { LoadedNxPlugin } from '../utils/nx-plugin';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { CreateNodesResult, LoadedNxPlugin } from '../../utils/nx-plugin';
import { readJsonFile } from '../../utils/fileutils';
import { workspaceRoot } from '../../utils/workspace-root';

import minimatch = require('minimatch');
import { minimatch } from 'minimatch';
import { join } from 'path';

export type SourceInformation = [string, string];
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/src/utils/find-matching-projects.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import {
getMatchingStringsWithCache,
} from './find-matching-projects';
import type { ProjectGraphProjectNode } from '../config/project-graph';
import minimatch = require('minimatch');
import { minimatch } from 'minimatch';

describe('findMatchingProjects', () => {
let projectGraph: Record<string, ProjectGraphProjectNode> = {
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/src/utils/find-matching-projects.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import minimatch = require('minimatch');
import { minimatch } from 'minimatch';
import type { ProjectGraphProjectNode } from '../config/project-graph';

const validPatternTypes = [
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"@nx/eslint": "file:../eslint",
"@nx/js": "file:../js",
"tslib": "^2.3.0",
"minimatch": "3.0.5"
"minimatch": "9.0.3"
},
"peerDependencies": {
"@playwright/test": "^1.36.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/playwright/src/plugins/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import { calculateHashForCreateNodes } from '@nx/devkit/src/utils/calculate-hash

import type { PlaywrightTestConfig } from '@playwright/test';
import { getFilesInDirectoryUsingContext } from 'nx/src/utils/workspace-context';
import minimatch = require('minimatch');
import { minimatch } from 'minimatch';
import { loadPlaywrightConfig } from '../utils/load-config-file';
import { projectGraphCacheDirectory } from 'nx/src/utils/cache-directory';
import { getLockFileName } from '@nx/js';
Expand Down
2 changes: 1 addition & 1 deletion packages/react-native/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"ignore": "^5.0.4",
"metro-config": "~0.76.8",
"metro-resolver": "~0.76.8",
"minimatch": "3.0.5",
"minimatch": "9.0.3",
"node-fetch": "^2.6.7",
"tsconfig-paths": "^4.1.2",
"tslib": "^2.3.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/react-native/src/generators/stories/stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import {
containsComponentDeclaration,
projectRootPath,
} from '@nx/react/src/generators/stories/stories';
import minimatch = require('minimatch');
import { minimatch } from 'minimatch';
import { nxVersion } from '../../utils/versions';

export async function createAllStories(
Expand Down
2 changes: 1 addition & 1 deletion packages/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"@svgr/webpack": "^8.0.1",
"chalk": "^4.1.0",
"file-loader": "^6.2.0",
"minimatch": "3.0.5",
"minimatch": "9.0.3",
"tslib": "^2.3.0",
"@nx/devkit": "file:../devkit",
"@nx/js": "file:../js",
Expand Down
2 changes: 1 addition & 1 deletion packages/react/src/generators/stories/stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
visitNotIgnoredFiles,
} from '@nx/devkit';
import { basename, join } from 'path';
import minimatch = require('minimatch');
import { minimatch } from 'minimatch';
import { ensureTypescript } from '@nx/js/src/utils/typescript/ensure-typescript';
import { nxVersion } from '../../utils/versions';

Expand Down
2 changes: 1 addition & 1 deletion packages/vue/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"migrations": "./migrations.json"
},
"dependencies": {
"minimatch": "3.0.5",
"minimatch": "9.0.3",
"tslib": "^2.3.0",
"@nx/devkit": "file:../devkit",
"@nx/js": "file:../js",
Expand Down
2 changes: 1 addition & 1 deletion packages/vue/src/generators/stories/stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {
import { basename, join } from 'path';
import { nxVersion } from '../../utils/versions';
import { createComponentStories } from './lib/component-story';
import minimatch = require('minimatch');
import { minimatch } from 'minimatch';

export interface StorybookStoriesSchema {
project: string;
Expand Down
24 changes: 12 additions & 12 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 comment on commit f98a16f

@vercel
Copy link

@vercel vercel bot commented on f98a16f Jan 18, 2024

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-git-master-nrwl.vercel.app
nx-five.vercel.app
nx-dev-nrwl.vercel.app
nx.dev

Please sign in to comment.