diff --git a/libraries/botbuilder-repo-utils/src/workspace.ts b/libraries/botbuilder-repo-utils/src/workspace.ts index 60b8993541..e82c91fae3 100644 --- a/libraries/botbuilder-repo-utils/src/workspace.ts +++ b/libraries/botbuilder-repo-utils/src/workspace.ts @@ -2,12 +2,15 @@ // Licensed under the MIT License. import compact from 'lodash/compact'; -import globby from 'globby'; +import globby, { GlobbyOptions } from 'globby'; import minimatch from 'minimatch'; import path from 'path'; import { Package } from './package'; import { readJsonFile } from './file'; +export const glob = (paths: string[], options: GlobbyOptions = {}): Promise => + globby(paths, { gitignore: true, cwd: process.env['INIT_CWD'], ...options }); + // Represents a workspace export interface Workspace { absPath: string; @@ -39,10 +42,7 @@ export async function collectWorkspacePackages( filters: Partial = {} ): Promise> { // Note: posix is required, this emits absolute paths that are platform specific - const paths = await globby( - workspaces.map((workspace) => path.posix.join(repoRoot, workspace, 'package.json')), - { gitignore: true, cwd: process.env['INIT_CWD'] } - ); + const paths = await glob(workspaces.map((workspace) => path.posix.join(repoRoot, workspace, 'package.json'))); const maybeWorkspaces = await Promise.all( paths.map( diff --git a/libraries/botbuilder-stdlib/.eslintrc.json b/libraries/botbuilder-stdlib/.eslintrc.json index b6e2302cdd..fb973107f2 100644 --- a/libraries/botbuilder-stdlib/.eslintrc.json +++ b/libraries/botbuilder-stdlib/.eslintrc.json @@ -1,3 +1,10 @@ { - "extends": "../../.eslintrc.json" + "extends": "../../.eslintrc.json", + "ignorePatterns": [ + "_ts3.4/", + "dist/", + "lib/", + "node_modules/", + "vendors/" + ] } \ No newline at end of file diff --git a/libraries/botbuilder-stdlib/package.json b/libraries/botbuilder-stdlib/package.json index da9014c480..12f07929f6 100644 --- a/libraries/botbuilder-stdlib/package.json +++ b/libraries/botbuilder-stdlib/package.json @@ -16,7 +16,7 @@ "scripts": { "build": "tsc -b", "clean": "rimraf _ts3.4 lib tsconfig.tsbuildinfo", - "depcheck": "depcheck --config ../../.depcheckrc", + "depcheck": "depcheck --config ../../.depcheckrc --ignores sinon,bignumber.js,grapheme-splitter,lodash.escaperegexp,lodash.isequal,lodash.last,lodash.max,lodash.tonumber,lodash,chai,chai-as-promised", "lint": "eslint . --ext .js,.ts", "postbuild": "downlevel-dts lib _ts3.4/lib", "test": "yarn build && nyc mocha --check-leaks tests"