Skip to content

Commit

Permalink
Merge pull request #1348 from flexn-io/fix/install_pkg-dir_before_fir…
Browse files Browse the repository at this point in the history
…st_run

install pkg-dir@7.0.0 before first run
  • Loading branch information
mihaiblaga89 committed Jan 19, 2024
2 parents 7578ea5 + c4426b3 commit 1fec067
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/engine-core/src/tasks/task.rnv.new.ts
Expand Up @@ -499,6 +499,10 @@ export const taskRnvNew = async (c: RnvContext) => {
await executeAsync(`${isYarnInstalled() ? 'yarn' : 'npm'} add rnv@${c.rnvVersion}`, {
cwd: c.paths.project.dir,
});
// Add pkg-dir to have the correct version before the first run
await executeAsync(`${isYarnInstalled() ? 'yarn' : 'npm'} add pkg-dir@7.0.0`, {
cwd: c.paths.project.dir,
});

// Check if node_modules folder exists
if (!fsExistsSync(path.join(c.paths.project.dir, 'node_modules'))) {
Expand Down

0 comments on commit 1fec067

Please sign in to comment.