@curviate/cli 0.30.0 → 0.31.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/CHANGELOG.md +153 -0
- package/README.md +65 -12
- package/dist/{account-5KGM6EPR.js → account-DZRX4YOK.js} +28 -12
- package/dist/{chunk-GHT2DLZR.js → chunk-A73TUZBK.js} +4 -4
- package/dist/{chunk-LCIUD7S2.js → chunk-JRKM4OV2.js} +1 -1
- package/dist/{chunk-5KANHEBN.js → chunk-KQXYEQAD.js} +0 -56
- package/dist/{chunk-63X3VI3T.js → chunk-LKF5MZIP.js} +1 -1
- package/dist/chunk-PKSKQ3LN.js +68 -0
- package/dist/{chunk-AHYUM2XQ.js → chunk-SKJNLN37.js} +12 -2
- package/dist/chunk-TD2ZIXFR.js +67 -0
- package/dist/{chunk-KTY7R27U.js → chunk-TQJ77SL4.js} +3 -1
- package/dist/chunk-X3YWBMBC.js +151 -0
- package/dist/{chunk-TAOXJNQN.js → chunk-Y3H55OSY.js} +14 -12
- package/dist/cli.js +36 -22
- package/dist/{comment-BLG4WHST.js → comment-6JI4Q6QY.js} +17 -14
- package/dist/{company-ZT65QZ6F.js → company-RLU5SHUO.js} +25 -22
- package/dist/{config-5HB2J3RY.js → config-FUHT23SX.js} +2 -2
- package/dist/{connect-57AUN33D.js → connect-63NUITEZ.js} +22 -19
- package/dist/doctor-KSLZNAKH.js +198 -0
- package/dist/{exit-codes-U5CHA6FT.js → exit-codes-RUKZC4WV.js} +1 -1
- package/dist/{feed-3AWI2URQ.js → feed-PAWXR56T.js} +12 -9
- package/dist/{group-DYC2NX5M.js → group-ZIIWI7JV.js} +12 -9
- package/dist/{inbox-ZRFIFOEP.js → inbox-GIPLWRHQ.js} +14 -11
- package/dist/{inboxes-XQ2B6X3Q.js → inboxes-ECGEMDH7.js} +12 -9
- package/dist/{job-NUT4QMH2.js → job-WPWIAVQY.js} +14 -11
- package/dist/{login-KNNEN4HP.js → login-3OAUY7TG.js} +3 -3
- package/dist/{message-KMNRUD4H.js → message-JQL2XABC.js} +9 -7
- package/dist/{notification-LEM57IBY.js → notification-URSGC7OR.js} +14 -11
- package/dist/{post-FXAANNUB.js → post-2HI6KL73.js} +17 -14
- package/dist/{profile-72V55PZM.js → profile-4BXLUYMH.js} +25 -22
- package/dist/{recruiter-JUNB5AUR.js → recruiter-OUXQ5XYU.js} +24 -18
- package/dist/{sales-nav-BALVVD35.js → sales-nav-MJAMCSBO.js} +22 -16
- package/dist/{search-QCXTK33P.js → search-M3R35BIB.js} +21 -18
- package/dist/setup-YV5PVIU5.js +419 -0
- package/dist/{webhook-D4QRWF7W.js → webhook-3TEYA3B2.js} +10 -7
- package/package.json +2 -2
- package/dist/chunk-2OG6M6ME.js +0 -89
- package/dist/{chunk-H4KV7MIN.js → chunk-YLSJ4HKU.js} +1 -1
|
@@ -0,0 +1,198 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
createClient,
|
|
4
|
+
resolveEffectiveConfig
|
|
5
|
+
} from "./chunk-TD2ZIXFR.js";
|
|
6
|
+
import "./chunk-PKSKQ3LN.js";
|
|
7
|
+
import {
|
|
8
|
+
getExitCode
|
|
9
|
+
} from "./chunk-X3YWBMBC.js";
|
|
10
|
+
import {
|
|
11
|
+
getConfigPath,
|
|
12
|
+
readConfig
|
|
13
|
+
} from "./chunk-TQJ77SL4.js";
|
|
14
|
+
import {
|
|
15
|
+
GLOBAL_FLAGS
|
|
16
|
+
} from "./chunk-SKJNLN37.js";
|
|
17
|
+
|
|
18
|
+
// src/commands/doctor.ts
|
|
19
|
+
import { defineCommand } from "citty";
|
|
20
|
+
import { existsSync } from "fs";
|
|
21
|
+
import { createRequire } from "module";
|
|
22
|
+
import { dirname, join } from "path";
|
|
23
|
+
import { fileURLToPath } from "url";
|
|
24
|
+
function defaultVersion() {
|
|
25
|
+
const require2 = createRequire(import.meta.url);
|
|
26
|
+
let dir = dirname(fileURLToPath(import.meta.url));
|
|
27
|
+
for (; ; ) {
|
|
28
|
+
const candidate = join(dir, "package.json");
|
|
29
|
+
if (existsSync(candidate)) return require2(candidate).version;
|
|
30
|
+
const parent = dirname(dir);
|
|
31
|
+
if (parent === dir) throw new Error("could not locate the package manifest");
|
|
32
|
+
dir = parent;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
async function defaultListAccounts(apiKey, baseUrl, timeout) {
|
|
36
|
+
return createClient({ apiKey, baseUrl, timeout }).accounts.list();
|
|
37
|
+
}
|
|
38
|
+
function resolveDoctorIO(io = {}) {
|
|
39
|
+
return {
|
|
40
|
+
stdout: io.stdout ?? { write: (s) => void process.stdout.write(s) },
|
|
41
|
+
stderr: io.stderr ?? { write: (s) => void process.stderr.write(s) },
|
|
42
|
+
isOutputTTY: io.isOutputTTY ?? (process.stdout.isTTY ?? false),
|
|
43
|
+
listAccounts: io.listAccounts ?? defaultListAccounts,
|
|
44
|
+
version: io.version ?? defaultVersion
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
function accountLines(payload) {
|
|
48
|
+
if (typeof payload !== "object" || payload === null) return [];
|
|
49
|
+
const items = payload["items"];
|
|
50
|
+
if (!Array.isArray(items)) return [];
|
|
51
|
+
return items.map((raw) => {
|
|
52
|
+
const item = typeof raw === "object" && raw !== null ? raw : {};
|
|
53
|
+
return {
|
|
54
|
+
account_id: typeof item["id"] === "string" ? item["id"] : String(item["account_id"] ?? ""),
|
|
55
|
+
status: typeof item["status"] === "string" ? item["status"] : "unknown"
|
|
56
|
+
};
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
async function runDoctor(args, io) {
|
|
60
|
+
const cfg = await readConfig();
|
|
61
|
+
const effective = await resolveEffectiveConfig({
|
|
62
|
+
apiKey: args["api-key"],
|
|
63
|
+
baseUrl: args["base-url"],
|
|
64
|
+
timeout: args.timeout,
|
|
65
|
+
profile: args.profile
|
|
66
|
+
});
|
|
67
|
+
const profileName = args.profile ?? cfg?.active ?? "default";
|
|
68
|
+
const checks = [];
|
|
69
|
+
const credentialResolved = effective.apiKey !== void 0;
|
|
70
|
+
checks.push({
|
|
71
|
+
name: "credential",
|
|
72
|
+
ok: credentialResolved,
|
|
73
|
+
detail: credentialResolved ? `resolved from ${effective.apiKeySource}` : "no credential found in a flag, the environment, or the profile. Run `curviate setup`.",
|
|
74
|
+
// 3: auth. Nothing is malformed, there is simply nothing to authenticate
|
|
75
|
+
// with, and the remedy is the same as for a rejected key.
|
|
76
|
+
exit: 3
|
|
77
|
+
});
|
|
78
|
+
let reachable = false;
|
|
79
|
+
let valid = false;
|
|
80
|
+
let accounts = [];
|
|
81
|
+
if (credentialResolved) {
|
|
82
|
+
try {
|
|
83
|
+
const payload = await io.listAccounts(
|
|
84
|
+
effective.apiKey,
|
|
85
|
+
effective.baseUrl,
|
|
86
|
+
effective.timeout
|
|
87
|
+
);
|
|
88
|
+
reachable = true;
|
|
89
|
+
valid = true;
|
|
90
|
+
accounts = accountLines(payload);
|
|
91
|
+
checks.push({ name: "api reachable", ok: true, detail: effective.baseUrl, exit: 7 });
|
|
92
|
+
checks.push({
|
|
93
|
+
name: "credential valid",
|
|
94
|
+
ok: true,
|
|
95
|
+
detail: `accepted by ${effective.baseUrl}`,
|
|
96
|
+
exit: 3
|
|
97
|
+
});
|
|
98
|
+
checks.push({
|
|
99
|
+
name: "connected accounts",
|
|
100
|
+
ok: true,
|
|
101
|
+
detail: `${accounts.length} connected`,
|
|
102
|
+
exit: 8
|
|
103
|
+
});
|
|
104
|
+
} catch (err) {
|
|
105
|
+
const error = err;
|
|
106
|
+
const code = typeof error.code === "string" ? error.code : void 0;
|
|
107
|
+
const responded = typeof error.httpStatus === "number";
|
|
108
|
+
const transportFault = !responded && error.retryLikelyToSucceed === true;
|
|
109
|
+
const codeExit = code ? getExitCode(code) : 3;
|
|
110
|
+
reachable = responded;
|
|
111
|
+
checks.push({
|
|
112
|
+
name: "api reachable",
|
|
113
|
+
ok: reachable,
|
|
114
|
+
detail: reachable ? effective.baseUrl : transportFault ? `could not reach ${effective.baseUrl}: ${error.message ?? "network error"}` : "not checked: the request was refused before it was sent",
|
|
115
|
+
exit: transportFault ? 7 : codeExit
|
|
116
|
+
});
|
|
117
|
+
checks.push({
|
|
118
|
+
name: "credential valid",
|
|
119
|
+
ok: false,
|
|
120
|
+
// Nothing asked the credential anything unless a response came back,
|
|
121
|
+
// so it was not "rejected". Saying it was is the half of this defect
|
|
122
|
+
// that actually misdirects: it names the one subsystem that is fine.
|
|
123
|
+
detail: responded ? code ? `rejected: ${code}` : error.message ?? "the call did not succeed" : transportFault ? `not checked: ${effective.baseUrl} could not be reached` : error.message ?? "the request was refused before it was sent",
|
|
124
|
+
exit: responded ? codeExit : transportFault ? 3 : codeExit
|
|
125
|
+
});
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
const tenant = effective.apiKeySource === "profile" ? cfg?.profiles[profileName]?.tenant ?? null : null;
|
|
129
|
+
const firstFailure = checks.find((c) => !c.ok);
|
|
130
|
+
const report = {
|
|
131
|
+
version: io.version(),
|
|
132
|
+
config_path: getConfigPath(),
|
|
133
|
+
profile: profileName,
|
|
134
|
+
base_url: effective.baseUrl,
|
|
135
|
+
credential_source: effective.apiKeySource,
|
|
136
|
+
credential_resolved: credentialResolved,
|
|
137
|
+
tenant,
|
|
138
|
+
api_reachable: reachable,
|
|
139
|
+
credential_valid: valid,
|
|
140
|
+
accounts,
|
|
141
|
+
checks: checks.map(({ name, ok, detail }) => ({ name, ok, detail })),
|
|
142
|
+
ok: firstFailure === void 0,
|
|
143
|
+
exit: firstFailure?.exit ?? 0
|
|
144
|
+
};
|
|
145
|
+
return report;
|
|
146
|
+
}
|
|
147
|
+
function renderHuman(report, io) {
|
|
148
|
+
const lines = [
|
|
149
|
+
`version ${report.version}`,
|
|
150
|
+
`config ${report.config_path}`,
|
|
151
|
+
`profile ${report.profile}`,
|
|
152
|
+
`base url ${report.base_url}`,
|
|
153
|
+
`credential ${report.credential_resolved ? `resolved from ${report.credential_source}` : "not found"}`,
|
|
154
|
+
`workspace ${report.tenant ?? "unknown (only a key `curviate setup` wrote carries it)"}`
|
|
155
|
+
];
|
|
156
|
+
for (const check of report.checks) {
|
|
157
|
+
lines.push(`${check.ok ? "PASS" : "FAIL"} ${check.name}: ${check.detail}`);
|
|
158
|
+
}
|
|
159
|
+
for (const account of report.accounts) {
|
|
160
|
+
lines.push(`account ${account.account_id} ${account.status}`);
|
|
161
|
+
}
|
|
162
|
+
io.stdout.write(lines.join("\n") + "\n");
|
|
163
|
+
}
|
|
164
|
+
var doctorCommand = defineCommand({
|
|
165
|
+
meta: {
|
|
166
|
+
name: "doctor",
|
|
167
|
+
description: "Check that this machine can call the API: config, credential source, workspace, reachability and connected accounts."
|
|
168
|
+
},
|
|
169
|
+
args: {
|
|
170
|
+
profile: GLOBAL_FLAGS.profile,
|
|
171
|
+
"api-key": GLOBAL_FLAGS["api-key"],
|
|
172
|
+
"base-url": GLOBAL_FLAGS["base-url"],
|
|
173
|
+
timeout: GLOBAL_FLAGS.timeout,
|
|
174
|
+
json: GLOBAL_FLAGS.json
|
|
175
|
+
},
|
|
176
|
+
async run({ args }) {
|
|
177
|
+
const io = resolveDoctorIO();
|
|
178
|
+
const report = await runDoctor(
|
|
179
|
+
{
|
|
180
|
+
profile: args.profile,
|
|
181
|
+
"api-key": args["api-key"],
|
|
182
|
+
"base-url": args["base-url"],
|
|
183
|
+
timeout: args.timeout,
|
|
184
|
+
json: args.json
|
|
185
|
+
},
|
|
186
|
+
io
|
|
187
|
+
);
|
|
188
|
+
const json = args.json === true || !io.isOutputTTY;
|
|
189
|
+
if (json) io.stdout.write(JSON.stringify(report) + "\n");
|
|
190
|
+
else renderHuman(report, io);
|
|
191
|
+
if (report.exit !== 0) process.exit(report.exit);
|
|
192
|
+
}
|
|
193
|
+
});
|
|
194
|
+
export {
|
|
195
|
+
doctorCommand,
|
|
196
|
+
resolveDoctorIO,
|
|
197
|
+
runDoctor
|
|
198
|
+
};
|
|
@@ -2,22 +2,25 @@
|
|
|
2
2
|
import {
|
|
3
3
|
pageDelayFromFlags,
|
|
4
4
|
streamAll
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-LKF5MZIP.js";
|
|
6
6
|
import {
|
|
7
7
|
requireAccount
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-A73TUZBK.js";
|
|
9
9
|
import {
|
|
10
|
-
createClient,
|
|
11
10
|
renderError,
|
|
12
11
|
renderSuccess,
|
|
13
|
-
renderUnexpectedError
|
|
12
|
+
renderUnexpectedError
|
|
13
|
+
} from "./chunk-KQXYEQAD.js";
|
|
14
|
+
import {
|
|
15
|
+
createClient,
|
|
14
16
|
resolveEffectiveConfig
|
|
15
|
-
} from "./chunk-
|
|
16
|
-
import "./chunk-
|
|
17
|
+
} from "./chunk-TD2ZIXFR.js";
|
|
18
|
+
import "./chunk-PKSKQ3LN.js";
|
|
19
|
+
import "./chunk-X3YWBMBC.js";
|
|
20
|
+
import "./chunk-TQJ77SL4.js";
|
|
17
21
|
import {
|
|
18
22
|
GLOBAL_FLAGS
|
|
19
|
-
} from "./chunk-
|
|
20
|
-
import "./chunk-2OG6M6ME.js";
|
|
23
|
+
} from "./chunk-SKJNLN37.js";
|
|
21
24
|
|
|
22
25
|
// src/commands/feed.ts
|
|
23
26
|
import { defineCommand } from "citty";
|
|
@@ -44,7 +47,7 @@ function resolveOutputOpts(flags) {
|
|
|
44
47
|
async function handleSdkError(err, outOpts, out) {
|
|
45
48
|
const { CurviateError } = await import("@curviate/sdk");
|
|
46
49
|
if (err instanceof CurviateError) {
|
|
47
|
-
const { getExitCode } = await import("./exit-codes-
|
|
50
|
+
const { getExitCode } = await import("./exit-codes-RUKZC4WV.js");
|
|
48
51
|
renderError(err, outOpts, out);
|
|
49
52
|
process.exit(getExitCode(err.code));
|
|
50
53
|
}
|
|
@@ -2,26 +2,29 @@
|
|
|
2
2
|
import {
|
|
3
3
|
pageDelayFromFlags,
|
|
4
4
|
streamAll
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-LKF5MZIP.js";
|
|
6
6
|
import {
|
|
7
7
|
normalizeGroupId
|
|
8
8
|
} from "./chunk-UEAX6KUB.js";
|
|
9
9
|
import {
|
|
10
10
|
requireAccount
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-A73TUZBK.js";
|
|
12
12
|
import {
|
|
13
|
-
createClient,
|
|
14
13
|
renderError,
|
|
15
14
|
renderSuccess,
|
|
16
|
-
renderUnexpectedError
|
|
15
|
+
renderUnexpectedError
|
|
16
|
+
} from "./chunk-KQXYEQAD.js";
|
|
17
|
+
import {
|
|
18
|
+
createClient,
|
|
17
19
|
resolveEffectiveConfig
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import "./chunk-
|
|
20
|
+
} from "./chunk-TD2ZIXFR.js";
|
|
21
|
+
import "./chunk-PKSKQ3LN.js";
|
|
22
|
+
import "./chunk-X3YWBMBC.js";
|
|
23
|
+
import "./chunk-TQJ77SL4.js";
|
|
20
24
|
import {
|
|
21
25
|
GLOBAL_FLAGS,
|
|
22
26
|
READ_SINGLE_FLAGS
|
|
23
|
-
} from "./chunk-
|
|
24
|
-
import "./chunk-2OG6M6ME.js";
|
|
27
|
+
} from "./chunk-SKJNLN37.js";
|
|
25
28
|
|
|
26
29
|
// src/commands/group.ts
|
|
27
30
|
import { defineCommand } from "citty";
|
|
@@ -54,7 +57,7 @@ function resolveOutputOpts(flags) {
|
|
|
54
57
|
async function handleSdkError(err, outOpts, out) {
|
|
55
58
|
const { CurviateError } = await import("@curviate/sdk");
|
|
56
59
|
if (err instanceof CurviateError) {
|
|
57
|
-
const { getExitCode } = await import("./exit-codes-
|
|
60
|
+
const { getExitCode } = await import("./exit-codes-RUKZC4WV.js");
|
|
58
61
|
renderError(err, outOpts, out);
|
|
59
62
|
process.exit(getExitCode(err.code));
|
|
60
63
|
}
|
|
@@ -6,30 +6,33 @@ import {
|
|
|
6
6
|
import {
|
|
7
7
|
pageDelayFromFlags,
|
|
8
8
|
streamAll
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-LKF5MZIP.js";
|
|
10
10
|
import {
|
|
11
11
|
normalizeChatId
|
|
12
12
|
} from "./chunk-UEAX6KUB.js";
|
|
13
|
-
import {
|
|
14
|
-
requireAccount
|
|
15
|
-
} from "./chunk-GHT2DLZR.js";
|
|
16
13
|
import {
|
|
17
14
|
buildPreviewOutput
|
|
18
15
|
} from "./chunk-R3VLWLVV.js";
|
|
19
16
|
import {
|
|
20
|
-
|
|
17
|
+
requireAccount
|
|
18
|
+
} from "./chunk-A73TUZBK.js";
|
|
19
|
+
import {
|
|
21
20
|
renderError,
|
|
22
21
|
renderSuccess,
|
|
23
|
-
renderUnexpectedError
|
|
22
|
+
renderUnexpectedError
|
|
23
|
+
} from "./chunk-KQXYEQAD.js";
|
|
24
|
+
import {
|
|
25
|
+
createClient,
|
|
24
26
|
resolveEffectiveConfig
|
|
25
|
-
} from "./chunk-
|
|
26
|
-
import "./chunk-
|
|
27
|
+
} from "./chunk-TD2ZIXFR.js";
|
|
28
|
+
import "./chunk-PKSKQ3LN.js";
|
|
29
|
+
import "./chunk-X3YWBMBC.js";
|
|
30
|
+
import "./chunk-TQJ77SL4.js";
|
|
27
31
|
import {
|
|
28
32
|
GLOBAL_FLAGS,
|
|
29
33
|
READ_SINGLE_FLAGS,
|
|
30
34
|
WRITE_SINGLE_FLAGS
|
|
31
|
-
} from "./chunk-
|
|
32
|
-
import "./chunk-2OG6M6ME.js";
|
|
35
|
+
} from "./chunk-SKJNLN37.js";
|
|
33
36
|
|
|
34
37
|
// src/commands/inbox.ts
|
|
35
38
|
import { defineCommand } from "citty";
|
|
@@ -96,7 +99,7 @@ function validateInboxFolder(raw, out) {
|
|
|
96
99
|
async function handleSdkError(err, outOpts, out) {
|
|
97
100
|
const { CurviateError } = await import("@curviate/sdk");
|
|
98
101
|
if (err instanceof CurviateError) {
|
|
99
|
-
const { getExitCode } = await import("./exit-codes-
|
|
102
|
+
const { getExitCode } = await import("./exit-codes-RUKZC4WV.js");
|
|
100
103
|
renderError(err, outOpts, out);
|
|
101
104
|
process.exit(getExitCode(err.code));
|
|
102
105
|
}
|
|
@@ -2,23 +2,26 @@
|
|
|
2
2
|
import {
|
|
3
3
|
pageDelayFromFlags,
|
|
4
4
|
streamAll
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-LKF5MZIP.js";
|
|
6
6
|
import {
|
|
7
7
|
requireAccount
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-A73TUZBK.js";
|
|
9
9
|
import {
|
|
10
|
-
createClient,
|
|
11
10
|
renderError,
|
|
12
11
|
renderSuccess,
|
|
13
|
-
renderUnexpectedError
|
|
12
|
+
renderUnexpectedError
|
|
13
|
+
} from "./chunk-KQXYEQAD.js";
|
|
14
|
+
import {
|
|
15
|
+
createClient,
|
|
14
16
|
resolveEffectiveConfig
|
|
15
|
-
} from "./chunk-
|
|
16
|
-
import "./chunk-
|
|
17
|
+
} from "./chunk-TD2ZIXFR.js";
|
|
18
|
+
import "./chunk-PKSKQ3LN.js";
|
|
19
|
+
import "./chunk-X3YWBMBC.js";
|
|
20
|
+
import "./chunk-TQJ77SL4.js";
|
|
17
21
|
import {
|
|
18
22
|
GLOBAL_FLAGS,
|
|
19
23
|
READ_SINGLE_FLAGS
|
|
20
|
-
} from "./chunk-
|
|
21
|
-
import "./chunk-2OG6M6ME.js";
|
|
24
|
+
} from "./chunk-SKJNLN37.js";
|
|
22
25
|
|
|
23
26
|
// src/commands/inboxes.ts
|
|
24
27
|
import { defineCommand } from "citty";
|
|
@@ -51,7 +54,7 @@ function resolveOutputOpts(flags) {
|
|
|
51
54
|
async function handleSdkError(err, outOpts, out) {
|
|
52
55
|
const { CurviateError } = await import("@curviate/sdk");
|
|
53
56
|
if (err instanceof CurviateError) {
|
|
54
|
-
const { getExitCode } = await import("./exit-codes-
|
|
57
|
+
const { getExitCode } = await import("./exit-codes-RUKZC4WV.js");
|
|
55
58
|
renderError(err, outOpts, out);
|
|
56
59
|
process.exit(getExitCode(err.code));
|
|
57
60
|
}
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
ndjsonModeNotice,
|
|
8
8
|
pageDelayFromFlags,
|
|
9
9
|
streamAll
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-LKF5MZIP.js";
|
|
11
11
|
import {
|
|
12
12
|
BinaryOutputError,
|
|
13
13
|
writeBinaryOutput
|
|
@@ -15,26 +15,29 @@ import {
|
|
|
15
15
|
import {
|
|
16
16
|
resolveJobIdentifier
|
|
17
17
|
} from "./chunk-UEAX6KUB.js";
|
|
18
|
-
import {
|
|
19
|
-
requireAccount
|
|
20
|
-
} from "./chunk-GHT2DLZR.js";
|
|
21
18
|
import {
|
|
22
19
|
buildPreviewOutput
|
|
23
20
|
} from "./chunk-R3VLWLVV.js";
|
|
24
21
|
import {
|
|
25
|
-
|
|
22
|
+
requireAccount
|
|
23
|
+
} from "./chunk-A73TUZBK.js";
|
|
24
|
+
import {
|
|
26
25
|
renderError,
|
|
27
26
|
renderSuccess,
|
|
28
|
-
renderUnexpectedError
|
|
27
|
+
renderUnexpectedError
|
|
28
|
+
} from "./chunk-KQXYEQAD.js";
|
|
29
|
+
import {
|
|
30
|
+
createClient,
|
|
29
31
|
resolveEffectiveConfig
|
|
30
|
-
} from "./chunk-
|
|
31
|
-
import "./chunk-
|
|
32
|
+
} from "./chunk-TD2ZIXFR.js";
|
|
33
|
+
import "./chunk-PKSKQ3LN.js";
|
|
34
|
+
import "./chunk-X3YWBMBC.js";
|
|
35
|
+
import "./chunk-TQJ77SL4.js";
|
|
32
36
|
import {
|
|
33
37
|
GLOBAL_FLAGS,
|
|
34
38
|
READ_SINGLE_FLAGS,
|
|
35
39
|
WRITE_SINGLE_FLAGS
|
|
36
|
-
} from "./chunk-
|
|
37
|
-
import "./chunk-2OG6M6ME.js";
|
|
40
|
+
} from "./chunk-SKJNLN37.js";
|
|
38
41
|
|
|
39
42
|
// src/commands/job.ts
|
|
40
43
|
import { defineCommand } from "citty";
|
|
@@ -96,7 +99,7 @@ function requireEnum(value, allowed, flag, out) {
|
|
|
96
99
|
async function handleSdkError(err, outOpts, out) {
|
|
97
100
|
const { CurviateError } = await import("@curviate/sdk");
|
|
98
101
|
if (err instanceof CurviateError) {
|
|
99
|
-
const { getExitCode } = await import("./exit-codes-
|
|
102
|
+
const { getExitCode } = await import("./exit-codes-RUKZC4WV.js");
|
|
100
103
|
renderError(err, outOpts, out);
|
|
101
104
|
process.exit(getExitCode(err.code));
|
|
102
105
|
}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
readlineSync
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-YLSJ4HKU.js";
|
|
5
5
|
import {
|
|
6
6
|
writeProfile
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-TQJ77SL4.js";
|
|
8
8
|
import {
|
|
9
9
|
GLOBAL_FLAGS,
|
|
10
10
|
defaultReadStdin,
|
|
11
11
|
resolveTextOrStdin
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-SKJNLN37.js";
|
|
13
13
|
|
|
14
14
|
// src/commands/login.ts
|
|
15
15
|
import { defineCommand } from "citty";
|
|
@@ -13,17 +13,19 @@ import {
|
|
|
13
13
|
runMessageSend,
|
|
14
14
|
sentAsNotice,
|
|
15
15
|
willSendAsNotice
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-Y3H55OSY.js";
|
|
17
|
+
import "./chunk-UWO2D4HW.js";
|
|
17
18
|
import "./chunk-HOQ7EUHJ.js";
|
|
18
19
|
import "./chunk-BGZW6B7G.js";
|
|
19
|
-
import "./chunk-UWO2D4HW.js";
|
|
20
20
|
import "./chunk-UEAX6KUB.js";
|
|
21
|
-
import "./chunk-GHT2DLZR.js";
|
|
22
21
|
import "./chunk-R3VLWLVV.js";
|
|
23
|
-
import "./chunk-
|
|
24
|
-
import "./chunk-
|
|
25
|
-
import "./chunk-
|
|
26
|
-
import "./chunk-
|
|
22
|
+
import "./chunk-A73TUZBK.js";
|
|
23
|
+
import "./chunk-KQXYEQAD.js";
|
|
24
|
+
import "./chunk-TD2ZIXFR.js";
|
|
25
|
+
import "./chunk-PKSKQ3LN.js";
|
|
26
|
+
import "./chunk-X3YWBMBC.js";
|
|
27
|
+
import "./chunk-TQJ77SL4.js";
|
|
28
|
+
import "./chunk-SKJNLN37.js";
|
|
27
29
|
export {
|
|
28
30
|
guardBareMessageForm,
|
|
29
31
|
messageCommand,
|
|
@@ -2,26 +2,29 @@
|
|
|
2
2
|
import {
|
|
3
3
|
pageDelayFromFlags,
|
|
4
4
|
streamAll
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import {
|
|
7
|
-
requireAccount
|
|
8
|
-
} from "./chunk-GHT2DLZR.js";
|
|
5
|
+
} from "./chunk-LKF5MZIP.js";
|
|
9
6
|
import {
|
|
10
7
|
buildPreviewOutput
|
|
11
8
|
} from "./chunk-R3VLWLVV.js";
|
|
12
9
|
import {
|
|
13
|
-
|
|
10
|
+
requireAccount
|
|
11
|
+
} from "./chunk-A73TUZBK.js";
|
|
12
|
+
import {
|
|
14
13
|
renderError,
|
|
15
14
|
renderSuccess,
|
|
16
|
-
renderUnexpectedError
|
|
15
|
+
renderUnexpectedError
|
|
16
|
+
} from "./chunk-KQXYEQAD.js";
|
|
17
|
+
import {
|
|
18
|
+
createClient,
|
|
17
19
|
resolveEffectiveConfig
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import "./chunk-
|
|
20
|
+
} from "./chunk-TD2ZIXFR.js";
|
|
21
|
+
import "./chunk-PKSKQ3LN.js";
|
|
22
|
+
import "./chunk-X3YWBMBC.js";
|
|
23
|
+
import "./chunk-TQJ77SL4.js";
|
|
20
24
|
import {
|
|
21
25
|
GLOBAL_FLAGS,
|
|
22
26
|
WRITE_SINGLE_FLAGS
|
|
23
|
-
} from "./chunk-
|
|
24
|
-
import "./chunk-2OG6M6ME.js";
|
|
27
|
+
} from "./chunk-SKJNLN37.js";
|
|
25
28
|
|
|
26
29
|
// src/commands/notification.ts
|
|
27
30
|
import { defineCommand } from "citty";
|
|
@@ -48,7 +51,7 @@ function resolveOutputOpts(flags) {
|
|
|
48
51
|
async function handleSdkError(err, outOpts, out) {
|
|
49
52
|
const { CurviateError } = await import("@curviate/sdk");
|
|
50
53
|
if (err instanceof CurviateError) {
|
|
51
|
-
const { getExitCode } = await import("./exit-codes-
|
|
54
|
+
const { getExitCode } = await import("./exit-codes-RUKZC4WV.js");
|
|
52
55
|
renderError(err, outOpts, out);
|
|
53
56
|
process.exit(getExitCode(err.code));
|
|
54
57
|
}
|
|
@@ -2,37 +2,40 @@
|
|
|
2
2
|
import {
|
|
3
3
|
resolveMemberOrMeProviderId
|
|
4
4
|
} from "./chunk-6P52Q2GK.js";
|
|
5
|
+
import {
|
|
6
|
+
pageDelayFromFlags,
|
|
7
|
+
streamAll
|
|
8
|
+
} from "./chunk-LKF5MZIP.js";
|
|
5
9
|
import {
|
|
6
10
|
AttachError,
|
|
7
11
|
readAttachment,
|
|
8
12
|
toAttachmentPayload
|
|
9
13
|
} from "./chunk-BGZW6B7G.js";
|
|
10
|
-
import {
|
|
11
|
-
pageDelayFromFlags,
|
|
12
|
-
streamAll
|
|
13
|
-
} from "./chunk-63X3VI3T.js";
|
|
14
14
|
import "./chunk-UEAX6KUB.js";
|
|
15
|
-
import {
|
|
16
|
-
requireAccount
|
|
17
|
-
} from "./chunk-GHT2DLZR.js";
|
|
18
15
|
import {
|
|
19
16
|
buildPreviewOutput
|
|
20
17
|
} from "./chunk-R3VLWLVV.js";
|
|
21
18
|
import {
|
|
22
|
-
|
|
19
|
+
requireAccount
|
|
20
|
+
} from "./chunk-A73TUZBK.js";
|
|
21
|
+
import {
|
|
23
22
|
renderError,
|
|
24
23
|
renderSuccess,
|
|
25
|
-
renderUnexpectedError
|
|
24
|
+
renderUnexpectedError
|
|
25
|
+
} from "./chunk-KQXYEQAD.js";
|
|
26
|
+
import {
|
|
27
|
+
createClient,
|
|
26
28
|
resolveEffectiveConfig
|
|
27
|
-
} from "./chunk-
|
|
28
|
-
import "./chunk-
|
|
29
|
+
} from "./chunk-TD2ZIXFR.js";
|
|
30
|
+
import "./chunk-PKSKQ3LN.js";
|
|
31
|
+
import "./chunk-X3YWBMBC.js";
|
|
32
|
+
import "./chunk-TQJ77SL4.js";
|
|
29
33
|
import {
|
|
30
34
|
GLOBAL_FLAGS,
|
|
31
35
|
WRITE_FLAGS,
|
|
32
36
|
WRITE_SINGLE_FLAGS,
|
|
33
37
|
resolveTextOrStdin
|
|
34
|
-
} from "./chunk-
|
|
35
|
-
import "./chunk-2OG6M6ME.js";
|
|
38
|
+
} from "./chunk-SKJNLN37.js";
|
|
36
39
|
|
|
37
40
|
// src/commands/post.ts
|
|
38
41
|
import { defineCommand } from "citty";
|
|
@@ -75,7 +78,7 @@ function normalizeAttachPaths(attach) {
|
|
|
75
78
|
async function handleSdkError(err, outOpts, out) {
|
|
76
79
|
const { CurviateError } = await import("@curviate/sdk");
|
|
77
80
|
if (err instanceof CurviateError) {
|
|
78
|
-
const { getExitCode } = await import("./exit-codes-
|
|
81
|
+
const { getExitCode } = await import("./exit-codes-RUKZC4WV.js");
|
|
79
82
|
renderError(err, outOpts, out);
|
|
80
83
|
process.exit(getExitCode(err.code));
|
|
81
84
|
}
|