allow for production deployment
This commit is contained in:
parent
79c5a0aff0
commit
bd7af1241e
@ -54,6 +54,17 @@ try
|
|||||||
let useToken = await collect("DENO_DEPLOY_TOKEN", arg, env);
|
let useToken = await collect("DENO_DEPLOY_TOKEN", arg, env);
|
||||||
let useProject = await collect("DENO_DEPLOY_PROJECT", arg, env);
|
let useProject = await collect("DENO_DEPLOY_PROJECT", arg, env);
|
||||||
|
|
||||||
|
let scanProd:string|string[] = await prompt(`Do you want to deploy to *production*? [y/n]`);
|
||||||
|
if(scanProd == "y")
|
||||||
|
{
|
||||||
|
scanProd = await prompt(`This will update the live project at ${useProject} are you sure you want to continue? [y/n]`);
|
||||||
|
scanProd = scanProd=="y" ? ["--prod"] : [];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
scanProd = [];
|
||||||
|
}
|
||||||
|
|
||||||
const command = new Deno.Command(
|
const command = new Deno.Command(
|
||||||
`deno`,
|
`deno`,
|
||||||
{
|
{
|
||||||
@ -66,6 +77,7 @@ try
|
|||||||
`--project=${useProject}`,
|
`--project=${useProject}`,
|
||||||
`--import-map=./deno.json`,
|
`--import-map=./deno.json`,
|
||||||
`--token=${useToken}`,
|
`--token=${useToken}`,
|
||||||
|
...scanProd,
|
||||||
Deno.mainModule
|
Deno.mainModule
|
||||||
],
|
],
|
||||||
stdin: "piped",
|
stdin: "piped",
|
||||||
|
Loading…
Reference in New Issue
Block a user