File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -51,9 +51,10 @@ async function run(argv) {
51
51
) ;
52
52
} else if ( babelRuntimeVersion === 'catalog:' ) {
53
53
// resolve the version from the given package
54
- const { stdout : listedBabelRuntime } = await exec ( 'pnpm list "@babel/runtime" --json' ) ;
55
- const jsonListedDependencies = JSON . parse ( listedBabelRuntime ) ;
56
- babelRuntimeVersion = jsonListedDependencies [ 0 ] . dependencies [ '@babel/runtime' ] . version ;
54
+ // outputs the pnpm-workspace.yaml config as json
55
+ const { stdout : configStdout } = await exec ( 'pnpm config list --json' ) ;
56
+ const pnpmWorkspaceConfig = JSON . parse ( configStdout ) ;
57
+ babelRuntimeVersion = pnpmWorkspaceConfig . catalog [ '@babel/runtime' ] ;
57
58
}
58
59
59
60
const babelConfigPath = path . resolve ( getWorkspaceRoot ( ) , 'babel.config.js' ) ;
You can’t perform that action at this time.
0 commit comments