@gadgetinc/ggt 1.3.0 → 1.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{add-VYOF3CRL.js → add-CVO2CSA3.js} +2 -2
- package/dist/{chunk-J5XIQ6N4.js → chunk-6BXHYE2C.js} +2 -2
- package/dist/{chunk-LQDBD3BI.js → chunk-ACR6CVXY.js} +4 -4
- package/dist/{chunk-LQDBD3BI.js.map → chunk-ACR6CVXY.js.map} +2 -2
- package/dist/{chunk-3B5DKR5D.js → chunk-AGRDDZFS.js} +2 -2
- package/dist/{chunk-JU6IEBE5.js → chunk-GIAIN3IJ.js} +10 -10
- package/dist/{chunk-JU6IEBE5.js.map → chunk-GIAIN3IJ.js.map} +4 -4
- package/dist/{chunk-ENT5WEIR.js → chunk-HCQR6OPH.js} +2 -2
- package/dist/{chunk-VE2URKOG.js → chunk-MIN6ZMLJ.js} +2 -2
- package/dist/{chunk-CQH5IRAO.js → chunk-O2K4B6AL.js} +3 -3
- package/dist/{chunk-WBESFPTY.js → chunk-W5JAWOQQ.js} +2 -2
- package/dist/{chunk-YQO2R55C.js → chunk-XB3JTJT6.js} +2 -2
- package/dist/{chunk-ZHG3WLFU.js → chunk-YESACFSR.js} +2 -2
- package/dist/deploy-6JPQ4SNV.js +25 -0
- package/dist/deploy-6JPQ4SNV.js.map +7 -0
- package/dist/{dev-G77WSGIC.js → dev-ZPSCK7JQ.js} +2 -2
- package/dist/{esm-3OYJEC4Z.js → esm-46TFUFSK.js} +22 -22
- package/dist/{esm-3OYJEC4Z.js.map → esm-46TFUFSK.js.map} +3 -3
- package/dist/{list-3AI2FD3F.js → list-A7LFGUXG.js} +2 -2
- package/dist/login-BP4XIHLA.js +2 -0
- package/dist/{logout-CN5DL7Z2.js → logout-PPA6JCDY.js} +2 -2
- package/dist/main.js +1 -1
- package/dist/{open-PM56SR6Z.js → open-MWPVVE7V.js} +2 -2
- package/dist/{pull-TAW6KHZO.js → pull-WEYQPN7H.js} +2 -2
- package/dist/push-S4CWMHMS.js +2 -0
- package/dist/{status-WDYI4EOU.js → status-GI5XJQTQ.js} +2 -2
- package/dist/{version-3FBGIVXT.js → version-CXGPMLMK.js} +2 -2
- package/dist/{whoami-UALRX2FT.js → whoami-PPXXBHUR.js} +2 -2
- package/package.json +2 -2
- package/dist/deploy-EEJCK2MG.js +0 -25
- package/dist/deploy-EEJCK2MG.js.map +0 -7
- package/dist/login-UGTNK3B3.js +0 -2
- package/dist/push-2NCJSDGS.js +0 -2
- /package/dist/{add-VYOF3CRL.js.map → add-CVO2CSA3.js.map} +0 -0
- /package/dist/{chunk-J5XIQ6N4.js.map → chunk-6BXHYE2C.js.map} +0 -0
- /package/dist/{chunk-3B5DKR5D.js.map → chunk-AGRDDZFS.js.map} +0 -0
- /package/dist/{chunk-ENT5WEIR.js.map → chunk-HCQR6OPH.js.map} +0 -0
- /package/dist/{chunk-VE2URKOG.js.map → chunk-MIN6ZMLJ.js.map} +0 -0
- /package/dist/{chunk-CQH5IRAO.js.map → chunk-O2K4B6AL.js.map} +0 -0
- /package/dist/{chunk-WBESFPTY.js.map → chunk-W5JAWOQQ.js.map} +0 -0
- /package/dist/{chunk-YQO2R55C.js.map → chunk-XB3JTJT6.js.map} +0 -0
- /package/dist/{chunk-ZHG3WLFU.js.map → chunk-YESACFSR.js.map} +0 -0
- /package/dist/{dev-G77WSGIC.js.map → dev-ZPSCK7JQ.js.map} +0 -0
- /package/dist/{list-3AI2FD3F.js.map → list-A7LFGUXG.js.map} +0 -0
- /package/dist/{login-UGTNK3B3.js.map → login-BP4XIHLA.js.map} +0 -0
- /package/dist/{logout-CN5DL7Z2.js.map → logout-PPA6JCDY.js.map} +0 -0
- /package/dist/{open-PM56SR6Z.js.map → open-MWPVVE7V.js.map} +0 -0
- /package/dist/{pull-TAW6KHZO.js.map → pull-WEYQPN7H.js.map} +0 -0
- /package/dist/{push-2NCJSDGS.js.map → push-S4CWMHMS.js.map} +0 -0
- /package/dist/{status-WDYI4EOU.js.map → status-GI5XJQTQ.js.map} +0 -0
- /package/dist/{version-3FBGIVXT.js.map → version-CXGPMLMK.js.map} +0 -0
- /package/dist/{whoami-UALRX2FT.js.map → whoami-PPXXBHUR.js.map} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{b as l}from"./chunk-
|
|
1
|
+
import{b as l}from"./chunk-HCQR6OPH.js";import{i as u}from"./chunk-XB3JTJT6.js";import{v as g,w as c}from"./chunk-O2K4B6AL.js";import"./chunk-AGRDDZFS.js";import{$ as o,U as p,Z as a,_ as m}from"./chunk-GIAIN3IJ.js";import"./chunk-B6XQEEUK.js";import{g as n}from"./chunk-SGMPMYEU.js";n();var U=()=>a`
|
|
2
2
|
List the apps available to the currently logged-in user.
|
|
3
3
|
|
|
4
4
|
{bold Usage}
|
|
@@ -8,4 +8,4 @@ import{b as l}from"./chunk-ENT5WEIR.js";import{i as u}from"./chunk-YQO2R55C.js";
|
|
|
8
8
|
|
|
9
9
|
Visit https://gadget.new to create one!
|
|
10
10
|
`;return}let f=c(e);if(p.isInteractive)f.forEach((t,r)=>{o(a`{grey ${r}}`),l({json:t,headers:["Name","Domain"],rows:t.map(s=>[s.slug,s.primaryDomain])}),o("")});else{let t="";for(let r of e)t+=m`${r.slug}\t${r.primaryDomain}`;o({json:e,content:t})}};export{b as run,U as usage};
|
|
11
|
-
//# sourceMappingURL=list-
|
|
11
|
+
//# sourceMappingURL=list-A7LFGUXG.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{e as a,f as b,g as c}from"./chunk-XB3JTJT6.js";import"./chunk-O2K4B6AL.js";import"./chunk-AGRDDZFS.js";import"./chunk-GIAIN3IJ.js";import"./chunk-B6XQEEUK.js";import"./chunk-SGMPMYEU.js";export{c as login,b as run,a as usage};
|
|
2
|
+
//# sourceMappingURL=login-BP4XIHLA.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import{d as r,e as s}from"./chunk-
|
|
1
|
+
import{d as r,e as s}from"./chunk-AGRDDZFS.js";import{$ as o,Z as t}from"./chunk-GIAIN3IJ.js";import{g as n}from"./chunk-SGMPMYEU.js";n();var a=()=>t`
|
|
2
2
|
Log out of your account.
|
|
3
3
|
|
|
4
4
|
{bold Usage}
|
|
5
5
|
ggt logout
|
|
6
6
|
`,p=e=>{r(e)?(s(e,void 0),o("Goodbye")):o("You are not logged in")};export{p as run,a as usage};
|
|
7
|
-
//# sourceMappingURL=logout-
|
|
7
|
+
//# sourceMappingURL=logout-PPA6JCDY.js.map
|
package/dist/main.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{a as V}from"./chunk-3V7YWBUK.js";import{a as J,b as R}from"./chunk-
|
|
2
|
+
import{a as V}from"./chunk-3V7YWBUK.js";import{a as J,b as R}from"./chunk-W5JAWOQQ.js";import{a as _,b as u,d as T,e as E,f as j}from"./chunk-YESACFSR.js";import{D as A,E as C,d as g,e as N,k as K,o as x}from"./chunk-O2K4B6AL.js";import"./chunk-AGRDDZFS.js";import{$ as a,A as s,O,P as f,U as d,W as w,Z as c,b as v,e as m,f as S,z as F}from"./chunk-GIAIN3IJ.js";import{a as b}from"./chunk-B6XQEEUK.js";import{e as l,g as i}from"./chunk-SGMPMYEU.js";i();i();var $=l(b(),1);i();var B=l(_(),1);i();var P=l(K(),1),y=l(F(),1),h=l(b(),1),M=l(V(),1);import H from"node:assert";import D from"node:path";var z=(0,h.default)("12 hours"),q=m.object({name:m.literal("ggt"),"dist-tags":m.object({latest:m.string(),experimental:m.string()})}),Q=async o=>{let t=await C({context:{ctx:o},method:"GET",url:"https://registry.npmjs.org/ggt",responseType:"json",resolveBodyOnly:!0,timeout:{request:(0,h.default)("5s")}});return q.parse(t)["dist-tags"]},Y=async o=>{try{let t=Number(await y.default.readFile(D.join(f.cacheDir,"last-update-check"),"utf8"));return H(!Number.isNaN(t)),(0,P.default)().isAfter(t+z)}catch(t){return o.log.trace("failed to check for updates",{error:t}),!0}},k=async o=>{try{if(!await Y(o))return;await y.default.outputFile(D.join(f.cacheDir,"last-update-check"),String(Date.now()));let r=await Q(o),e,n,p;s.version.includes("experimental")?(e=r.experimental,n=s.version!==e,p=c`
|
|
3
3
|
Update available! {red ${s.version}} → {green ${e}}
|
|
4
4
|
Run "npm install -g ${s.name}@experimental" to update.
|
|
5
5
|
`):(e=r.latest,n=M.default.lt(s.version,e),p=c`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as f,l as v,m as u,n as $,o as O}from"./chunk-
|
|
1
|
+
import{g as f,l as v,m as u,n as $,o as O}from"./chunk-MIN6ZMLJ.js";import{c as p}from"./chunk-YESACFSR.js";import"./chunk-FQ2LR3BI.js";import{d as r}from"./chunk-XB3JTJT6.js";import{o as g,x as w}from"./chunk-O2K4B6AL.js";import"./chunk-AGRDDZFS.js";import{$ as s,Z as i,n as y}from"./chunk-GIAIN3IJ.js";import"./chunk-B6XQEEUK.js";import{g as h}from"./chunk-SGMPMYEU.js";h();var R={...u,"--show-all":{type:Boolean}},J=m=>i`
|
|
2
2
|
This command opens a specific Gadget page in your browser, allowing you to directly access
|
|
3
3
|
various parts of your application's interface such as logs, permissions, data views, or
|
|
4
4
|
schemas.
|
|
@@ -71,4 +71,4 @@ import{g as f,l as v,m as u,n as $,o as O}from"./chunk-VE2URKOG.js";import{c as
|
|
|
71
71
|
`)}await r(`https://${e.environment.application.primaryDomain}/edit/${e.environment.name}/model/${n}/${o}`),s`
|
|
72
72
|
Opened ${o} viewer for environment {cyanBright ${e.environment.name}} for model {cyanBright ${n}}.
|
|
73
73
|
`;break}default:y(a)}},B=["logs","permissions","data","schema"];export{R as args,j as run,J as usage};
|
|
74
|
-
//# sourceMappingURL=open-
|
|
74
|
+
//# sourceMappingURL=open-MWPVVE7V.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{o as g}from"./chunk-
|
|
1
|
+
import{o as g}from"./chunk-6BXHYE2C.js";import{m as l,n as c,o as p}from"./chunk-MIN6ZMLJ.js";import"./chunk-HCQR6OPH.js";import"./chunk-W5JAWOQQ.js";import{c as i}from"./chunk-YESACFSR.js";import"./chunk-FQ2LR3BI.js";import"./chunk-XB3JTJT6.js";import"./chunk-O2K4B6AL.js";import"./chunk-AGRDDZFS.js";import{$ as a,Z as t}from"./chunk-GIAIN3IJ.js";import"./chunk-B6XQEEUK.js";import{g as s}from"./chunk-SGMPMYEU.js";s();var w={...l,"--force":{type:Boolean,alias:"-f"}},P=e=>t`
|
|
2
2
|
Pulls your environment files to your local directory.
|
|
3
3
|
|
|
4
4
|
This command first tracks changes in your local directory since the last sync. If changes are
|
|
@@ -25,4 +25,4 @@ import{o as g}from"./chunk-J5XIQ6N4.js";import{m as l,n as c,o as p}from"./chunk
|
|
|
25
25
|
|
|
26
26
|
Run "ggt pull -h" for more information.
|
|
27
27
|
`);let y=await p(process.cwd()),m=await c.loadOrInit(e,{command:"pull",args:r,directory:y}),o=new g(m),n=await o.hashes(e);if(n.environmentChangesToPull.size===0){a({ensureEmptyLineAbove:!0,content:"Nothing to pull."});return}n.localChangesToPush.size>0&&await o.print(e,{hashes:n}),await o.pull(e,{hashes:n})};export{w as args,A as run,P as usage};
|
|
28
|
-
//# sourceMappingURL=pull-
|
|
28
|
+
//# sourceMappingURL=pull-WEYQPN7H.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a,b,c}from"./chunk-ACR6CVXY.js";import"./chunk-6BXHYE2C.js";import"./chunk-MIN6ZMLJ.js";import"./chunk-HCQR6OPH.js";import"./chunk-W5JAWOQQ.js";import"./chunk-YESACFSR.js";import"./chunk-FQ2LR3BI.js";import"./chunk-XB3JTJT6.js";import"./chunk-O2K4B6AL.js";import"./chunk-AGRDDZFS.js";import"./chunk-GIAIN3IJ.js";import"./chunk-B6XQEEUK.js";import"./chunk-SGMPMYEU.js";export{a as args,c as run,b as usage};
|
|
2
|
+
//# sourceMappingURL=push-S4CWMHMS.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{k as u,l as p,o as d}from"./chunk-
|
|
1
|
+
import{k as u,l as p,o as d}from"./chunk-6BXHYE2C.js";import{g as m,m as f,n as y,o as l}from"./chunk-MIN6ZMLJ.js";import"./chunk-HCQR6OPH.js";import"./chunk-W5JAWOQQ.js";import{c as g}from"./chunk-YESACFSR.js";import"./chunk-FQ2LR3BI.js";import"./chunk-XB3JTJT6.js";import"./chunk-O2K4B6AL.js";import"./chunk-AGRDDZFS.js";import{Z as r}from"./chunk-GIAIN3IJ.js";import"./chunk-B6XQEEUK.js";import{g as c}from"./chunk-SGMPMYEU.js";c();var v=f,D=()=>r`
|
|
2
2
|
Shows file changes since last sync (e.g. $ggt dev, push, deploy etc.)
|
|
3
3
|
|
|
4
4
|
{gray Usage}
|
|
@@ -11,4 +11,4 @@ import{k as u,l as p,o as d}from"./chunk-J5XIQ6N4.js";import{g as m,m as f,n as
|
|
|
11
11
|
|
|
12
12
|
Run "ggt status -h" for more information.
|
|
13
13
|
`);let a=await l(process.cwd()),o=await y.load(t,{command:"status",args:s,directory:a});if(!o)throw new m({command:"status",args:s,directory:a});o.print();let i=new d(o),n=await i.hashes(t);await i.print(t,{hashes:n});let e=u({localChanges:n.localChanges,environmentChanges:n.environmentChanges});e.size>0&&(t.log.debug("conflicts detected",{conflicts:e}),p({conflicts:e}))};export{v as args,J as run,D as usage};
|
|
14
|
-
//# sourceMappingURL=status-
|
|
14
|
+
//# sourceMappingURL=status-GI5XJQTQ.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{$ as o,A as e,Z as n}from"./chunk-
|
|
1
|
+
import{$ as o,A as e,Z as n}from"./chunk-GIAIN3IJ.js";import{g as t}from"./chunk-SGMPMYEU.js";t();var i=()=>n`
|
|
2
2
|
Print this version of ggt.
|
|
3
3
|
|
|
4
4
|
{gray Usage}
|
|
@@ -8,4 +8,4 @@ import{$ as o,A as e,Z as n}from"./chunk-JU6IEBE5.js";import{g as t}from"./chunk
|
|
|
8
8
|
When there is a new release of ggt, running ggt will show you a message letting you
|
|
9
9
|
know that an update is available.
|
|
10
10
|
`,m=r=>{o(e.version)};export{m as run,i as usage};
|
|
11
|
-
//# sourceMappingURL=version-
|
|
11
|
+
//# sourceMappingURL=version-CXGPMLMK.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import{h as n}from"./chunk-
|
|
1
|
+
import{h as n}from"./chunk-XB3JTJT6.js";import"./chunk-O2K4B6AL.js";import"./chunk-AGRDDZFS.js";import{$ as o,Z as a}from"./chunk-GIAIN3IJ.js";import"./chunk-B6XQEEUK.js";import{g as r}from"./chunk-SGMPMYEU.js";r();var g=()=>a`
|
|
2
2
|
Show the name and email address of the currently logged in user.
|
|
3
3
|
|
|
4
4
|
{gray Usage}
|
|
5
5
|
ggt whoami
|
|
6
6
|
`,u=async s=>{let e=await n(s);if(!e){o("You are not logged in");return}e.name?o(`You are logged in as ${e.name} (${e.email})`):o(`You are logged in as ${e.email}`)};export{u as run,g as usage};
|
|
7
|
-
//# sourceMappingURL=whoami-
|
|
7
|
+
//# sourceMappingURL=whoami-PPXXBHUR.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gadgetinc/ggt",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.1",
|
|
4
4
|
"description": "The command-line interface for Gadget",
|
|
5
5
|
"homepage": "https://github.com/gadget-inc/ggt",
|
|
6
6
|
"bugs": {
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"eslint": "^8.57.0",
|
|
64
64
|
"eslint-config-prettier": "^9.1.0",
|
|
65
65
|
"eslint-import-resolver-typescript": "^3.6.3",
|
|
66
|
-
"eslint-plugin-import": "^2.
|
|
66
|
+
"eslint-plugin-import": "^2.31.0",
|
|
67
67
|
"eslint-plugin-jsdoc": "^50.3.1",
|
|
68
68
|
"eslint-plugin-only-warn": "^1.1.0",
|
|
69
69
|
"eslint-plugin-unicorn": "^55.0.0",
|
package/dist/deploy-EEJCK2MG.js
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import{a as K}from"./chunk-P5OUQ5XQ.js";import{a as Z}from"./chunk-LQDBD3BI.js";import{b as j,c as O,e as q,j as m,o as W}from"./chunk-J5XIQ6N4.js";import{a as z,c as H,d as R,i as J,n as Q,o as Y}from"./chunk-VE2URKOG.js";import"./chunk-ENT5WEIR.js";import{b as X}from"./chunk-WBESFPTY.js";import"./chunk-ZHG3WLFU.js";import"./chunk-FQ2LR3BI.js";import{c as A}from"./chunk-YQO2R55C.js";import{a as D,d as G,h as V}from"./chunk-CQH5IRAO.js";import"./chunk-3B5DKR5D.js";import{$ as t,U as L,X as F,Z as p,b as l,m as M}from"./chunk-JU6IEBE5.js";import"./chunk-B6XQEEUK.js";import{g as k}from"./chunk-SGMPMYEU.js";k();import ae from"node:assert";var Le={...Z,"--env":{type:String,alias:["-e","--environment","--from"]},"--allow-problems":{type:Boolean,alias:"--allow-issues"},"--allow-charges":{type:Boolean},"--allow-data-delete":{type:Boolean}},Ge=n=>p`
|
|
2
|
-
Deploys your app to production.
|
|
3
|
-
|
|
4
|
-
This command first performs a sync to ensure that your local and environment directories
|
|
5
|
-
match, changes are tracked since last sync. If any conflicts are detected, they must be
|
|
6
|
-
resolved before deployment.
|
|
7
|
-
|
|
8
|
-
{gray Usage}
|
|
9
|
-
$ ggt deploy [options]
|
|
10
|
-
|
|
11
|
-
{gray Options}
|
|
12
|
-
-a, --app <app_name> Selects a specific app to deploy. Default set on ".gadget/sync.json"
|
|
13
|
-
--from, -e, --env <env_name> Selects a specific environment to sync and deploy from. Default set on ".gadget/sync.json"
|
|
14
|
-
--force Deploys by discarding any changes made to the environment directory since last sync
|
|
15
|
-
--allow-different-directory Deploys from any local directory with existing files, even if the ".gadget/sync.json" file is missing
|
|
16
|
-
--allow-different-app Deploys a different app using the --app command, instead of the one specified in the “.gadget/sync.json” file
|
|
17
|
-
--allow-problems Deploys despite any existing issues found in the app (gelly errors, typescript errors etc.)
|
|
18
|
-
--allow-data-delete Deploys even if it results in the deletion of data in production
|
|
19
|
-
--allow-charges Deploys even if it results in additional charges to your plan
|
|
20
|
-
|
|
21
|
-
{gray Examples}
|
|
22
|
-
Deploys code from the staging environment of a myBlog
|
|
23
|
-
{cyanBright $ ggt deploy -a myBlog -from staging}
|
|
24
|
-
`,Oe=async(n,r)=>{let te=await Y(process.cwd()),a=await Q.loadOrInit(n,{command:"deploy",args:r,directory:te});t({ensureEmptyLineAbove:!0,content:`Deploying ${a.environment.name} to ${D(a.environment.application.primaryDomain,`https://${a.environment.application.primaryDomain}/`)}`});let w=new W(a),c=await w.hashes(n);if(!c.inSync&&(c.localChangesToPush.size>0||!c.onlyDotGadgetFilesChanged)){await w.print(n,{hashes:c}),t({ensureEmptyLineAbove:!0,content:"Your environment's files must match your local files before you can deploy."});let i=!1;if(L.isInteractive){let s;switch(!0){case c.bothChanged:s=p`Would you like to push your local changes and {underline discard your environment's} changes now?`,i=!0;break;case c.localChangesToPush.size>0:s=p`Would you like to push your local changes now?`;break;case c.environmentChanges.size>0:s=p`Do you want to {underline discard your environment's} changes now?`,i=!0;break;default:K("no changes to push or discard")}await A(s)}else t({ensureEmptyLineAbove:!0,content:"Assuming you want to push your local files now."});await w.push(n,{command:"deploy",hashes:c,force:i||r["--force"]})}let T={localFilesVersion:String(a.filesVersion),force:r["--allow-problems"],allowDeletedData:r["--allow-data-delete"],allowCharges:r["--allow-charges"]},h,y=e.NOT_STARTED,P=!1,I=a.edit.subscribe({subscription:q,variables:T,onError:async i=>{if(n.log.error("failed to deploy",{error:i}),h?.fail(_(a,y)+" "+m()),M(i.cause)){let s=i.cause[0];if(ae(s,"expected graphqlError to be defined"),s.extensions)switch(!0){case s.extensions.requiresUpgrade:t({ensureEmptyLineAbove:!0,content:s.message.replace(/GGT_PAYMENT_REQUIRED:?\s*/,"")}),process.exit(1);break;case s.extensions.requiresAdditionalCharge:t({ensureEmptyLineAbove:!0,content:s.message.replace(/GGT_PAYMENT_REQUIRED:?\s*/,"")}),await A({ensureEmptyLineAbove:!0,content:"Do you want to continue?"}),I.resubscribe({...T,allowCharges:!0});return}}await G(n,i)},onData:async({publishStatus:i})=>{if(!i){n.log.warn("received empty publish status");return}let{publishStarted:s,progress:b,issues:v,status:f,deletedModelsAndFields:oe}=i,B=v.length>0,{deletedModels:C,deletedModelFields:U}=oe??{deletedModels:[],deletedModelFields:[]},$=C.length>0||U.length>0;if(!P&&(B||$)){P=!0;let d=v.filter(u=>u.severity===z.Fatal);if(d.length>0&&await G(n,new J(R(d))),B&&(t({ensureEmptyLineAbove:!0,content:p`{bold.yellow !} {bold Issues found in your development app}`}),H({problems:R(v)})),$){t({ensureEmptyLineAbove:!0,content:p`{bold.yellow !} {bold Data deleted on deploy}`});let u=l.blueBright("updated"),S=l.redBright("deleted"),E=[];C.forEach(o=>{E.push({symbol:O,name:l.redBright(o),action:S,indent:0})}),U.forEach(({modelIdentifier:o,fields:g})=>{E.push({symbol:j,name:l.blueBright(o),action:u,indent:0}),g.forEach(N=>{E.push({symbol:O,name:l.redBright(N),action:S,indent:2})})});let ne=E.reduce((o,g)=>Math.max(o,g.name.length),0),se=E.reduce((o,g)=>Math.max(o,g.indent),0),x=2;t({ensureEmptyLineAbove:!0,content:l.gray("These changes will be applied to production based on the app you're deploying.")});for(let o of E){let g=" ".repeat(o.indent*x),N=" ".repeat(ne-o.name.length+2),re=" ".repeat((se-o.indent)*x);t({ensureEmptyLineAbove:!1,content:F(`${g}${o.symbol} ${o.name}${N}${re}${o.action}`,6)})}}if(!s)await A("Do you want to continue?"),I.resubscribe({...T,force:!0,allowDeletedData:!0});else{let u=r["--allow-data-delete"],S=r["--allow-problems"];if(!u&&!S)throw new V("expected --allow-data-delete or --allow-problems to be true");S&&t(p`Deploying regardless of problems because "${l.gray("--allow-problems")}" was passed.`),u&&t(p`Deploying regardless of deleted data because "${l.gray("--allow-data-delete")}" was passed.`)}return}if(f?.code==="Errored"){h?.fail(_(a,y)+" "+m()),f.message&&t({ensureEmptyLineAbove:!0,content:l.red(f.message)}),f.output&&t({ensureEmptyLineAbove:!0,content:p`${D("Check logs",f.output)}`});return}if(b===e.COMPLETED){h?.succeed(ee(a,y));let d=l.green("Deploy successful!");f?.output&&(d+=` ${D("Check logs",f.output)}.`),t({ensureEmptyLineAbove:!0,content:d});return}if(b!==y){let d=_(a,b);if(d!==h?.text){h?.succeed(ee(a,y));let u=y===e.NOT_STARTED||!L.isInteractive;h=X({ensureEmptyLineAbove:u,content:d})}y=b}},onComplete:()=>{I.unsubscribe()}})},e=Object.freeze({NOT_STARTED:"NOT_STARTED",STARTING:"STARTING",BUILDING_ASSETS:"BUILDING_ASSETS",UPLOADING_ASSETS:"UPLOADING_ASSETS",CONVERGING_STORAGE:"CONVERGING_STORAGE",PUBLISHING_TREE:"PUBLISHING_TREE",RELOADING_SANDBOX:"RELOADING_SANDBOX",COMPLETED:"COMPLETED"}),_=(n,r)=>{switch(r){case e.NOT_STARTED:case e.STARTING:case e.BUILDING_ASSETS:case e.UPLOADING_ASSETS:return"Building frontend assets.";case e.CONVERGING_STORAGE:return"Setting up database.";case e.PUBLISHING_TREE:return`Copying ${n.environment.name}.`;case e.RELOADING_SANDBOX:return"Restarting app.";case e.COMPLETED:return"Deploy complete!";default:return"Unknown step."}},ee=(n,r)=>{switch(r){case e.NOT_STARTED:case e.STARTING:case e.BUILDING_ASSETS:case e.UPLOADING_ASSETS:return`Built frontend assets. ${m()}`;case e.CONVERGING_STORAGE:return`Setup database. ${m()}`;case e.PUBLISHING_TREE:return`Copied ${n.environment.name}. ${m()}`;case e.RELOADING_SANDBOX:return`Restarted app. ${m()}`;case e.COMPLETED:return"Deploy successful!";default:return`Completed unknown step. ${m()}`}};export{e as AppDeploymentSteps,Le as args,Oe as run,ee as stepToSpinnerEnd,_ as stepToSpinnerStart,Ge as usage};
|
|
25
|
-
//# sourceMappingURL=deploy-EEJCK2MG.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../src/commands/deploy.ts"],
|
|
4
|
-
"sourcesContent": ["import chalk from \"chalk\";\nimport indentString from \"indent-string\";\nimport assert from \"node:assert\";\nimport terminalLink from \"terminal-link\";\nimport { PUBLISH_STATUS_SUBSCRIPTION } from \"../services/app/edit/operation.js\";\nimport { type Run, type Usage } from \"../services/command/command.js\";\nimport { deletedSymbol, updatedSymbol } from \"../services/filesync/changes.js\";\nimport { DeployDisallowedError } from \"../services/filesync/error.js\";\nimport { FileSync } from \"../services/filesync/filesync.js\";\nimport { SyncJson, loadSyncJsonDirectory } from \"../services/filesync/sync-json.js\";\nimport { confirm } from \"../services/output/confirm.js\";\nimport { output } from \"../services/output/output.js\";\nimport { println } from \"../services/output/print.js\";\nimport { ProblemSeverity, printProblems, publishIssuesToProblems } from \"../services/output/problems.js\";\nimport { UnexpectedError, reportErrorAndExit } from \"../services/output/report.js\";\nimport { spin, type spinner } from \"../services/output/spinner.js\";\nimport { sprint } from \"../services/output/sprint.js\";\nimport { ts } from \"../services/output/timestamp.js\";\nimport { unreachable } from \"../services/util/assert.js\";\nimport { isGraphQLErrors } from \"../services/util/is.js\";\nimport { args as PushArgs } from \"./push.js\";\n\nexport type DeployArgs = typeof args;\n\nexport const args = {\n ...PushArgs,\n \"--env\": { type: String, alias: [\"-e\", \"--environment\", \"--from\"] },\n \"--allow-problems\": { type: Boolean, alias: \"--allow-issues\" },\n \"--allow-charges\": { type: Boolean },\n \"--allow-data-delete\": { type: Boolean },\n};\n\nexport const usage: Usage = (_ctx) => {\n return sprint`\n Deploys your app to production.\n\n This command first performs a sync to ensure that your local and environment directories\n match, changes are tracked since last sync. If any conflicts are detected, they must be\n resolved before deployment.\n\n {gray Usage}\n $ ggt deploy [options]\n\n {gray Options}\n -a, --app <app_name> Selects a specific app to deploy. Default set on \".gadget/sync.json\"\n --from, -e, --env <env_name> Selects a specific environment to sync and deploy from. Default set on \".gadget/sync.json\"\n --force Deploys by discarding any changes made to the environment directory since last sync\n --allow-different-directory Deploys from any local directory with existing files, even if the \".gadget/sync.json\" file is missing\n --allow-different-app Deploys a different app using the --app command, instead of the one specified in the \u201C.gadget/sync.json\u201D file\n --allow-problems Deploys despite any existing issues found in the app (gelly errors, typescript errors etc.)\n --allow-data-delete Deploys even if it results in the deletion of data in production\n --allow-charges Deploys even if it results in additional charges to your plan\n\n {gray Examples}\n Deploys code from the staging environment of a myBlog\n {cyanBright $ ggt deploy -a myBlog -from staging}\n`;\n};\n\nexport const run: Run<DeployArgs> = async (ctx, args) => {\n const directory = await loadSyncJsonDirectory(process.cwd());\n const syncJson = await SyncJson.loadOrInit(ctx, { command: \"deploy\", args, directory });\n\n println({\n ensureEmptyLineAbove: true,\n content: `Deploying ${syncJson.environment.name} to ${terminalLink(syncJson.environment.application.primaryDomain, `https://${syncJson.environment.application.primaryDomain}/`)}`,\n });\n\n const filesync = new FileSync(syncJson);\n const hashes = await filesync.hashes(ctx);\n if (!hashes.inSync && (hashes.localChangesToPush.size > 0 || !hashes.onlyDotGadgetFilesChanged)) {\n // the following is true:\n // 1. our local files don't match our environment's files\n // 2. we have local changes to push or non .gadget/ files have changed on our environment\n // therefor, we need to push before we can deploy\n await filesync.print(ctx, { hashes });\n\n println({\n ensureEmptyLineAbove: true,\n content: \"Your environment's files must match your local files before you can deploy.\",\n });\n\n // some scenarios make the confirmation to push changes imply the\n // --force flag (e.g. when both local and environment files have\n // changed, or when only environment files have changed)\n let implicitForce = false;\n\n if (output.isInteractive) {\n let content: string;\n switch (true) {\n case hashes.bothChanged:\n content = sprint`Would you like to push your local changes and {underline discard your environment's} changes now?`;\n implicitForce = true;\n break;\n case hashes.localChangesToPush.size > 0:\n content = sprint`Would you like to push your local changes now?`;\n break;\n case hashes.environmentChanges.size > 0:\n content = sprint`Do you want to {underline discard your environment's} changes now?`;\n implicitForce = true;\n break;\n default:\n unreachable(\"no changes to push or discard\");\n }\n\n await confirm(content);\n } else {\n println({\n ensureEmptyLineAbove: true,\n content: \"Assuming you want to push your local files now.\",\n });\n }\n\n await filesync.push(ctx, { command: \"deploy\", hashes, force: implicitForce || args[\"--force\"] });\n }\n\n const variables = {\n localFilesVersion: String(syncJson.filesVersion),\n force: args[\"--allow-problems\"],\n allowDeletedData: args[\"--allow-data-delete\"],\n allowCharges: args[\"--allow-charges\"],\n };\n\n let spinner: spinner | undefined;\n let currentStep: AppDeploymentSteps = AppDeploymentSteps.NOT_STARTED;\n let printedProblems = false;\n\n const subscription = syncJson.edit.subscribe({\n subscription: PUBLISH_STATUS_SUBSCRIPTION,\n variables,\n onError: async (error) => {\n ctx.log.error(\"failed to deploy\", { error });\n spinner?.fail(stepToSpinnerStart(syncJson, currentStep) + \" \" + ts());\n\n if (isGraphQLErrors(error.cause)) {\n const graphqlError = error.cause[0];\n assert(graphqlError, \"expected graphqlError to be defined\");\n\n // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- TODO: extensions is typed as never undefined, but it can be.\n if (graphqlError.extensions) {\n switch (true) {\n case graphqlError.extensions[\"requiresUpgrade\"]:\n println({ ensureEmptyLineAbove: true, content: graphqlError.message.replace(/GGT_PAYMENT_REQUIRED:?\\s*/, \"\") });\n process.exit(1);\n break;\n case graphqlError.extensions[\"requiresAdditionalCharge\"]:\n println({ ensureEmptyLineAbove: true, content: graphqlError.message.replace(/GGT_PAYMENT_REQUIRED:?\\s*/, \"\") });\n await confirm({ ensureEmptyLineAbove: true, content: \"Do you want to continue?\" });\n subscription.resubscribe({ ...variables, allowCharges: true });\n return;\n }\n }\n }\n\n await reportErrorAndExit(ctx, error);\n },\n onData: async ({ publishStatus }): Promise<void> => {\n if (!publishStatus) {\n ctx.log.warn(\"received empty publish status\");\n return;\n }\n\n const { publishStarted, progress: step, issues, status, deletedModelsAndFields } = publishStatus;\n const hasIssues = issues.length > 0;\n\n const { deletedModels, deletedModelFields } = deletedModelsAndFields ?? { deletedModels: [], deletedModelFields: [] };\n const hasDataLoss = deletedModels.length > 0 || deletedModelFields.length > 0;\n\n if (!printedProblems && (hasIssues || hasDataLoss)) {\n printedProblems = true;\n\n const fatalIssues = issues.filter((issue) => issue.severity === ProblemSeverity.Fatal);\n if (fatalIssues.length > 0) {\n await reportErrorAndExit(ctx, new DeployDisallowedError(publishIssuesToProblems(fatalIssues)));\n }\n\n if (hasIssues) {\n println({ ensureEmptyLineAbove: true, content: sprint`{bold.yellow !} {bold Issues found in your development app}` });\n printProblems({ problems: publishIssuesToProblems(issues) });\n }\n\n if (hasDataLoss) {\n println({\n ensureEmptyLineAbove: true,\n content: sprint`{bold.yellow !} {bold Data deleted on deploy}`,\n });\n\n const updated = chalk.blueBright(\"updated\");\n const deleted = chalk.redBright(\"deleted\");\n\n const rows: { symbol: string; name: string; action: string; indent: number }[] = [];\n\n deletedModels.forEach((model: string) => {\n rows.push({ symbol: deletedSymbol, name: chalk.redBright(model), action: deleted, indent: 0 });\n });\n\n deletedModelFields.forEach(({ modelIdentifier, fields }) => {\n rows.push({ symbol: updatedSymbol, name: chalk.blueBright(modelIdentifier), action: updated, indent: 0 });\n fields.forEach((field) => {\n rows.push({ symbol: deletedSymbol, name: chalk.redBright(field), action: deleted, indent: 2 });\n });\n });\n\n const longestNameLength = rows.reduce((longest, row) => Math.max(longest, row.name.length), 0);\n const longestIndent = rows.reduce((longest, row) => Math.max(longest, row.indent), 0);\n const indentSize = 2;\n\n println({\n ensureEmptyLineAbove: true,\n content: chalk.gray(\"These changes will be applied to production based on the app you're deploying.\"),\n });\n for (const row of rows) {\n const indentation = \" \".repeat(row.indent * indentSize);\n const namePadding = \" \".repeat(longestNameLength - row.name.length + 2);\n const actionPadding = \" \".repeat((longestIndent - row.indent) * indentSize);\n println({\n ensureEmptyLineAbove: false,\n content: indentString(`${indentation}${row.symbol} ${row.name}${namePadding}${actionPadding}${row.action}`, 6),\n });\n }\n }\n\n if (!publishStarted) {\n await confirm(\"Do you want to continue?\");\n subscription.resubscribe({ ...variables, force: true, allowDeletedData: true });\n } else {\n const allowDataDelete = args[\"--allow-data-delete\"];\n const allowProblems = args[\"--allow-problems\"];\n\n if (!allowDataDelete && !allowProblems) {\n throw new UnexpectedError(\"expected --allow-data-delete or --allow-problems to be true\");\n }\n\n if (allowProblems) {\n println(sprint`Deploying regardless of problems because \"${chalk.gray(\"--allow-problems\")}\" was passed.`);\n }\n\n if (allowDataDelete) {\n println(sprint`Deploying regardless of deleted data because \"${chalk.gray(\"--allow-data-delete\")}\" was passed.`);\n }\n }\n\n return;\n }\n\n if (status?.code === \"Errored\") {\n spinner?.fail(stepToSpinnerStart(syncJson, currentStep) + \" \" + ts());\n\n if (status.message) {\n println({ ensureEmptyLineAbove: true, content: chalk.red(status.message) });\n }\n if (status.output) {\n println({ ensureEmptyLineAbove: true, content: sprint`${terminalLink(\"Check logs\", status.output)}` });\n }\n return;\n }\n\n if (step === AppDeploymentSteps.COMPLETED) {\n spinner?.succeed(stepToSpinnerEnd(syncJson, currentStep));\n\n let content = chalk.green(\"Deploy successful!\");\n if (status?.output) {\n content += ` ${terminalLink(\"Check logs\", status.output)}.`;\n }\n\n println({ ensureEmptyLineAbove: true, content });\n return;\n }\n\n if (step !== currentStep) {\n const spinnerText = stepToSpinnerStart(syncJson, step);\n if (spinnerText !== spinner?.text) {\n // stop the current spinner, if any, and start a new one\n spinner?.succeed(stepToSpinnerEnd(syncJson, currentStep));\n\n const ensureEmptyLineAbove = currentStep === AppDeploymentSteps.NOT_STARTED || !output.isInteractive;\n spinner = spin({ ensureEmptyLineAbove, content: spinnerText });\n }\n\n currentStep = step as AppDeploymentSteps;\n }\n },\n onComplete: () => {\n subscription.unsubscribe();\n },\n });\n};\n\nexport const AppDeploymentSteps = Object.freeze({\n NOT_STARTED: \"NOT_STARTED\",\n STARTING: \"STARTING\",\n BUILDING_ASSETS: \"BUILDING_ASSETS\",\n UPLOADING_ASSETS: \"UPLOADING_ASSETS\",\n CONVERGING_STORAGE: \"CONVERGING_STORAGE\",\n PUBLISHING_TREE: \"PUBLISHING_TREE\",\n RELOADING_SANDBOX: \"RELOADING_SANDBOX\",\n COMPLETED: \"COMPLETED\",\n});\n\nexport type AppDeploymentSteps = (typeof AppDeploymentSteps)[keyof typeof AppDeploymentSteps];\n\nexport const stepToSpinnerStart = (syncJson: SyncJson, step: string): string => {\n switch (step) {\n case AppDeploymentSteps.NOT_STARTED:\n case AppDeploymentSteps.STARTING:\n case AppDeploymentSteps.BUILDING_ASSETS:\n case AppDeploymentSteps.UPLOADING_ASSETS:\n return \"Building frontend assets.\";\n case AppDeploymentSteps.CONVERGING_STORAGE:\n return \"Setting up database.\";\n case AppDeploymentSteps.PUBLISHING_TREE:\n return `Copying ${syncJson.environment.name}.`;\n case AppDeploymentSteps.RELOADING_SANDBOX:\n return \"Restarting app.\";\n case AppDeploymentSteps.COMPLETED:\n return \"Deploy complete!\";\n default:\n return \"Unknown step.\";\n }\n};\n\nexport const stepToSpinnerEnd = (syncJson: SyncJson, step: string): string => {\n switch (step) {\n case AppDeploymentSteps.NOT_STARTED:\n case AppDeploymentSteps.STARTING:\n case AppDeploymentSteps.BUILDING_ASSETS:\n case AppDeploymentSteps.UPLOADING_ASSETS:\n return `Built frontend assets. ${ts()}`;\n case AppDeploymentSteps.CONVERGING_STORAGE:\n return `Setup database. ${ts()}`;\n case AppDeploymentSteps.PUBLISHING_TREE:\n return `Copied ${syncJson.environment.name}. ${ts()}`;\n case AppDeploymentSteps.RELOADING_SANDBOX:\n return `Restarted app. ${ts()}`;\n case AppDeploymentSteps.COMPLETED:\n return \"Deploy successful!\";\n default:\n return `Completed unknown step. ${ts()}`;\n }\n};\n"],
|
|
5
|
-
"mappings": "omBAAAA,IAEA,OAAOC,OAAY,cAsBZ,IAAMC,GAAO,CAClB,GAAGA,EACH,QAAS,CAAE,KAAM,OAAQ,MAAO,CAAC,KAAM,gBAAiB,QAAQ,CAAE,EAClE,mBAAoB,CAAE,KAAM,QAAS,MAAO,gBAAiB,EA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kBACT,KAAKA,EAAmB,UACtB,MAAO,mBACT,QACE,MAAO,eACX,CACF,EAEaiD,GAAmB,CAAChE,EAAoB4B,IAAyB,CAC5E,OAAQA,EAAM,CACZ,KAAKb,EAAmB,YACxB,KAAKA,EAAmB,SACxB,KAAKA,EAAmB,gBACxB,KAAKA,EAAmB,iBACtB,MAAO,0BAA0BM,EAAG,CAAC,GACvC,KAAKN,EAAmB,mBACtB,MAAO,mBAAmBM,EAAG,CAAC,GAChC,KAAKN,EAAmB,gBACtB,MAAO,UAAUf,EAAS,YAAY,IAAI,KAAKqB,EAAG,CAAC,GACrD,KAAKN,EAAmB,kBACtB,MAAO,kBAAkBM,EAAG,CAAC,GAC/B,KAAKN,EAAmB,UACtB,MAAO,qBACT,QACE,MAAO,2BAA2BM,EAAG,CAAC,EAC1C,CACF",
|
|
6
|
-
"names": ["init_cjs", "assert", "args", "usage", "_ctx", "sprint", "run", "ctx", "directory", "loadSyncJsonDirectory", "syncJson", "SyncJson", "println", "terminalLink", "filesync", "FileSync", "hashes", "implicitForce", "output", "content", "unreachable", "confirm", "variables", "spinner", "currentStep", "AppDeploymentSteps", "printedProblems", "subscription", "PUBLISH_STATUS_SUBSCRIPTION", "error", "stepToSpinnerStart", "ts", "isGraphQLErrors", "graphqlError", "assert", "reportErrorAndExit", "publishStatus", "publishStarted", "step", "issues", "status", "deletedModelsAndFields", "hasIssues", "deletedModels", "deletedModelFields", "hasDataLoss", "fatalIssues", "issue", "ProblemSeverity", "DeployDisallowedError", "publishIssuesToProblems", "printProblems", "updated", "source_default", "deleted", "rows", "model", "deletedSymbol", "modelIdentifier", "fields", "updatedSymbol", "field", "longestNameLength", "longest", "row", "longestIndent", "indentSize", "indentation", "namePadding", "actionPadding", "indentString", "allowDataDelete", "allowProblems", "UnexpectedError", "stepToSpinnerEnd", "spinnerText", "ensureEmptyLineAbove", "spin"]
|
|
7
|
-
}
|
package/dist/login-UGTNK3B3.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{e as a,f as b,g as c}from"./chunk-YQO2R55C.js";import"./chunk-CQH5IRAO.js";import"./chunk-3B5DKR5D.js";import"./chunk-JU6IEBE5.js";import"./chunk-B6XQEEUK.js";import"./chunk-SGMPMYEU.js";export{c as login,b as run,a as usage};
|
|
2
|
-
//# sourceMappingURL=login-UGTNK3B3.js.map
|
package/dist/push-2NCJSDGS.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a,b,c}from"./chunk-LQDBD3BI.js";import"./chunk-J5XIQ6N4.js";import"./chunk-VE2URKOG.js";import"./chunk-ENT5WEIR.js";import"./chunk-WBESFPTY.js";import"./chunk-ZHG3WLFU.js";import"./chunk-FQ2LR3BI.js";import"./chunk-YQO2R55C.js";import"./chunk-CQH5IRAO.js";import"./chunk-3B5DKR5D.js";import"./chunk-JU6IEBE5.js";import"./chunk-B6XQEEUK.js";import"./chunk-SGMPMYEU.js";export{a as args,c as run,b as usage};
|
|
2
|
-
//# sourceMappingURL=push-2NCJSDGS.js.map
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|