Skip to content

Commit

Permalink
fix will now install the required nodejs deps.
Browse files Browse the repository at this point in the history
  • Loading branch information
ispyhumanfly committed Oct 12, 2023
1 parent f730dfe commit 6734af4
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions packages/iniquity/src/commands/init.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,24 @@ export class Init implements yargs.CommandModule {
copyfiles([path.join(__dirname, "../../../src/example/*"), "."], { up: true, all: true }, (err) => {})
copyfiles([path.join(__dirname, "../../../src/example/.iniquity/*"), ".iniquity"], { up: true, all: true }, (err) => {})

if (fs.existsSync(".iniquity")) {
process.chdir(".iniquity")
exec("npm install", (err, stdout, stderr) => {
if (err) {
console.error(err)
return
}
console.log(stdout)
})
exec("npx rollup -c", (err, stdout, stderr) => {
if (err) {
console.error(err)
return
}
console.log(stdout)
})
}

console.log("Iniquity system initialized.")
}
}
Expand Down

0 comments on commit 6734af4

Please sign in to comment.