Skip to content

Commit

Permalink
perf: update pkg-dir to v6.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
antongolub committed Oct 2, 2021
1 parent c1db23c commit 3b54abb
Show file tree
Hide file tree
Showing 4 changed files with 693 additions and 690 deletions.
20 changes: 10 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
},
"dependencies": {
"@types/find-cache-dir": "^3.2.1",
"@types/fs-extra": "^9.0.12",
"@types/fs-extra": "^9.0.13",
"@types/lodash-es": "^4.17.5",
"@types/semver": "^7.3.8",
"@types/yarnpkg__lockfile": "^1.1.5",
Expand All @@ -77,32 +77,32 @@
"commander": "^8.2.0",
"fs-extra": "^10.0.0",
"find-cache-dir": "^3.3.2",
"find-up": "^6.0.0",
"find-up": "^6.1.0",
"globby": "^12.0.2",
"lodash-es": "^4.17.21",
"npm": "7.24.1",
"pkg-dir": "^5.0.0",
"pkg-dir": "^6.0.0",
"semver": "^7.3.5",
"synp": "^1.9.7",
"tslib": "^2.3.1"
},
"devDependencies": {
"@jest/globals": "^27.2.0",
"@jest/globals": "^27.2.4",
"@qiwi/libdefkit": "^3.1.1",
"@qiwi/npm-run-all": "^4.1.7",
"@types/jest": "^27.0.1",
"@types/node": "^16.9.1",
"@types/jest": "^27.0.2",
"@types/node": "^16.10.2",
"cpy-cli": "^3.1.1",
"eslint": "^7.32.0",
"eslint-config-prettier": "^8.3.0",
"eslint-config-qiwi": "^1.13.6",
"jest": "^27.2.0",
"jest": "^27.2.4",
"mkdirp": "^1.0.4",
"prettier": "^2.4.0",
"terser": "^5.7.2",
"prettier": "^2.4.1",
"terser": "^5.9.0",
"ts-jest": "^27.0.5",
"tsc-esm-fix": "^2.7.2",
"typedoc": "^0.22.3",
"typedoc": "^0.22.5",
"typescript": "4.4.3"
},
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion src/main/ts/stages.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import fs from 'fs-extra'
import { dirname, join, relative } from 'node:path'
import { fileURLToPath } from 'node:url'
import { sync as pkgDir } from 'pkg-dir'
import semver from 'semver'
import synp from 'synp'

Expand All @@ -14,6 +13,7 @@ import {
getWorkspaces,
getYarn,
invoke,
pkgDir,
readJson,
} from './util'

Expand Down
4 changes: 3 additions & 1 deletion src/main/ts/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import type { StdioOptions } from 'node:child_process'
import { createRequire } from 'node:module'
import { dirname, join, resolve } from 'node:path'
import { fileURLToPath } from 'node:url'
import { sync as pkgDir } from 'pkg-dir'
import { packageDirectorySync } from 'pkg-dir'

import { TFlags, TFlagsMapping } from './ifaces'

Expand All @@ -18,6 +18,8 @@ const cp = createRequire(import.meta.url)('child_process')
const { ensureDirSync, readFileSync } = fse
const __dirname = dirname(fileURLToPath(import.meta.url))

export const pkgDir = (cwd: string): string => packageDirectorySync({cwd})

export const invoke = (
cmd: string,
args: string[],
Expand Down
Loading

0 comments on commit 3b54abb

Please sign in to comment.