@dropthis/cli 0.15.0 → 0.16.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/README.md +4 -5
- package/dist/cli.cjs +30 -6
- package/dist/cli.cjs.map +1 -1
- package/node_modules/@dropthis/node/README.md +3 -5
- package/node_modules/@dropthis/node/dist/{drops-C59ZhFES.d.cts → drops-BtAGkA9A.d.cts} +12 -0
- package/node_modules/@dropthis/node/dist/{drops-C59ZhFES.d.ts → drops-BtAGkA9A.d.ts} +12 -0
- package/node_modules/@dropthis/node/dist/edge.cjs +1 -1
- package/node_modules/@dropthis/node/dist/edge.cjs.map +1 -1
- package/node_modules/@dropthis/node/dist/edge.d.cts +1 -1
- package/node_modules/@dropthis/node/dist/edge.d.ts +1 -1
- package/node_modules/@dropthis/node/dist/edge.mjs +1 -1
- package/node_modules/@dropthis/node/dist/edge.mjs.map +1 -1
- package/node_modules/@dropthis/node/dist/index.cjs +1 -1
- package/node_modules/@dropthis/node/dist/index.cjs.map +1 -1
- package/node_modules/@dropthis/node/dist/index.d.cts +2 -2
- package/node_modules/@dropthis/node/dist/index.d.ts +2 -2
- package/node_modules/@dropthis/node/dist/index.mjs +1 -1
- package/node_modules/@dropthis/node/dist/index.mjs.map +1 -1
- package/node_modules/@dropthis/node/package.json +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -269,13 +269,12 @@ Reports CLI version, auth source (`env`, `flag`, `storage`, or `missing`), and c
|
|
|
269
269
|
|
|
270
270
|
## Pricing tiers
|
|
271
271
|
|
|
272
|
-
- **Free
|
|
273
|
-
- **
|
|
274
|
-
- **Pro ($19/mo)** — everything in Personal plus password protection and analytics.
|
|
272
|
+
- **Free** — drops expire after 7 days, 5 MB per drop, 500 MB active storage, dropthis badge.
|
|
273
|
+
- **Pro** — drops never expire, 100 MB per drop, 10 GB storage, no badge, 1 custom domain, password-protected drops. Pro is currently invite-only. Learn more at https://dropthis.app/pricing.
|
|
275
274
|
|
|
276
|
-
|
|
275
|
+
Connecting a custom domain (`dropthis domains connect`) requires the Pro plan (1 hostname). Domains already connected keep working regardless of plan.
|
|
277
276
|
|
|
278
|
-
`dropthis account` shows your active tier and its limits.
|
|
277
|
+
`dropthis account` shows your active tier and its limits.
|
|
279
278
|
|
|
280
279
|
## Agent skills
|
|
281
280
|
|
package/dist/cli.cjs
CHANGED
|
@@ -365,7 +365,9 @@ function formatDateTime(iso) {
|
|
|
365
365
|
function formatBytes(bytes) {
|
|
366
366
|
if (bytes < 1024) return `${bytes} B`;
|
|
367
367
|
if (bytes < 1024 * 1024) return `${(bytes / 1024).toFixed(1)} KB`;
|
|
368
|
-
|
|
368
|
+
if (bytes < 1024 * 1024 * 1024)
|
|
369
|
+
return `${(bytes / (1024 * 1024)).toFixed(1)} MB`;
|
|
370
|
+
return `${(bytes / (1024 * 1024 * 1024)).toFixed(1)} GB`;
|
|
369
371
|
}
|
|
370
372
|
function writeJson(deps, envelope) {
|
|
371
373
|
deps.stdout(`${JSON.stringify(envelope)}
|
|
@@ -481,7 +483,29 @@ async function runAccountGet(_input, deps) {
|
|
|
481
483
|
if (data?.status) pairs.push(["Status", String(data.status)]);
|
|
482
484
|
if (data?.createdAt)
|
|
483
485
|
pairs.push(["Created", String(data.createdAt).split("T")[0]]);
|
|
486
|
+
const usage = data?.usage;
|
|
487
|
+
const limits = data?.limits;
|
|
488
|
+
if (typeof usage?.storageUsedBytes === "number") {
|
|
489
|
+
if (typeof limits?.maxStorageBytes === "number") {
|
|
490
|
+
pairs.push([
|
|
491
|
+
"Storage",
|
|
492
|
+
`${formatBytes(usage.storageUsedBytes)} of ${formatBytes(limits.maxStorageBytes)}`
|
|
493
|
+
]);
|
|
494
|
+
} else {
|
|
495
|
+
pairs.push(["Storage", formatBytes(usage.storageUsedBytes)]);
|
|
496
|
+
}
|
|
497
|
+
}
|
|
498
|
+
if (typeof usage?.customDomainsUsed === "number" && typeof limits?.maxCustomHostnames === "number") {
|
|
499
|
+
pairs.push([
|
|
500
|
+
"Domains",
|
|
501
|
+
`${usage.customDomainsUsed} of ${limits.maxCustomHostnames}`
|
|
502
|
+
]);
|
|
503
|
+
}
|
|
484
504
|
writeKv(deps, pairs, { ok: true, account: result.data });
|
|
505
|
+
if (typeof data?.upgradeUrl === "string") {
|
|
506
|
+
deps.stderr(`${hint(`Upgrade: ${data.upgradeUrl}`)}
|
|
507
|
+
`);
|
|
508
|
+
}
|
|
485
509
|
return { exitCode: 0 };
|
|
486
510
|
}
|
|
487
511
|
async function runAccountUpdate(input, deps) {
|
|
@@ -880,13 +904,13 @@ async function runDoctor(_input, deps) {
|
|
|
880
904
|
const authSource = credential?.source ?? "missing";
|
|
881
905
|
const storageBackend = stored?.storage ?? "none";
|
|
882
906
|
const pairs = [
|
|
883
|
-
["Version", "0.
|
|
907
|
+
["Version", "0.16.0"],
|
|
884
908
|
["Auth", authSource],
|
|
885
909
|
["Storage", storageBackend]
|
|
886
910
|
];
|
|
887
911
|
writeKv(deps, pairs, {
|
|
888
912
|
ok: true,
|
|
889
|
-
version: "0.
|
|
913
|
+
version: "0.16.0",
|
|
890
914
|
auth: { source: authSource },
|
|
891
915
|
storage: { backend: storageBackend }
|
|
892
916
|
});
|
|
@@ -2567,7 +2591,7 @@ function buildProgram(options = {}) {
|
|
|
2567
2591
|
` ${import_picocolors6.default.cyan("dropthis login")}`,
|
|
2568
2592
|
` ${import_picocolors6.default.cyan("dropthis publish ./dist")}`
|
|
2569
2593
|
].join("\n")
|
|
2570
|
-
).version("0.
|
|
2594
|
+
).version("0.16.0").configureHelp({
|
|
2571
2595
|
subcommandTerm(cmd) {
|
|
2572
2596
|
const args = cmd.registeredArguments.map((a) => {
|
|
2573
2597
|
const name = a.name();
|
|
@@ -3112,7 +3136,7 @@ ${lines.map((l) => ` ${l}`).join("\n")}
|
|
|
3112
3136
|
);
|
|
3113
3137
|
const result = await runUpgrade(commandOptions, {
|
|
3114
3138
|
...deps,
|
|
3115
|
-
currentVersion: "0.
|
|
3139
|
+
currentVersion: "0.16.0"
|
|
3116
3140
|
});
|
|
3117
3141
|
process.exitCode = result.exitCode;
|
|
3118
3142
|
});
|
|
@@ -3355,7 +3379,7 @@ var showNotice = shouldShowNotice({
|
|
|
3355
3379
|
if (showNotice) {
|
|
3356
3380
|
const notice = noticeFromCache({
|
|
3357
3381
|
cache: updateCache,
|
|
3358
|
-
currentVersion: "0.
|
|
3382
|
+
currentVersion: "0.16.0"
|
|
3359
3383
|
});
|
|
3360
3384
|
if (notice) {
|
|
3361
3385
|
process.stderr.write(`
|