@wirecat/drive-cli 0.57.0 → 0.59.0
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/bin/drive.js +6 -2
- package/dist/bin/drive.js.map +1 -1
- package/dist/bundle/{all-profiles-7LSZ3CC3.js → all-profiles-CVISDGMF.js} +14 -9
- package/dist/bundle/{anthropic-3QRM4QXB.js → anthropic-WLNQC23G.js} +11 -7
- package/dist/bundle/{app-server-WWNMUHID.js → app-server-P2VOONXF.js} +61 -53
- package/dist/bundle/{bun-NIIYUR5F.js → bun-CDFBNTKV.js} +2 -2
- package/dist/bundle/{bun-sqlite-GSLSN3OT.js → bun-sqlite-MNZICITP.js} +8 -4
- package/dist/bundle/chunk-2AXA5SKP.js +23 -0
- package/dist/bundle/{chunk-EFEI724Z.js → chunk-36B7AIGP.js} +1 -1
- package/dist/bundle/{chunk-Q3TMNETS.js → chunk-3KJTJDDT.js} +52 -39
- package/dist/bundle/{chunk-4F2VRJZE.js → chunk-3KNZADHJ.js} +5080 -626
- package/dist/bundle/{chunk-GIQFBXQN.js → chunk-3U22QTU6.js} +12 -125
- package/dist/bundle/chunk-3VSUT6BD.js +35 -0
- package/dist/bundle/{chunk-U2RSVKR5.js → chunk-5C7K6XIT.js} +1 -1
- package/dist/bundle/{chunk-6CFSDU56.js → chunk-6C6255U6.js} +16 -14
- package/dist/bundle/{chunk-EE7R457T.js → chunk-6CQO2FIN.js} +1569 -739
- package/dist/bundle/{chunk-KHNDZNQA.js → chunk-7QTVIZII.js} +5410 -3002
- package/dist/bundle/{chunk-HNUSPNUQ.js → chunk-A6EG7ZDS.js} +13 -13
- package/dist/bundle/{chunk-WBYCUBYM.js → chunk-A6SLYOP2.js} +49 -42
- package/dist/bundle/{chunk-TR5656OS.js → chunk-AD62XJKO.js} +162 -106
- package/dist/bundle/{chunk-TKVSJV5P.js → chunk-B5GBJ35N.js} +6 -4
- package/dist/bundle/{chunk-LSSIVBQI.js → chunk-BSGOM3BD.js} +1 -1
- package/dist/bundle/{chunk-XGNADVIA.js → chunk-CBM2XAEZ.js} +28 -229
- package/dist/bundle/{chunk-OYNSFQ7K.js → chunk-D72URWJE.js} +1 -39
- package/dist/bundle/{chunk-L4BBK7UX.js → chunk-DI5Z4SH5.js} +5 -3
- package/dist/bundle/chunk-EBLA7GXY.js +45 -0
- package/dist/bundle/{chunk-4UQLL6RJ.js → chunk-EHEZSV6I.js} +11 -88
- package/dist/bundle/{chunk-6ZA4NR5H.js → chunk-EORMZCVF.js} +3 -3
- package/dist/bundle/{chunk-W5FOPSJZ.js → chunk-EVETU3TF.js} +10 -8
- package/dist/bundle/{chunk-TZHCS5MG.js → chunk-F3FOL42A.js} +2 -2
- package/dist/bundle/{chunk-2QLLKDE5.js → chunk-FICVPYE4.js} +206 -73
- package/dist/bundle/{chunk-AKPFH3KC.js → chunk-FVQCM7IQ.js} +1 -1
- package/dist/bundle/{chunk-ADLS6FVG.js → chunk-FXBHOCJK.js} +1 -1
- package/dist/bundle/{chunk-WAVJWGUC.js → chunk-GI5JBGXH.js} +4611 -1530
- package/dist/bundle/{chunk-SRNXTXJN.js → chunk-GJ4ZCIOP.js} +3 -3
- package/dist/bundle/{chunk-GKHUHRSL.js → chunk-GT5KTGCN.js} +4 -4
- package/dist/bundle/{chunk-WJOKTIOJ.js → chunk-H2BKXPBL.js} +2 -2
- package/dist/bundle/chunk-HIOJRPCT.js +93 -0
- package/dist/bundle/chunk-HIP43OGZ.js +34 -0
- package/dist/bundle/{chunk-2ULJW5BA.js → chunk-HMZAMHKN.js} +2 -2
- package/dist/bundle/{chunk-64E6QXXQ.js → chunk-HWLLVLAB.js} +10 -10
- package/dist/bundle/{chunk-373WJIHE.js → chunk-IADOBOKB.js} +2 -2
- package/dist/bundle/{chunk-B3TPS7BW.js → chunk-IBZ3IBO4.js} +9 -7
- package/dist/bundle/{chunk-QAT6UXZZ.js → chunk-IGF6EXBR.js} +53 -48
- package/dist/bundle/{chunk-KYNTSA6K.js → chunk-II7LST64.js} +5 -5
- package/dist/bundle/{chunk-JLKNUFL2.js → chunk-IIP43FQJ.js} +2 -2
- package/dist/bundle/{chunk-ELIYJXIY.js → chunk-JSDVK3JA.js} +2 -2
- package/dist/bundle/{chunk-UKMFPBAO.js → chunk-JW2CVCUH.js} +4 -4
- package/dist/bundle/{chunk-O5KDIVGE.js → chunk-K4LXGZTE.js} +23 -21
- package/dist/bundle/{chunk-RB674T6L.js → chunk-KFZUODXB.js} +76 -20
- package/dist/bundle/chunk-KPRGTTJH.js +34 -0
- package/dist/bundle/{chunk-XJVK7ETL.js → chunk-L5SE2XZP.js} +23 -15
- package/dist/bundle/{chunk-OOR6PEHV.js → chunk-LJ7E4HLQ.js} +1 -1
- package/dist/bundle/{chunk-VTJF2L5E.js → chunk-LPHMAQJQ.js} +16 -16
- package/dist/bundle/{chunk-566W4Q6L.js → chunk-M6I2SQN7.js} +4 -4
- package/dist/bundle/{chunk-NLLWLCUZ.js → chunk-MEAPA4EZ.js} +2 -2
- package/dist/bundle/{chunk-J2HGHSLX.js → chunk-MKCNUI72.js} +4 -4
- package/dist/bundle/{chunk-CD736BG3.js → chunk-MUUHUHWC.js} +2 -1
- package/dist/bundle/{chunk-AHBUTDS7.js → chunk-OKXSTWKW.js} +8 -8
- package/dist/bundle/{chunk-W6FYYQ2J.js → chunk-OMMEQJOB.js} +3 -3
- package/dist/bundle/{chunk-EFX6FIDM.js → chunk-OZH4ALTI.js} +1 -1
- package/dist/bundle/{chunk-KM4Y55ZE.js → chunk-P3ZTW2ZM.js} +7 -7
- package/dist/bundle/{chunk-5KNIVHP6.js → chunk-P7WPYKSB.js} +7 -20
- package/dist/bundle/{chunk-RAEKC6TV.js → chunk-PAEVBAM3.js} +9 -42
- package/dist/bundle/{chunk-LBFFI6FE.js → chunk-PGKIOSN3.js} +9 -7
- package/dist/bundle/{chunk-WJPVGXKA.js → chunk-QTM7USFA.js} +8 -13
- package/dist/bundle/{chunk-EN7OZ5JH.js → chunk-TFH5X46A.js} +37 -22
- package/dist/bundle/{chunk-OZJMZSFB.js → chunk-TI55J3BA.js} +6 -4
- package/dist/bundle/{chunk-R5GJZPRF.js → chunk-TJXPJ3A5.js} +572 -366
- package/dist/bundle/chunk-UQPKAY6I.js +106 -0
- package/dist/bundle/{chunk-JUKVJ7M2.js → chunk-UWVNRPT7.js} +56 -40
- package/dist/bundle/chunk-V36RIXFA.js +201 -0
- package/dist/bundle/{chunk-JIGMCW4C.js → chunk-V42KAPU3.js} +6 -6
- package/dist/bundle/{chunk-7SNS443B.js → chunk-VT6GZAF4.js} +35 -35
- package/dist/bundle/{chunk-ISK4K7UE.js → chunk-VVCZS42A.js} +1 -1
- package/dist/bundle/chunk-W62CON5K.js +166 -0
- package/dist/bundle/{chunk-YZ6SYLDC.js → chunk-XCOCPXCM.js} +2 -2
- package/dist/bundle/{chunk-G34Y5RAC.js → chunk-YADXWQHV.js} +29 -29
- package/dist/bundle/{chunk-AL7MY7MW.js → chunk-YU3PTU3D.js} +1 -1
- package/dist/bundle/{chunk-IJ2S53WJ.js → chunk-YV4ABH6J.js} +7 -7
- package/dist/bundle/{chunk-B64EY2SC.js → chunk-ZSMCJKGP.js} +42 -41
- package/dist/bundle/chunk-ZYCLPJ7U.js +46 -0
- package/dist/bundle/command-contract-LQDNHZJU.js +39 -0
- package/dist/bundle/{decode-5MHMPYKE.js → decode-XTOMXMGN.js} +10 -6
- package/dist/bundle/dispatch-T6TW2JJB.js +412 -0
- package/dist/bundle/drive.js +40 -22
- package/dist/bundle/{echarts-CLB22SZS.js → echarts-RKKIOYVV.js} +2 -2
- package/dist/bundle/{embed-TF66ODAR.js → embed-STHKKA6G.js} +9 -5
- package/dist/bundle/{embedder-EDWOIAC2.js → embedder-3XZEWHRO.js} +14 -10
- package/dist/bundle/entry-CNOYSSSD.js +22 -0
- package/dist/bundle/failure-DNQYXP2T.js +26 -0
- package/dist/bundle/first-run-F2SI24PK.js +30 -0
- package/dist/bundle/first-screen-TYYF6VXY.js +37 -0
- package/dist/bundle/{google-A4F2WFO4.js → google-BYNSAIQI.js} +13 -9
- package/dist/bundle/{google-api-ZXGQOJUI.js → google-api-4VTZH7OP.js} +59 -52
- package/dist/bundle/grants-EUQXSICG.js +105 -0
- package/dist/bundle/{identity-4IO7WGG4.js → identity-ARDPFYV5.js} +6 -4
- package/dist/bundle/{instructions-BXZZNAMS.js → instructions-N3OH5X2Y.js} +1 -1
- package/dist/bundle/{login-A4QHJ5DA.js → login-4VQEC7VI.js} +65 -58
- package/dist/bundle/{mcp-VVMPUDSL.js → mcp-WBHKX5E3.js} +5 -3
- package/dist/bundle/{node-P4E63KXA.js → node-KM3CUABH.js} +9 -9
- package/dist/bundle/{node-R6ZNQ3NT.js → node-YU5JBNAA.js} +2 -2
- package/dist/bundle/{node-sqlite-AFQTE4XZ.js → node-sqlite-3C6PSBIW.js} +14 -4
- package/dist/bundle/oauth-D6NJFPYU.js +22 -0
- package/dist/bundle/{open-WJCRBIP7.js → open-M2V2VYXO.js} +8 -3
- package/dist/bundle/{openai-3TIBDWZA.js → openai-ST2IWNUX.js} +18 -14
- package/dist/bundle/{process-P36JP33R.js → process-PYNNBBTV.js} +1 -1
- package/dist/bundle/{program-AHZH65IT.js → program-Q4VWV2MR.js} +193 -147
- package/dist/bundle/prompt-MFIOJMAF.js +17 -0
- package/dist/bundle/{reasons-VHCVYH54.js → reasons-LOQ5J73F.js} +5 -3
- package/dist/bundle/{recognize-4EAKIMON.js → recognize-FBLMWXNE.js} +7 -3
- package/dist/bundle/{remote-HX3JP4EH.js → remote-XC3OXE4T.js} +10 -6
- package/dist/bundle/{rerank-BW3A4PUU.js → rerank-2XMKKF4S.js} +10 -6
- package/dist/bundle/{serve-YYOOLIBS.js → serve-Q2BQHNZB.js} +15 -10
- package/dist/bundle/{server-G6XTEEFI.js → server-42HPV3AH.js} +46 -39
- package/dist/bundle/server-EWZYN323.js +70 -0
- package/dist/bundle/{services-OAPILZOW.js → services-WU22S2MU.js} +100 -26
- package/dist/bundle/{sqlite-runtime-GTXDK4PE.js → sqlite-runtime-CSO6K6B2.js} +9 -4
- package/dist/bundle/start-TZWKM4AH.js +138 -0
- package/dist/bundle/{state-XG335LGZ.js → state-FLUT7U7R.js} +9 -5
- package/dist/bundle/{store-N53SJOPS.js → store-HDWMJ44E.js} +42 -17
- package/dist/bundle/{store-7KOXJNQP.js → store-TG6622NG.js} +20 -12
- package/dist/bundle/store-maintenance-command-RHWRUREJ.js +60 -0
- package/dist/bundle/tokens-TXYURU4S.js +103 -0
- package/dist/commands/documents.d.ts +1 -0
- package/dist/commands/documents.d.ts.map +1 -1
- package/dist/commands/documents.js +14 -1
- package/dist/commands/documents.js.map +1 -1
- package/dist/commands/knowledge.d.ts +4 -0
- package/dist/commands/knowledge.d.ts.map +1 -1
- package/dist/commands/knowledge.js +8 -7
- package/dist/commands/knowledge.js.map +1 -1
- package/dist/contract-overrides.js +5 -5
- package/dist/contract-overrides.js.map +1 -1
- package/dist/knowledge-query.d.ts +2 -0
- package/dist/knowledge-query.d.ts.map +1 -1
- package/dist/program.d.ts.map +1 -1
- package/dist/program.js +8 -3
- package/dist/program.js.map +1 -1
- package/dist/provider-json.d.ts +2 -0
- package/dist/provider-json.d.ts.map +1 -1
- package/dist/provider-json.js +13 -0
- package/dist/provider-json.js.map +1 -1
- package/dist/reasons.d.ts.map +1 -1
- package/dist/reasons.js +1 -0
- package/dist/reasons.js.map +1 -1
- package/dist/store.d.ts +2 -0
- package/dist/store.d.ts.map +1 -1
- package/dist/store.js +9 -0
- package/dist/store.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +5 -4
- package/skills/drive-cli/SKILL.md +2 -1
- package/dist/bundle/chunk-3BXSLNWW.js +0 -3607
- package/dist/bundle/chunk-CGCQNYB3.js +0 -18
- package/dist/bundle/command-contract-XIACCAZL.js +0 -35
- package/dist/bundle/entry-CWYCQ53A.js +0 -17
- package/dist/bundle/first-run-YIH7EHJI.js +0 -24
- package/dist/bundle/first-screen-THH3XD5Y.js +0 -33
- package/dist/bundle/grants-3Z7DG3W3.js +0 -98
- package/dist/bundle/oauth-46XBJBML.js +0 -18
- package/dist/bundle/prompt-FFGBIT4A.js +0 -13
- package/dist/bundle/server-YKYEUIJT.js +0 -63
- package/dist/bundle/store-maintenance-command-W3TI52X2.js +0 -52
- package/dist/bundle/tokens-P7TEHKDD.js +0 -96
- /package/dist/bundle/{chunk-HPXYN7F3.js → chunk-LK2E2ELG.js} +0 -0
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
import { createRequire as __bundleRequire } from "node:module";
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
|
+
import {
|
|
4
|
+
DOC,
|
|
5
|
+
DOCUMENT_LIST_FIELDS,
|
|
6
|
+
FOLDER,
|
|
7
|
+
MAX_ENTRIES,
|
|
8
|
+
metadataJson,
|
|
9
|
+
supported,
|
|
10
|
+
tooManyEntries
|
|
11
|
+
} from "./chunk-VVCZS42A.js";
|
|
3
12
|
import {
|
|
4
13
|
ACCOUNT_FREE_COMMANDS,
|
|
5
14
|
ANY_PROFILE_COMMANDS,
|
|
@@ -10,25 +19,7 @@ import {
|
|
|
10
19
|
describeDriveProgram,
|
|
11
20
|
examples,
|
|
12
21
|
markProfileFree
|
|
13
|
-
} from "./chunk-
|
|
14
|
-
import {
|
|
15
|
-
apiMethod,
|
|
16
|
-
apiMethods,
|
|
17
|
-
jsonObject,
|
|
18
|
-
operationOf,
|
|
19
|
-
schemas,
|
|
20
|
-
validateApiParams,
|
|
21
|
-
validateRequest
|
|
22
|
-
} from "./chunk-TKVSJV5P.js";
|
|
23
|
-
import {
|
|
24
|
-
DOC,
|
|
25
|
-
DOCUMENT_LIST_FIELDS,
|
|
26
|
-
FOLDER,
|
|
27
|
-
MAX_ENTRIES,
|
|
28
|
-
metadataJson,
|
|
29
|
-
supported,
|
|
30
|
-
tooManyEntries
|
|
31
|
-
} from "./chunk-ISK4K7UE.js";
|
|
22
|
+
} from "./chunk-II7LST64.js";
|
|
32
23
|
import {
|
|
33
24
|
DEFAULTS_ONLY,
|
|
34
25
|
DEFAULT_LEVELS,
|
|
@@ -54,7 +45,35 @@ import {
|
|
|
54
45
|
textLimit,
|
|
55
46
|
unknownProfile,
|
|
56
47
|
writeConfig
|
|
57
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-K4LXGZTE.js";
|
|
49
|
+
import {
|
|
50
|
+
blockKey,
|
|
51
|
+
blocksMarkdown,
|
|
52
|
+
catalogFiles,
|
|
53
|
+
diffBlocks,
|
|
54
|
+
documentIngestion,
|
|
55
|
+
documentKnowledge,
|
|
56
|
+
extractDocumentMemories,
|
|
57
|
+
fileMirrorState,
|
|
58
|
+
markdownBlocks,
|
|
59
|
+
mergeBlocks,
|
|
60
|
+
mirrorId,
|
|
61
|
+
mirrorStatus,
|
|
62
|
+
normalizeInlines,
|
|
63
|
+
spliceMarkdown,
|
|
64
|
+
syncDocuments,
|
|
65
|
+
syncMirrors,
|
|
66
|
+
watchMirrors
|
|
67
|
+
} from "./chunk-UWVNRPT7.js";
|
|
68
|
+
import {
|
|
69
|
+
apiMethod,
|
|
70
|
+
apiMethods,
|
|
71
|
+
jsonObject,
|
|
72
|
+
operationOf,
|
|
73
|
+
schemas,
|
|
74
|
+
validateApiParams,
|
|
75
|
+
validateRequest
|
|
76
|
+
} from "./chunk-B5GBJ35N.js";
|
|
58
77
|
import {
|
|
59
78
|
DISCOVERY_DESCRIPTIONS,
|
|
60
79
|
MEMO_SCENARIOS,
|
|
@@ -84,52 +103,24 @@ import {
|
|
|
84
103
|
skillCommand,
|
|
85
104
|
suggest,
|
|
86
105
|
upgradeCommand
|
|
87
|
-
} from "./chunk-
|
|
88
|
-
import {
|
|
89
|
-
blockKey,
|
|
90
|
-
blocksMarkdown,
|
|
91
|
-
catalogFiles,
|
|
92
|
-
diffBlocks,
|
|
93
|
-
documentIngestion,
|
|
94
|
-
documentKnowledge,
|
|
95
|
-
extractDocumentMemories,
|
|
96
|
-
fileMirrorState,
|
|
97
|
-
markdownBlocks,
|
|
98
|
-
mergeBlocks,
|
|
99
|
-
mirrorId,
|
|
100
|
-
mirrorStatus,
|
|
101
|
-
normalizeInlines,
|
|
102
|
-
spliceMarkdown,
|
|
103
|
-
syncDocuments,
|
|
104
|
-
syncMirrors,
|
|
105
|
-
watchMirrors
|
|
106
|
-
} from "./chunk-JUKVJ7M2.js";
|
|
106
|
+
} from "./chunk-6CQO2FIN.js";
|
|
107
107
|
import {
|
|
108
108
|
googleError
|
|
109
|
-
} from "./chunk-
|
|
110
|
-
import "./chunk-
|
|
111
|
-
import "./chunk-OOR6PEHV.js";
|
|
112
|
-
import "./chunk-RB674T6L.js";
|
|
109
|
+
} from "./chunk-FVQCM7IQ.js";
|
|
110
|
+
import "./chunk-LJ7E4HLQ.js";
|
|
113
111
|
import "./chunk-SBZB7HMU.js";
|
|
114
|
-
import
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
VERSION
|
|
118
|
-
} from "./chunk-NLLWLCUZ.js";
|
|
119
|
-
import {
|
|
120
|
-
REASONS
|
|
121
|
-
} from "./chunk-CD736BG3.js";
|
|
122
|
-
import "./chunk-AL7MY7MW.js";
|
|
123
|
-
import "./chunk-GKHUHRSL.js";
|
|
112
|
+
import "./chunk-YU3PTU3D.js";
|
|
113
|
+
import "./chunk-A6SLYOP2.js";
|
|
114
|
+
import "./chunk-KFZUODXB.js";
|
|
124
115
|
import {
|
|
125
116
|
modelGateway,
|
|
126
117
|
storeInfo
|
|
127
|
-
} from "./chunk-
|
|
118
|
+
} from "./chunk-FICVPYE4.js";
|
|
128
119
|
import {
|
|
129
120
|
RecipientList,
|
|
130
121
|
SendJournal,
|
|
131
122
|
sendGuard
|
|
132
|
-
} from "./chunk-
|
|
123
|
+
} from "./chunk-ZSMCJKGP.js";
|
|
133
124
|
import {
|
|
134
125
|
LIST_QUERY_GUIDE,
|
|
135
126
|
listQuery,
|
|
@@ -140,29 +131,13 @@ import {
|
|
|
140
131
|
typedQuery,
|
|
141
132
|
unfilteredQuery,
|
|
142
133
|
withQuery
|
|
143
|
-
} from "./chunk-
|
|
144
|
-
import "./chunk-SRNXTXJN.js";
|
|
145
|
-
import {
|
|
146
|
-
newOperationId
|
|
147
|
-
} from "./chunk-KHNDZNQA.js";
|
|
148
|
-
import "./chunk-HNUSPNUQ.js";
|
|
149
|
-
import {
|
|
150
|
-
columnName,
|
|
151
|
-
readSpreadsheet
|
|
152
|
-
} from "./chunk-G34Y5RAC.js";
|
|
153
|
-
import {
|
|
154
|
-
applyDocumentTransfer,
|
|
155
|
-
previewDocumentTransfer
|
|
156
|
-
} from "./chunk-VTJF2L5E.js";
|
|
134
|
+
} from "./chunk-TFH5X46A.js";
|
|
157
135
|
import {
|
|
158
136
|
commandsText,
|
|
159
137
|
inSection
|
|
160
|
-
} from "./chunk-
|
|
138
|
+
} from "./chunk-EVETU3TF.js";
|
|
161
139
|
import "./chunk-HTQTIKWP.js";
|
|
162
|
-
import
|
|
163
|
-
answerEntity
|
|
164
|
-
} from "./chunk-RAEKC6TV.js";
|
|
165
|
-
import "./chunk-3BXSLNWW.js";
|
|
140
|
+
import "./chunk-PAEVBAM3.js";
|
|
166
141
|
import {
|
|
167
142
|
FETCH,
|
|
168
143
|
InvalidArgumentError,
|
|
@@ -172,6 +147,7 @@ import {
|
|
|
172
147
|
Option,
|
|
173
148
|
REMOTE_WRITE,
|
|
174
149
|
annotate,
|
|
150
|
+
answerEntity,
|
|
175
151
|
changesAuthority,
|
|
176
152
|
commandWords,
|
|
177
153
|
customizeSharedCommand,
|
|
@@ -192,9 +168,29 @@ import {
|
|
|
192
168
|
resolveAISettings,
|
|
193
169
|
rootOf,
|
|
194
170
|
snakeKeys
|
|
195
|
-
} from "./chunk-
|
|
196
|
-
import "./chunk-
|
|
197
|
-
import "./chunk-
|
|
171
|
+
} from "./chunk-3KNZADHJ.js";
|
|
172
|
+
import "./chunk-EHEZSV6I.js";
|
|
173
|
+
import "./chunk-6C6255U6.js";
|
|
174
|
+
import {
|
|
175
|
+
setupPermissionCeiling
|
|
176
|
+
} from "./chunk-JW2CVCUH.js";
|
|
177
|
+
import "./chunk-HWLLVLAB.js";
|
|
178
|
+
import {
|
|
179
|
+
readOnlyLockOf,
|
|
180
|
+
readOnlyRefusal
|
|
181
|
+
} from "./chunk-IIP43FQJ.js";
|
|
182
|
+
import "./chunk-GT5KTGCN.js";
|
|
183
|
+
import "./chunk-GJ4ZCIOP.js";
|
|
184
|
+
import "./chunk-5C7K6XIT.js";
|
|
185
|
+
import "./chunk-DI5Z4SH5.js";
|
|
186
|
+
import {
|
|
187
|
+
newOperationId
|
|
188
|
+
} from "./chunk-7QTVIZII.js";
|
|
189
|
+
import {
|
|
190
|
+
columnName,
|
|
191
|
+
readSpreadsheet
|
|
192
|
+
} from "./chunk-YADXWQHV.js";
|
|
193
|
+
import "./chunk-A6EG7ZDS.js";
|
|
198
194
|
import {
|
|
199
195
|
CEILING_KEY,
|
|
200
196
|
LEVELS,
|
|
@@ -203,49 +199,40 @@ import {
|
|
|
203
199
|
layerPermissions,
|
|
204
200
|
levelFor,
|
|
205
201
|
parseDuration
|
|
206
|
-
} from "./chunk-
|
|
207
|
-
import "./chunk-
|
|
208
|
-
import {
|
|
209
|
-
note
|
|
210
|
-
} from "./chunk-7SNS443B.js";
|
|
211
|
-
import "./chunk-6CFSDU56.js";
|
|
202
|
+
} from "./chunk-AD62XJKO.js";
|
|
203
|
+
import "./chunk-HMZAMHKN.js";
|
|
212
204
|
import {
|
|
213
|
-
installerOf,
|
|
214
205
|
latestVersion,
|
|
215
206
|
runUpdate,
|
|
216
207
|
updateNotice
|
|
217
|
-
} from "./chunk-
|
|
218
|
-
import "./chunk-
|
|
208
|
+
} from "./chunk-P7WPYKSB.js";
|
|
209
|
+
import "./chunk-ZYCLPJ7U.js";
|
|
210
|
+
import "./chunk-JSDVK3JA.js";
|
|
211
|
+
import "./chunk-EORMZCVF.js";
|
|
212
|
+
import "./chunk-P3ZTW2ZM.js";
|
|
213
|
+
import "./chunk-5DPV7X27.js";
|
|
214
|
+
import "./chunk-TI55J3BA.js";
|
|
219
215
|
import {
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
216
|
+
applyDocumentTransfer,
|
|
217
|
+
previewDocumentTransfer
|
|
218
|
+
} from "./chunk-LPHMAQJQ.js";
|
|
223
219
|
import {
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
import "./chunk-W6FYYQ2J.js";
|
|
228
|
-
import "./chunk-TZHCS5MG.js";
|
|
229
|
-
import "./chunk-L4BBK7UX.js";
|
|
230
|
-
import "./chunk-ELIYJXIY.js";
|
|
231
|
-
import "./chunk-6ZA4NR5H.js";
|
|
232
|
-
import "./chunk-KM4Y55ZE.js";
|
|
233
|
-
import "./chunk-5DPV7X27.js";
|
|
234
|
-
import "./chunk-OZJMZSFB.js";
|
|
235
|
-
import "./chunk-WJOKTIOJ.js";
|
|
220
|
+
note
|
|
221
|
+
} from "./chunk-VT6GZAF4.js";
|
|
222
|
+
import "./chunk-H2BKXPBL.js";
|
|
236
223
|
import {
|
|
237
224
|
CATALOG_QUERY,
|
|
238
225
|
IMPORTED_DOCUMENT_QUERY,
|
|
239
226
|
openStore
|
|
240
|
-
} from "./chunk-
|
|
241
|
-
import "./chunk-
|
|
227
|
+
} from "./chunk-GI5JBGXH.js";
|
|
228
|
+
import "./chunk-IADOBOKB.js";
|
|
242
229
|
import {
|
|
243
230
|
FACT_STATUSES,
|
|
244
231
|
FACT_TYPES,
|
|
245
232
|
MEMORY_KINDS,
|
|
246
233
|
MEMORY_SCOPES,
|
|
247
234
|
MEMORY_STATUSES
|
|
248
|
-
} from "./chunk-
|
|
235
|
+
} from "./chunk-TJXPJ3A5.js";
|
|
249
236
|
import {
|
|
250
237
|
dateRange,
|
|
251
238
|
defineQuery,
|
|
@@ -255,26 +242,45 @@ import {
|
|
|
255
242
|
timezoneOf,
|
|
256
243
|
validateQuery,
|
|
257
244
|
zonedMoment
|
|
258
|
-
} from "./chunk-
|
|
259
|
-
import "./chunk-
|
|
260
|
-
import "./chunk-
|
|
261
|
-
import "./chunk-
|
|
245
|
+
} from "./chunk-L5SE2XZP.js";
|
|
246
|
+
import "./chunk-HIOJRPCT.js";
|
|
247
|
+
import "./chunk-OKXSTWKW.js";
|
|
248
|
+
import "./chunk-IBZ3IBO4.js";
|
|
262
249
|
import {
|
|
263
250
|
storePath
|
|
264
|
-
} from "./chunk-
|
|
265
|
-
import "./chunk-
|
|
251
|
+
} from "./chunk-3VSUT6BD.js";
|
|
252
|
+
import "./chunk-QTM7USFA.js";
|
|
253
|
+
import "./chunk-BSGOM3BD.js";
|
|
254
|
+
import "./chunk-OMMEQJOB.js";
|
|
255
|
+
import "./chunk-F3FOL42A.js";
|
|
256
|
+
import "./chunk-D72URWJE.js";
|
|
257
|
+
import {
|
|
258
|
+
installerOf
|
|
259
|
+
} from "./chunk-2AXA5SKP.js";
|
|
260
|
+
import {
|
|
261
|
+
DRIVE_APP,
|
|
262
|
+
PACKAGE,
|
|
263
|
+
VERSION
|
|
264
|
+
} from "./chunk-MEAPA4EZ.js";
|
|
265
|
+
import {
|
|
266
|
+
REASONS
|
|
267
|
+
} from "./chunk-MUUHUHWC.js";
|
|
268
|
+
import "./chunk-LK2E2ELG.js";
|
|
269
|
+
import "./chunk-KPRGTTJH.js";
|
|
266
270
|
import {
|
|
267
271
|
processStreams,
|
|
268
272
|
saveConfigFile,
|
|
269
273
|
writeSecurely
|
|
270
|
-
} from "./chunk-
|
|
274
|
+
} from "./chunk-CBM2XAEZ.js";
|
|
275
|
+
import "./chunk-V36RIXFA.js";
|
|
276
|
+
import "./chunk-Y5E2WNWB.js";
|
|
277
|
+
import "./chunk-HIP43OGZ.js";
|
|
278
|
+
import "./chunk-UQPKAY6I.js";
|
|
271
279
|
import {
|
|
272
|
-
CliError,
|
|
273
280
|
array,
|
|
274
281
|
boolean,
|
|
275
282
|
defineSteps,
|
|
276
283
|
integer,
|
|
277
|
-
isCliError,
|
|
278
284
|
isoTime,
|
|
279
285
|
literal,
|
|
280
286
|
looseObject,
|
|
@@ -293,9 +299,11 @@ import {
|
|
|
293
299
|
string,
|
|
294
300
|
unknown,
|
|
295
301
|
writes
|
|
296
|
-
} from "./chunk-
|
|
297
|
-
import
|
|
298
|
-
|
|
302
|
+
} from "./chunk-3U22QTU6.js";
|
|
303
|
+
import {
|
|
304
|
+
CliError,
|
|
305
|
+
isCliError
|
|
306
|
+
} from "./chunk-EBLA7GXY.js";
|
|
299
307
|
import {
|
|
300
308
|
__commonJS,
|
|
301
309
|
__name,
|
|
@@ -2710,7 +2718,7 @@ var installModelCommands = /* @__PURE__ */ __name((program, { env, output, strea
|
|
|
2710
2718
|
throw new CliError("permission_error", "downloading a model needs the network; --offline was requested", {
|
|
2711
2719
|
reason: "offline.refused"
|
|
2712
2720
|
});
|
|
2713
|
-
const { downloadImageModel, downloadTextModel } = await import("./services-
|
|
2721
|
+
const { downloadImageModel, downloadTextModel } = await import("./services-WU22S2MU.js");
|
|
2714
2722
|
const progress = /* @__PURE__ */ __name((line) => {
|
|
2715
2723
|
if (!program.opts().quiet)
|
|
2716
2724
|
streams.diagnostic(line);
|
|
@@ -2810,7 +2818,7 @@ var SHELL_OVERRIDES = {
|
|
|
2810
2818
|
name: "document",
|
|
2811
2819
|
required: true,
|
|
2812
2820
|
variadic: false,
|
|
2813
|
-
description: "Google file or folder id or URL in the local catalog"
|
|
2821
|
+
description: "Google file or folder id or URL in the local catalog, or a document:<n> ref"
|
|
2814
2822
|
},
|
|
2815
2823
|
{
|
|
2816
2824
|
name: "text",
|
|
@@ -3136,7 +3144,7 @@ var SHELL_OVERRIDES = {
|
|
|
3136
3144
|
name: "document",
|
|
3137
3145
|
required: true,
|
|
3138
3146
|
variadic: false,
|
|
3139
|
-
description: "Google file or folder id or URL in the local catalog"
|
|
3147
|
+
description: "Google file or folder id or URL in the local catalog, or a document:<n> ref"
|
|
3140
3148
|
},
|
|
3141
3149
|
{
|
|
3142
3150
|
name: "query",
|
|
@@ -3192,7 +3200,7 @@ var SHELL_OVERRIDES = {
|
|
|
3192
3200
|
name: "document",
|
|
3193
3201
|
required: true,
|
|
3194
3202
|
variadic: false,
|
|
3195
|
-
description: "Google file or folder id or URL in the local catalog"
|
|
3203
|
+
description: "Google file or folder id or URL in the local catalog, or a document:<n> ref"
|
|
3196
3204
|
},
|
|
3197
3205
|
{
|
|
3198
3206
|
name: "note",
|
|
@@ -3239,7 +3247,7 @@ var SHELL_OVERRIDES = {
|
|
|
3239
3247
|
name: "document",
|
|
3240
3248
|
required: true,
|
|
3241
3249
|
variadic: false,
|
|
3242
|
-
description: "Google file or folder id or URL in the local catalog"
|
|
3250
|
+
description: "Google file or folder id or URL in the local catalog, or a document:<n> ref"
|
|
3243
3251
|
},
|
|
3244
3252
|
{
|
|
3245
3253
|
name: "note",
|
|
@@ -3300,7 +3308,7 @@ var SHELL_OVERRIDES = {
|
|
|
3300
3308
|
name: "document",
|
|
3301
3309
|
required: true,
|
|
3302
3310
|
variadic: false,
|
|
3303
|
-
description: "Google file or folder id or URL in the local catalog"
|
|
3311
|
+
description: "Google file or folder id or URL in the local catalog, or a document:<n> ref"
|
|
3304
3312
|
},
|
|
3305
3313
|
{
|
|
3306
3314
|
name: "note",
|
|
@@ -3547,10 +3555,21 @@ var changedCopy = /* @__PURE__ */ __name(({ changed, local_modified_at }) => {
|
|
|
3547
3555
|
|
|
3548
3556
|
// dist/commands/documents.js
|
|
3549
3557
|
var DOCUMENT_REF = /^document:[1-9]\d*$/;
|
|
3558
|
+
var isDocumentRef = /* @__PURE__ */ __name((input) => DOCUMENT_REF.test(input), "isDocumentRef");
|
|
3559
|
+
var refuseBareNumber = /* @__PURE__ */ __name((input, documents) => {
|
|
3560
|
+
if (!/^\d+$/.test(input))
|
|
3561
|
+
return;
|
|
3562
|
+
const ref = `document:${input}`;
|
|
3563
|
+
if (Object.values(documents).some((doc) => doc.reference === ref))
|
|
3564
|
+
throw new CliError("validation_error", `${input} is a bare number; name the document as ${ref}`, {
|
|
3565
|
+
reason: "ref.bare-number"
|
|
3566
|
+
});
|
|
3567
|
+
}, "refuseBareNumber");
|
|
3550
3568
|
var storedDocument = /* @__PURE__ */ __name(({ env, selected }) => (input) => {
|
|
3551
3569
|
const profile = activeProfile(env, selected());
|
|
3552
3570
|
const documents = readState(env, selected(), profile.principal).documents;
|
|
3553
|
-
|
|
3571
|
+
refuseBareNumber(input, documents);
|
|
3572
|
+
const id = isDocumentRef(input) ? Object.entries(documents).find(([, doc2]) => doc2.reference === input)?.[0] ?? "" : fileId(input);
|
|
3554
3573
|
const doc = documents[id];
|
|
3555
3574
|
if (!doc)
|
|
3556
3575
|
throw new CliError("not_found", "this source is not imported in the selected profile", {
|
|
@@ -3759,8 +3778,8 @@ var memorySearch = /* @__PURE__ */ __name((words) => {
|
|
|
3759
3778
|
|
|
3760
3779
|
// dist/commands/knowledge.js
|
|
3761
3780
|
var installKnowledgeCommandsDefinition = /* @__PURE__ */ __name((program, helpers) => {
|
|
3762
|
-
const { run: run3, output, positive: positive2 } = helpers;
|
|
3763
|
-
const documentArgument = "Google file or folder id or URL in the local catalog";
|
|
3781
|
+
const { run: run3, output, positive: positive2, author, decider } = helpers;
|
|
3782
|
+
const documentArgument = "Google file or folder id or URL in the local catalog, or a document:<n> ref";
|
|
3764
3783
|
const scopes = ["personal", "work"];
|
|
3765
3784
|
const documents = program.commands.find((command) => command.name() === "documents");
|
|
3766
3785
|
examples(annotate(documents.command("context"), { effects: LOCAL_READ }).argument("<document>", documentArgument).description("show a document with its tags, relationships, notes, memories and editors"), ["drive personal documents context DOC_ID"]).action(async (doc) => output(itemOf(await run3(doc, (k, p, ref) => k.context(p, ref)))));
|
|
@@ -3783,8 +3802,8 @@ var installKnowledgeCommandsDefinition = /* @__PURE__ */ __name((program, helper
|
|
|
3783
3802
|
examples(annotate(relationships.command("add"), { effects: LOCAL_WRITE }).description("connect a document to another reference"), [
|
|
3784
3803
|
"drive personal relationships add DOC_ID project:PROJECT_ID --kind about",
|
|
3785
3804
|
"drive personal relationships add DOC_ID person:PERSON_UID --kind assigned-to --role reviewer"
|
|
3786
|
-
]).argument("<document>", documentArgument).argument("<reference>", "what it connects to, such as person:<uid>, project:<id> or note:<id>").addOption(new Option("--kind <kind>", "how the two relate").choices(["links-to", "about", "evidence", "created-from", "related-to", "assigned-to"]).default("related-to")).option("--role <role>", "the part the reference plays, in a word or two").option("--reason <text>", "why the two are connected").action(async (doc, to, { reason, ...args }) => output(itemOf(await run3(doc, (k, p, ref) => k.addLink(p, ref, { to, ...args, ...reason ? { evidence: reason } : {} })))));
|
|
3787
|
-
examples(annotate(relationships.command("remove"), { effects: LOCAL_WRITE }).description("remove one of a document's relationships"), ["drive personal relationships remove DOC_ID LINK_ID"]).argument("<document>", documentArgument).argument("<relationship-id>", "id, as relationships list prints it").action(async (doc, id) => output(itemOf(await run3(doc, (k, p, ref) => k.removeLink(p, ref, id)))));
|
|
3805
|
+
]).argument("<document>", documentArgument).argument("<reference>", "what it connects to, such as person:<uid>, project:<id> or note:<id>").addOption(new Option("--kind <kind>", "how the two relate").choices(["links-to", "about", "evidence", "created-from", "related-to", "assigned-to"]).default("related-to")).option("--role <role>", "the part the reference plays, in a word or two").option("--reason <text>", "why the two are connected").action(async (doc, to, { reason, ...args }) => output(itemOf(await run3(doc, (k, p, ref) => k.addLink(p, ref, { to, ...args, by: decider(), ...reason ? { evidence: reason } : {} })))));
|
|
3806
|
+
examples(annotate(relationships.command("remove"), { effects: LOCAL_WRITE }).description("remove one of a document's relationships"), ["drive personal relationships remove DOC_ID LINK_ID"]).argument("<document>", documentArgument).argument("<relationship-id>", "id, as relationships list prints it").action(async (doc, id) => output(itemOf(await run3(doc, (k, p, ref) => k.removeLink(p, ref, id, decider())))));
|
|
3788
3807
|
const notes = annotate(program.command("notes"), { effects: LOCAL_READ }).description("write notes about an imported document");
|
|
3789
3808
|
const noteArgument = "note:<id> reference, as notes list prints it";
|
|
3790
3809
|
examples(annotate(notes.command("add"), {
|
|
@@ -3818,7 +3837,7 @@ var installKnowledgeCommandsDefinition = /* @__PURE__ */ __name((program, helper
|
|
|
3818
3837
|
const memories = annotate(program.command("memories"), { effects: LOCAL_READ }).description("keep what was learned from a document, with evidence; an agent's stay proposed");
|
|
3819
3838
|
const memoryArgument = "memory:<id> reference, as memories list prints it";
|
|
3820
3839
|
const scope = /* @__PURE__ */ __name((description) => new Option("--scope <scope>", description).choices(scopes), "scope");
|
|
3821
|
-
examples(annotate(memories.command("add"), { effects: LOCAL_WRITE }).description("record a memory about a document"), [`drive personal memories add DOC_ID "The team prefers async reviews" --scope work --kind preference`]).argument("<document>", documentArgument).argument("<text>", "what to remember").addOption(scope("whose memory it is: personal or work").makeOptionMandatory()).addOption(new Option("--kind <kind>", "what kind of memory it is").choices(MEMORY_KINDS).default("summary")).option("--supersedes <ref>", "a memory:<id> about the same document that this one replaces").action(async (doc, body, args) => output(itemOf(memoryItem(await run3(doc, (k, p, ref) => k.addMemory(p, ref, { body, ...args, status: "proposed" }))))));
|
|
3840
|
+
examples(annotate(memories.command("add"), { effects: LOCAL_WRITE }).description("record a memory about a document"), [`drive personal memories add DOC_ID "The team prefers async reviews" --scope work --kind preference`]).argument("<document>", documentArgument).argument("<text>", "what to remember").addOption(scope("whose memory it is: personal or work").makeOptionMandatory()).addOption(new Option("--kind <kind>", "what kind of memory it is").choices(MEMORY_KINDS).default("summary")).option("--supersedes <ref>", "a memory:<id> about the same document that this one replaces").action(async (doc, body, args) => output(itemOf(memoryItem(await run3(doc, (k, p, ref) => k.addMemory(p, ref, { body, ...args, status: "proposed", author: author() }))))));
|
|
3822
3841
|
withQuery(examples(annotate(memories.command("list"), { effects: LOCAL_READ }).description("list a document's memories"), [
|
|
3823
3842
|
"drive personal memories list DOC_ID scope:work",
|
|
3824
3843
|
"drive personal memories list DOC_ID kind:preference status:confirmed"
|
|
@@ -3837,7 +3856,7 @@ var installKnowledgeCommandsDefinition = /* @__PURE__ */ __name((program, helper
|
|
|
3837
3856
|
stale: "mark a memory as out of date"
|
|
3838
3857
|
};
|
|
3839
3858
|
for (const [action, description] of Object.entries(memoryActions))
|
|
3840
|
-
examples(annotate(memories.command(action), { effects: action === "show" ? LOCAL_READ : LOCAL_WRITE }).description(description), [`drive personal memories ${action} DOC_ID memory:MEMORY_ID`]).argument("<document>", documentArgument).argument("<memory>", memoryArgument).action(async (doc, memoryRef) => output(itemOf(memoryItem(await run3(doc, (k, p, ref) => k.memory(p, ref, memoryRef, action))))));
|
|
3859
|
+
examples(annotate(memories.command(action), { effects: action === "show" ? LOCAL_READ : LOCAL_WRITE }).description(description), [`drive personal memories ${action} DOC_ID memory:MEMORY_ID`]).argument("<document>", documentArgument).argument("<memory>", memoryArgument).action(async (doc, memoryRef) => output(itemOf(memoryItem(await run3(doc, (k, p, ref) => action === "show" ? k.memory(p, ref, memoryRef) : k.memory(p, ref, memoryRef, action, decider()))))));
|
|
3841
3860
|
const search = examples(annotate(memories.command("search"), { effects: LOCAL_READ }).description("search a document's memories by words"), [
|
|
3842
3861
|
"drive personal memories search DOC_ID reviews scope:work",
|
|
3843
3862
|
`drive personal memories search DOC_ID "async reviews"`
|
|
@@ -3874,6 +3893,7 @@ var installKnowledgeCommandsDefinition = /* @__PURE__ */ __name((program, helper
|
|
|
3874
3893
|
]).argument("<document>", documentArgument).argument("<statement>", "the fact, in one sentence").addOption(new Option("--type <type>", "what kind of fact it is").choices(FACT_TYPES).default("fact")).addOption(scope("whose fact it is: personal or work")).option("--supersedes <ref>", "a decision only: the decision this one replaces").option("--occurred-time <time>", "when it happened, as the evidence shows, ISO 8601; a time without a zone is read in this computer's zone, a date alone as its midnight").action(async (doc, statement, { occurredTime, ...args }) => output(itemOf(factItem(await run3(doc, (k, p, ref) => k.addFact(p, ref, {
|
|
3875
3894
|
statement,
|
|
3876
3895
|
...args,
|
|
3896
|
+
by: author(),
|
|
3877
3897
|
...occurredTime === void 0 ? {} : { occurredAt: occurredTime }
|
|
3878
3898
|
}))))));
|
|
3879
3899
|
withQuery(examples(annotate(facts.command("list"), { effects: LOCAL_READ }).description("list a document's facts"), [
|
|
@@ -3893,7 +3913,7 @@ var installKnowledgeCommandsDefinition = /* @__PURE__ */ __name((program, helper
|
|
|
3893
3913
|
reverse: "an accepted decision no longer holds, and nothing replaced it"
|
|
3894
3914
|
};
|
|
3895
3915
|
for (const [action, description] of Object.entries(factActions))
|
|
3896
|
-
examples(annotate(facts.command(action), { effects: action === "show" ? LOCAL_READ : LOCAL_WRITE }).description(description), [`drive personal facts ${action} DOC_ID fact:FACT_ID`]).argument("<document>", documentArgument).argument("<fact>", factArgument).action(async (doc, factRef) => output(itemOf(factItem(await run3(doc, (k, p, ref) => k.fact(p, ref, factRef, action))))));
|
|
3916
|
+
examples(annotate(facts.command(action), { effects: action === "show" ? LOCAL_READ : LOCAL_WRITE }).description(description), [`drive personal facts ${action} DOC_ID fact:FACT_ID`]).argument("<document>", documentArgument).argument("<fact>", factArgument).action(async (doc, factRef) => output(itemOf(factItem(await run3(doc, (k, p, ref) => action === "show" ? k.fact(p, ref, factRef) : k.fact(p, ref, factRef, action, decider()))))));
|
|
3897
3917
|
const identities = annotate(program.command("identities"), { effects: LOCAL_READ }).description("the Google accounts seen on a document, and the people they belong to");
|
|
3898
3918
|
bindQuery(examples(annotate(identities.command("list"), { effects: LOCAL_READ }).description("list the owners and last editor Google shows for a document"), ["drive personal identities list DOC_ID"]).argument("<document>", documentArgument), IDENTITIES_QUERY, identityRow).action(async (doc, words) => {
|
|
3899
3919
|
const filter = termsOf(words, IDENTITIES_QUERY, "identities list");
|
|
@@ -22527,7 +22547,7 @@ var installSessionCommands = /* @__PURE__ */ __name((program, context) => {
|
|
|
22527
22547
|
json: json === true || jsonl === true || !process.stdout.isTTY,
|
|
22528
22548
|
answers: false
|
|
22529
22549
|
});
|
|
22530
|
-
const { login } = await import("./login-
|
|
22550
|
+
const { login } = await import("./login-4VQEC7VI.js");
|
|
22531
22551
|
output(itemOf(await login({
|
|
22532
22552
|
env,
|
|
22533
22553
|
profile: selected(),
|
|
@@ -22557,7 +22577,7 @@ var installSessionCommands = /* @__PURE__ */ __name((program, context) => {
|
|
|
22557
22577
|
const name = selected();
|
|
22558
22578
|
const config = readConfig(env);
|
|
22559
22579
|
const profile = activeProfile(env, name);
|
|
22560
|
-
const { credentials } = await import("./tokens-
|
|
22580
|
+
const { credentials } = await import("./tokens-TXYURU4S.js");
|
|
22561
22581
|
const store = credentials(env, profile.storage, options.keyring);
|
|
22562
22582
|
store.remove(name);
|
|
22563
22583
|
writeConfig(env, config);
|
|
@@ -22604,7 +22624,7 @@ var selection = /* @__PURE__ */ __name((env, name, source) => {
|
|
|
22604
22624
|
return { profile, state, options: { source, destination, collection: `google-drive:${profile.principal}`, env } };
|
|
22605
22625
|
}, "selection");
|
|
22606
22626
|
var checkStoreImport = /* @__PURE__ */ __name(async (env, name, source, bindings) => {
|
|
22607
|
-
const { ensureSqlite } = await import("./sqlite-runtime-
|
|
22627
|
+
const { ensureSqlite } = await import("./sqlite-runtime-CSO6K6B2.js");
|
|
22608
22628
|
await ensureSqlite();
|
|
22609
22629
|
const { state, options } = selection(env, name, source);
|
|
22610
22630
|
const preview = await previewDocumentTransfer({ ...options, bindings });
|
|
@@ -22778,7 +22798,7 @@ var installSyncCommands = /* @__PURE__ */ __name((program, context) => {
|
|
|
22778
22798
|
// dist/commands/upgrade.js
|
|
22779
22799
|
import { join as join7 } from "node:path";
|
|
22780
22800
|
|
|
22781
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
22801
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.561.0_@wirecat+cli-base@0.75.2_commander@15.0.0_esbuild@0.28.2_type_ef328e5cd047e3c19bb2231542618c08/node_modules/@wirecat/cli-core/dist/update/index.js
|
|
22782
22802
|
import { realpathSync } from "node:fs";
|
|
22783
22803
|
import { fileURLToPath } from "node:url";
|
|
22784
22804
|
var QUIET_WORDS = [
|
|
@@ -22953,6 +22973,19 @@ var providerJsonFields = entityFields({
|
|
|
22953
22973
|
"document.drive_catalog": CATALOG_FIELDS,
|
|
22954
22974
|
drive_document: DOCUMENT_LIST_FIELDS
|
|
22955
22975
|
});
|
|
22976
|
+
var DRIVE_ROWS = {
|
|
22977
|
+
drive_document: {
|
|
22978
|
+
columns: [
|
|
22979
|
+
{ field: "reference" },
|
|
22980
|
+
{ field: "name" },
|
|
22981
|
+
{ field: "modified_at", as: "time" },
|
|
22982
|
+
{ field: "age_days", as: "count", tag: "days since sync" }
|
|
22983
|
+
]
|
|
22984
|
+
},
|
|
22985
|
+
"document.drive_catalog": {
|
|
22986
|
+
columns: [{ field: "ref" }, { field: "name" }, { field: "kind" }, { field: "modified_at", as: "time" }]
|
|
22987
|
+
}
|
|
22988
|
+
};
|
|
22956
22989
|
var checkProviderJson = /* @__PURE__ */ __name((command, request, terminal) => {
|
|
22957
22990
|
checkJson(command, request, terminal, providerJsonFields);
|
|
22958
22991
|
if (request.fields && writes(metaOf(command).effects) && !answerFields(command, providerJsonFields))
|
|
@@ -23174,17 +23207,25 @@ var prepareStore = /* @__PURE__ */ __name(async (index, env, name, rescan = fals
|
|
|
23174
23207
|
}, "prepareStore");
|
|
23175
23208
|
|
|
23176
23209
|
// dist/store.js
|
|
23210
|
+
var DRIVE_PROVIDER = {
|
|
23211
|
+
name: "google-drive",
|
|
23212
|
+
kind: "documents",
|
|
23213
|
+
aliases: [],
|
|
23214
|
+
command: "drive",
|
|
23215
|
+
opens: { document: "documents show" }
|
|
23216
|
+
};
|
|
23177
23217
|
var openIndex = /* @__PURE__ */ __name(async (env, name, rescan = false) => {
|
|
23178
23218
|
if (name)
|
|
23179
23219
|
activeProfile(env, name);
|
|
23180
|
-
const { ensureSqlite } = await import("./sqlite-runtime-
|
|
23220
|
+
const { ensureSqlite } = await import("./sqlite-runtime-CSO6K6B2.js");
|
|
23181
23221
|
await ensureSqlite();
|
|
23182
|
-
const { openStore: openStore2, storePath: storePath2 } = await import("./store-
|
|
23222
|
+
const { openStore: openStore2, storePath: storePath2 } = await import("./store-HDWMJ44E.js");
|
|
23183
23223
|
if (env.DRIVE_STORE)
|
|
23184
23224
|
throw new CliError("configuration_error", "DRIVE_STORE has been retired; use MESSAGING_STORE to select the shared database", { reason: "store.override-retired" });
|
|
23185
23225
|
const store = await openStore2({ path: storePath2(env), env, command: "drive", version: VERSION });
|
|
23186
23226
|
const index = indexOver(store, env);
|
|
23187
23227
|
try {
|
|
23228
|
+
await store.accounts.registerProvider(DRIVE_PROVIDER);
|
|
23188
23229
|
if (name)
|
|
23189
23230
|
await prepareStore(index, env, name, rescan);
|
|
23190
23231
|
return index;
|
|
@@ -23223,7 +23264,7 @@ var indexOver = /* @__PURE__ */ __name((store, env, pictureEmbedder) => {
|
|
|
23223
23264
|
linkMessages: /* @__PURE__ */ __name((documents, since) => store.notes.linkMessages({ documents, ...since ? { since } : {} }), "linkMessages"),
|
|
23224
23265
|
knowledge: documentKnowledge2(store, async (principal) => (await folder(principal, false))?.id),
|
|
23225
23266
|
openPictures: /* @__PURE__ */ __name(async () => {
|
|
23226
|
-
const { openPictureEmbedderFor, savePicture } = await import("./services-
|
|
23267
|
+
const { openPictureEmbedderFor, savePicture } = await import("./services-WU22S2MU.js");
|
|
23227
23268
|
const embedder = pictureEmbedder ?? await openPictureEmbedderFor({ env, command: "drive" });
|
|
23228
23269
|
return {
|
|
23229
23270
|
save: /* @__PURE__ */ __name((reference, bytes) => savePicture(store, { ref: reference }, bytes, { embedder }), "save"),
|
|
@@ -23242,7 +23283,7 @@ var indexOver = /* @__PURE__ */ __name((store, env, pictureEmbedder) => {
|
|
|
23242
23283
|
has_more: false,
|
|
23243
23284
|
meaning_skipped: "this Google account has no imported sources"
|
|
23244
23285
|
};
|
|
23245
|
-
const { searchNotes } = await import("./services-
|
|
23286
|
+
const { searchNotes } = await import("./services-WU22S2MU.js");
|
|
23246
23287
|
const result = await searchNotes(store, query, {
|
|
23247
23288
|
...options,
|
|
23248
23289
|
folderIds: selected ? [selected.id] : [],
|
|
@@ -23273,7 +23314,7 @@ var indexOver = /* @__PURE__ */ __name((store, env, pictureEmbedder) => {
|
|
|
23273
23314
|
};
|
|
23274
23315
|
}, "search"),
|
|
23275
23316
|
embed: /* @__PURE__ */ __name(async (max) => {
|
|
23276
|
-
const { embedNotes } = await import("./services-
|
|
23317
|
+
const { embedNotes } = await import("./services-WU22S2MU.js");
|
|
23277
23318
|
return embedNotes(store, { maxChunks: max, env, command: "drive" });
|
|
23278
23319
|
}, "embed"),
|
|
23279
23320
|
close: /* @__PURE__ */ __name(() => store.close(), "close")
|
|
@@ -23459,6 +23500,7 @@ var Preview = class extends Error {
|
|
|
23459
23500
|
}
|
|
23460
23501
|
};
|
|
23461
23502
|
var EXPORTS = /* @__PURE__ */ new Set(["documents export", "files download", "files export"]);
|
|
23503
|
+
var MCP_AGENT = "drive-mcp";
|
|
23462
23504
|
var googleOnly = /* @__PURE__ */ __name((effects) => effects?.local === "none" && effects.remote !== "none", "googleOnly");
|
|
23463
23505
|
var lateEnv = /* @__PURE__ */ __name((environment) => {
|
|
23464
23506
|
const current = /* @__PURE__ */ __name(() => environment().env ?? process.env, "current");
|
|
@@ -23559,7 +23601,7 @@ var installDrive = /* @__PURE__ */ __name((program) => {
|
|
|
23559
23601
|
}, "output");
|
|
23560
23602
|
const signal = /* @__PURE__ */ __name(() => environment().signal, "signal");
|
|
23561
23603
|
const signedIn = /* @__PURE__ */ __name(async (name, scope2) => {
|
|
23562
|
-
const { authorizedClient, checkAuthorization } = await import("./tokens-
|
|
23604
|
+
const { authorizedClient, checkAuthorization } = await import("./tokens-TXYURU4S.js");
|
|
23563
23605
|
const client = authorizedClient(env, name, environment().keyring, signal());
|
|
23564
23606
|
await checkAuthorization(client, scope2);
|
|
23565
23607
|
return client;
|
|
@@ -23569,7 +23611,7 @@ var installDrive = /* @__PURE__ */ __name((program) => {
|
|
|
23569
23611
|
const fake = environment().source;
|
|
23570
23612
|
if (fake)
|
|
23571
23613
|
return fake(name);
|
|
23572
|
-
const [{ googleSource }, client] = await Promise.all([import("./google-
|
|
23614
|
+
const [{ googleSource }, client] = await Promise.all([import("./google-BYNSAIQI.js"), signedIn(name)]);
|
|
23573
23615
|
return googleSource(client);
|
|
23574
23616
|
}, "source");
|
|
23575
23617
|
const withIndex = /* @__PURE__ */ __name(async (fn) => {
|
|
@@ -23646,6 +23688,8 @@ var installDrive = /* @__PURE__ */ __name((program) => {
|
|
|
23646
23688
|
output,
|
|
23647
23689
|
positive,
|
|
23648
23690
|
complete: /* @__PURE__ */ __name(() => environment().complete ?? memoryModel(env, selected(), signal()), "complete"),
|
|
23691
|
+
author: /* @__PURE__ */ __name(() => agent() ? { bot: MCP_AGENT, kind: "agent" } : "owner", "author"),
|
|
23692
|
+
decider: /* @__PURE__ */ __name(() => agent() ? { bot: MCP_AGENT, reason: "asked over drive's MCP server" } : "owner", "decider"),
|
|
23649
23693
|
run: /* @__PURE__ */ __name(async (input, fn) => withIndex(async (index) => {
|
|
23650
23694
|
const lock = await lockProfile(env, selected());
|
|
23651
23695
|
try {
|
|
@@ -23653,7 +23697,8 @@ var installDrive = /* @__PURE__ */ __name((program) => {
|
|
|
23653
23697
|
if (!index.knowledge)
|
|
23654
23698
|
throw new CliError("configuration_error", "index has no shared knowledge adapter");
|
|
23655
23699
|
const principal = activeProfile(env, selected()).principal;
|
|
23656
|
-
const
|
|
23700
|
+
const local2 = isDocumentRef(input) || /^\d+$/.test(input);
|
|
23701
|
+
const found = local2 ? void 0 : await index.catalog?.get(principal, fileId(input));
|
|
23657
23702
|
const ref = found?.ref ?? imported(input).ref;
|
|
23658
23703
|
const result = await fn(index.knowledge, principal, ref);
|
|
23659
23704
|
lock.assertHeld();
|
|
@@ -23708,7 +23753,7 @@ var installDrive = /* @__PURE__ */ __name((program) => {
|
|
|
23708
23753
|
if (fake)
|
|
23709
23754
|
return await fake.call(method, params, body);
|
|
23710
23755
|
const [{ googleApi }, client] = await Promise.all([
|
|
23711
|
-
import("./google-api-
|
|
23756
|
+
import("./google-api-4VTZH7OP.js"),
|
|
23712
23757
|
signedIn(selected(), descriptor.scope)
|
|
23713
23758
|
]);
|
|
23714
23759
|
return await googleApi(client).call(method, params, body);
|
|
@@ -23734,7 +23779,7 @@ var installDrive = /* @__PURE__ */ __name((program) => {
|
|
|
23734
23779
|
if (fake)
|
|
23735
23780
|
return fake(id, mime);
|
|
23736
23781
|
const [{ googleDownload }, client] = await Promise.all([
|
|
23737
|
-
import("./google-api-
|
|
23782
|
+
import("./google-api-4VTZH7OP.js"),
|
|
23738
23783
|
signedIn(selected(), apiMethod(method).scope)
|
|
23739
23784
|
]);
|
|
23740
23785
|
return googleDownload(client)(id, mime);
|
|
@@ -23752,7 +23797,7 @@ var installDrive = /* @__PURE__ */ __name((program) => {
|
|
|
23752
23797
|
let request = environment().uploadRequest;
|
|
23753
23798
|
if (!request) {
|
|
23754
23799
|
const [{ googleUploadRequest }, client] = await Promise.all([
|
|
23755
|
-
import("./google-api-
|
|
23800
|
+
import("./google-api-4VTZH7OP.js"),
|
|
23756
23801
|
signedIn(selected(), apiMethod(method).scope)
|
|
23757
23802
|
]);
|
|
23758
23803
|
request = googleUploadRequest(client);
|
|
@@ -23953,7 +23998,7 @@ var mcpCommand = /* @__PURE__ */ __name(() => {
|
|
|
23953
23998
|
const environment = environmentOf(action);
|
|
23954
23999
|
if (environment.api)
|
|
23955
24000
|
return;
|
|
23956
|
-
const { grantAvailability } = await import("./grants-
|
|
24001
|
+
const { grantAvailability } = await import("./grants-EUQXSICG.js");
|
|
23957
24002
|
availability = grantAvailability(rootOf(root), environment.env ?? process.env, environment.keyring);
|
|
23958
24003
|
});
|
|
23959
24004
|
}, "mcpCommand");
|
|
@@ -23961,6 +24006,7 @@ var definition = /* @__PURE__ */ __name(() => ({
|
|
|
23961
24006
|
app: DRIVE_APP,
|
|
23962
24007
|
configuration,
|
|
23963
24008
|
firstScreen: FIRST_SCREEN,
|
|
24009
|
+
rows: DRIVE_ROWS,
|
|
23964
24010
|
commands: /* @__PURE__ */ __name(() => [
|
|
23965
24011
|
appDoctorCommand(DRIVE_APP, configuration, { oauthClient, packageName: PACKAGE }),
|
|
23966
24012
|
skillCommand(DRIVE_APP, SKILL),
|