changed setup to require CLI modules directly
This commit is contained in:
parent
47762bd0d5
commit
ce6ca5351d
|
@ -4,10 +4,14 @@
|
||||||
// 3. Runs the server using said folder
|
// 3. Runs the server using said folder
|
||||||
|
|
||||||
const rimraf = require("rimraf")
|
const rimraf = require("rimraf")
|
||||||
const homedir = require("os").homedir() + "/.budibase-cypress"
|
const { join } = require("path")
|
||||||
const { execSync } = require("child_process")
|
const homedir = join(require("os").homedir(), ".budibase-cypress")
|
||||||
|
const init = require("../../cli/src/commands/init/initHandler")
|
||||||
|
const run = require("../../cli/src/commands/run/runHandler")
|
||||||
|
|
||||||
rimraf.sync(homedir)
|
rimraf.sync(homedir)
|
||||||
|
|
||||||
execSync(`../../packages/cli/bin/budi init -d ${homedir}`)
|
init({ dir: homedir })
|
||||||
execSync(`../../packages/cli/bin/budi run -d ${homedir}`)
|
.then(() => {
|
||||||
|
run({ dir: homedir })
|
||||||
|
})
|
||||||
|
|
|
@ -7,7 +7,7 @@ const Sqrl = require("squirrelly")
|
||||||
const uuid = require("uuid")
|
const uuid = require("uuid")
|
||||||
|
|
||||||
module.exports = opts => {
|
module.exports = opts => {
|
||||||
run(opts)
|
return run(opts)
|
||||||
}
|
}
|
||||||
|
|
||||||
const run = async opts => {
|
const run = async opts => {
|
||||||
|
|
Loading…
Reference in New Issue