diff options
author | Leonid Logvinov <logvinov.leon@gmail.com> | 2017-12-05 23:17:57 +0800 |
---|---|---|
committer | Leonid Logvinov <logvinov.leon@gmail.com> | 2017-12-06 20:48:30 +0800 |
commit | 55083316fc7f4bcfbb77470a3f66e621a68ebb95 (patch) | |
tree | daf5600c48e1e453ebbe1da5a618007bfdfd12f4 /packages/monorepo-scripts/src | |
parent | 8c87394b2b0cea4c3fc6126c9b22830041fff889 (diff) | |
download | dexon-0x-contracts-55083316fc7f4bcfbb77470a3f66e621a68ebb95.tar dexon-0x-contracts-55083316fc7f4bcfbb77470a3f66e621a68ebb95.tar.gz dexon-0x-contracts-55083316fc7f4bcfbb77470a3f66e621a68ebb95.tar.bz2 dexon-0x-contracts-55083316fc7f4bcfbb77470a3f66e621a68ebb95.tar.lz dexon-0x-contracts-55083316fc7f4bcfbb77470a3f66e621a68ebb95.tar.xz dexon-0x-contracts-55083316fc7f4bcfbb77470a3f66e621a68ebb95.tar.zst dexon-0x-contracts-55083316fc7f4bcfbb77470a3f66e621a68ebb95.zip |
Inline function
Diffstat (limited to 'packages/monorepo-scripts/src')
-rw-r--r-- | packages/monorepo-scripts/src/deps_versions.ts | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/packages/monorepo-scripts/src/deps_versions.ts b/packages/monorepo-scripts/src/deps_versions.ts index c4ee90775..84b024427 100644 --- a/packages/monorepo-scripts/src/deps_versions.ts +++ b/packages/monorepo-scripts/src/deps_versions.ts @@ -31,15 +31,10 @@ function getDependencies(path: string): Dependencies { return dependencies; } -function getPackageName(path: string): string { - const [dotDot, packageName, packageJSON] = path.split('/'); - return packageName; -} - const files = globSync(PACKAGE_JSON_GLOB); const versionsByDependency: VersionsByDependency = {}; files.map(path => { - const packageName = getPackageName(path); + const [_1, packageName, _2] = path.split('/'); const dependencies = getDependencies(path); _.map(dependencies, (version: string, depName: string) => { if (_.isUndefined(versionsByDependency[depName])) { |