fix: use pnpm manage package (#4695)

pull/48/MERGE
afe1 2024-10-20 22:30:20 +08:00 committed by GitHub
parent 860fc15ce6
commit 93b48ef244
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 7 deletions

View File

@ -11,13 +11,10 @@ import { findUpSync } from 'find-up';
* @param cwd * @param cwd
*/ */
function findMonorepoRoot(cwd: string = process.cwd()) { function findMonorepoRoot(cwd: string = process.cwd()) {
const lockFile = findUpSync( const lockFile = findUpSync('pnpm-lock.yaml', {
['pnpm-lock.yaml', 'yarn.lock', 'package-lock.json'], cwd,
{ type: 'file',
cwd, });
type: 'file',
},
);
return dirname(lockFile || ''); return dirname(lockFile || '');
} }