clawnify 0.20.0 → 0.20.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.
@@ -620,7 +620,7 @@ async function pollUntilReady(resourceId, options = {}) {
620
620
  }
621
621
 
622
622
  // src/version.ts
623
- var VERSION = "0.20.0";
623
+ var VERSION = "0.20.1";
624
624
 
625
625
  export {
626
626
  OAUTH_CLIENT_ID,
@@ -644,4 +644,4 @@ export {
644
644
  pollUntilReady,
645
645
  VERSION
646
646
  };
647
- //# sourceMappingURL=chunk-B3T4NFKV.js.map
647
+ //# sourceMappingURL=chunk-JBI5FFND.js.map
@@ -20,7 +20,7 @@ import {
20
20
  resolveOrgContext,
21
21
  saveAuth,
22
22
  saveProject
23
- } from "./chunk-B3T4NFKV.js";
23
+ } from "./chunk-JBI5FFND.js";
24
24
 
25
25
  // src/cli.ts
26
26
  import { Command, Option } from "commander";
@@ -494,12 +494,18 @@ async function uploadRedeploy(appId, archive, orgId, sync) {
494
494
  return { ok: true, data };
495
495
  }
496
496
  const err = await res.json().catch(() => ({}));
497
- return { ok: false, error: err.error || res.statusText };
497
+ return { ok: false, error: redeployError(err, res.statusText) };
498
498
  }
499
499
  function appendDraftFields(formData, discardDraft) {
500
500
  formData.append("accepts_draft", "true");
501
501
  if (discardDraft) formData.append("discard_draft", "true");
502
502
  }
503
+ function redeployError(err, fallback) {
504
+ if (err.code === "draft_pending") {
505
+ return "This app has unpublished changes from the chat, and this deploy would overwrite them. Review and publish them in the dashboard first, or deploy again with --discard-draft to replace them.";
506
+ }
507
+ return err.error || fallback;
508
+ }
503
509
  async function repoDeploy(opts) {
504
510
  const res = await api.post(
505
511
  "/v1/apps/deploy",
@@ -540,7 +546,7 @@ async function repoRedeploy(appId, opts, orgId) {
540
546
  return { ok: true, data };
541
547
  }
542
548
  const err = await res.json().catch(() => ({}));
543
- return { ok: false, error: err.error || res.statusText };
549
+ return { ok: false, error: redeployError(err, res.statusText) };
544
550
  }
545
551
  function assertNodeVersion() {
546
552
  const [major] = process.versions.node.split(".").map(Number);
@@ -1785,7 +1791,7 @@ function agentByName(name) {
1785
1791
  var ALL_AGENTS = DETECTORS.map((d) => d.agent);
1786
1792
 
1787
1793
  // src/lib/skills/content.gen.ts
1788
- var CLI_VERSION = "0.20.0";
1794
+ var CLI_VERSION = "0.20.1";
1789
1795
  var BUNDLED_SKILLS = [
1790
1796
  {
1791
1797
  name: "build-a-clawnify-app",
@@ -4492,4 +4498,4 @@ async function runCli() {
4492
4498
  export {
4493
4499
  runCli
4494
4500
  };
4495
- //# sourceMappingURL=cli-UBOVQQM4.js.map
4501
+ //# sourceMappingURL=cli-7WSI6PRM.js.map