@artifactshare/cli 0.15.2 → 0.15.3
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 +4 -0
- package/README.md +2 -0
- package/dist/index.js +13 -2
- package/package.json +1 -1
- package/skills/artifactshare/SKILL.md +2 -2
- package/skills/artifactshare/artifactshare.mdc +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,10 @@ For user-facing announcements, see https://artifactshare.com/updates?product=cli
|
|
|
5
5
|
|
|
6
6
|
## Unreleased
|
|
7
7
|
|
|
8
|
+
## 0.15.3 - 2026-10-10
|
|
9
|
+
|
|
10
|
+
- `edit` now accepts `--visibility project`, including when moving into a project in the same request. Edits requesting project visibility at home are refused without changes and explain how to select a project.
|
|
11
|
+
|
|
8
12
|
## 0.15.2 - 2026-10-10
|
|
9
13
|
|
|
10
14
|
- Fix complete downloads of static sites with dotted filenames, including `.data`, and identify the file when a download fails.
|
package/README.md
CHANGED
|
@@ -183,6 +183,8 @@ npm exec --yes --package=@artifactshare/cli -- artifactshare config get home_aud
|
|
|
183
183
|
|
|
184
184
|
Use `--scope repository` only for a policy agreed by all repository participants, and pass `--visibility private|workspace|link` for a one-time home override. For link sharing, pass exactly one of `--link-expires-at <RFC3339 UTC>` or `--no-link-expiry`; omit both to use the workspace default. For project creation, pass `projects create <name> --visibility private|workspace`; persistent project defaults are documented in `projects create --help`. Pass `--no-slack-notify` to suppress the project Slack notification for one post.
|
|
185
185
|
|
|
186
|
+
edit accepts --visibility private|workspace|project|link. Project visibility requires the artifact to be in a project after the edit; use --project-id <id> in the same request if needed. An explicit --visibility project at home (including --home) is refused without changes. Moving a project-visible artifact home makes it private only when project visibility is not explicitly requested.
|
|
187
|
+
|
|
186
188
|
Owners can run `edit <target> --retain-versions 24 --json` to keep the latest 24 published versions, or `--retain-versions all` to clear the limit. Setting or lowering the limit immediately deletes older versions and releases their storage. The response includes `retain_versions` and `deleted_versions`. Deleted version URLs return 404; comments and surviving version numbers remain. This requires unrestricted owner credentials; agent-preset credentials cannot change retention. The edit API accepts the same setting as `retain_versions` (a positive integer or `null`) at `POST /api/cli/shareables/:id/edit`.
|
|
187
189
|
|
|
188
190
|
Link sharing is available on every plan; Team workspaces can turn it off. A workspace policy may allow a finite expiry from 1 to 365 days or no expiration; the initial default is 30 days and the initial maximum is no limit. Share and edit results include the confirmed `link_expires_at` UTC timestamp or `null`. If a link command fails, use `link_sharing_plan_required` as a legacy code (no plan limit applies today), `link_sharing_disabled` to ask the workspace owner or a Team owner or admin to enable the workspace setting, or `link_expiry_invalid` to correct the timestamp or choose `--no-link-expiry` when allowed. Under the default thresholds, `link_publish_rate_limited` means the service observed 20 counted files before a publication in a Free workspace less than 14 days old during its rolling 24-hour window. A file counts once for its most recent change to link visibility, or for creation with link visibility while it remains link-shared. Share with specific people. `error.recovery` indicates `retry_later`; use `error.message` and `error.hint` for when to retry. Retry the link publication later instead of retrying immediately with unchanged input.
|
package/dist/index.js
CHANGED
|
@@ -505,6 +505,7 @@ const ProjectEditResponseSchema = z.object({
|
|
|
505
505
|
const CliEditableVisibilitySchema = z.enum([
|
|
506
506
|
"private",
|
|
507
507
|
"workspace",
|
|
508
|
+
"project",
|
|
508
509
|
"link"
|
|
509
510
|
]);
|
|
510
511
|
const CliDestinationSchema = z.union([z.literal("home"), z.object({ project_id: stringId })]);
|
|
@@ -1104,6 +1105,15 @@ function mapApiError(status, body, options = {}) {
|
|
|
1104
1105
|
command: PROJECTS_LIST_COMMAND
|
|
1105
1106
|
}
|
|
1106
1107
|
});
|
|
1108
|
+
if (options.editSettings && apiCode === "invalid-visibility") return cliError({
|
|
1109
|
+
code: "validation_failed",
|
|
1110
|
+
message: apiMessage ?? "Project visibility requires the artifact to be in a project.",
|
|
1111
|
+
why: "Project visibility requires project placement after the edit.",
|
|
1112
|
+
hint: "Use edit <id> --project-id <id> --visibility project, or move <id> --project-id <id> and retry --visibility project.",
|
|
1113
|
+
agentRecoverable: true,
|
|
1114
|
+
requiresHuman: false,
|
|
1115
|
+
recovery: { kind: "change_input" }
|
|
1116
|
+
});
|
|
1107
1117
|
if (options.editSettings && apiCode === "workspace-unavailable") return cliError({
|
|
1108
1118
|
code: "workspace_unavailable",
|
|
1109
1119
|
message: apiMessage ?? "Workspace visibility is unavailable for this account.",
|
|
@@ -12152,7 +12162,7 @@ function buildEditPayload(parsed) {
|
|
|
12152
12162
|
}
|
|
12153
12163
|
if (parsed.options.visibility !== void 0) {
|
|
12154
12164
|
const visibility = parsed.options.visibility.trim();
|
|
12155
|
-
if (visibility !== "private" && visibility !== "workspace" && visibility !== "link") return { error: validationError("--visibility must be private, workspace, or link.", "Retry with --visibility private, --visibility workspace, or --visibility link.") };
|
|
12165
|
+
if (visibility !== "private" && visibility !== "workspace" && visibility !== "project" && visibility !== "link") return { error: validationError("--visibility must be private, workspace, project, or link.", "Retry with --visibility private, --visibility workspace, --visibility project, or --visibility link.") };
|
|
12156
12166
|
body.visibility = visibility;
|
|
12157
12167
|
hasChange = true;
|
|
12158
12168
|
}
|
|
@@ -13785,7 +13795,7 @@ const editDefinition = define({
|
|
|
13785
13795
|
visibility: {
|
|
13786
13796
|
type: "string",
|
|
13787
13797
|
toKebab: true,
|
|
13788
|
-
description: "private, workspace, or link"
|
|
13798
|
+
description: "private, workspace, project, or link (project requires placement in a project)"
|
|
13789
13799
|
},
|
|
13790
13800
|
linkExpiresAt: {
|
|
13791
13801
|
type: "string",
|
|
@@ -13828,6 +13838,7 @@ const editDefinition = define({
|
|
|
13828
13838
|
examples: `npm exec --yes --package=@artifactshare/cli -- artifactshare edit abc123def4 --title "Launch plan" --json
|
|
13829
13839
|
npm exec --yes --package=@artifactshare/cli -- artifactshare edit abc123def4 --visibility private --grant-email viewer@example.com --json
|
|
13830
13840
|
npm exec --yes --package=@artifactshare/cli -- artifactshare edit https://artifactshare.com/a/abc123def4 --project-id prj123 --json
|
|
13841
|
+
npm exec --yes --package=@artifactshare/cli -- artifactshare edit abc123def4 --project-id prj1 --visibility project --json
|
|
13831
13842
|
npm exec --yes --package=@artifactshare/cli -- artifactshare edit abc123def4 --home --json
|
|
13832
13843
|
|
|
13833
13844
|
Link sharing accepts --visibility link with either --link-expires-at <RFC3339 UTC> or --no-link-expiry. These expiry options are mutually exclusive.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@artifactshare/cli",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.3",
|
|
4
4
|
"description": "Upload and share HTML, Markdown, folders, and static sites from terminals, AI agents, automation, and CI.",
|
|
5
5
|
"homepage": "https://artifactshare.com/connect",
|
|
6
6
|
"repository": {
|
|
@@ -279,6 +279,7 @@ project management.
|
|
|
279
279
|
npm exec --yes --package=@artifactshare/cli -- artifactshare edit <artifact-id-or-url> --title 'New title' --json
|
|
280
280
|
npm exec --yes --package=@artifactshare/cli -- artifactshare edit <artifact-id-or-url> --visibility private --grant-email viewer@example.com --json
|
|
281
281
|
npm exec --yes --package=@artifactshare/cli -- artifactshare edit <artifact-id-or-url> --project-id <id> --json
|
|
282
|
+
npm exec --yes --package=@artifactshare/cli -- artifactshare edit <artifact-id-or-url> --visibility project --json
|
|
282
283
|
npm exec --yes --package=@artifactshare/cli -- artifactshare edit <artifact-id-or-url> --home --json
|
|
283
284
|
npm exec --yes --package=@artifactshare/cli -- artifactshare delete <artifact-id-or-url> --json
|
|
284
285
|
```
|
|
@@ -312,8 +313,7 @@ npm exec --yes --package=@artifactshare/cli -- artifactshare delete <artifact-id
|
|
|
312
313
|
`error.hint` for when to retry, and honor the returned retry duration. Retry
|
|
313
314
|
the link publication later instead of retrying immediately with unchanged
|
|
314
315
|
input.
|
|
315
|
-
-
|
|
316
|
-
has no project audience.
|
|
316
|
+
- edit accepts --visibility private|workspace|project|link. Project visibility requires the artifact to be in a project after the edit; use --project-id <id> in the same request if needed. An explicit --visibility project at home (including --home) is refused without changes. Moving a project-visible artifact home makes it private only when project visibility is not explicitly requested.
|
|
317
317
|
- The older `move` command remains available for placement-only automation, but
|
|
318
318
|
prefer `edit` for new flows.
|
|
319
319
|
- `artifacts delete <artifact-id-or-url>` is an alias of `delete`; both return JSON `command: "delete"`. Keep using top-level `delete` in deletion workflows.
|
|
@@ -73,7 +73,7 @@ contain `$`, spaces, `*`, or `?`; use single quotes such as
|
|
|
73
73
|
Quoted comments are resolved in the viewer using the exact quote and surrounding context, never the nearest repeated words. `--quote-before` and `--quote-after` accept up to 400 characters per side; preserve spaces next to the quote. Creation does not search the artifact. Optional `anchor.position_state` is `unchecked` until that version is viewed, then `attached` or `needs-check`. Only `attached` maps to `anchor.state: attached`; both other states map to `orphaned`. Older responses may omit `position_state`. Local preview uses the same strict resolution on every reload and preserves the original quote when its position needs checking.
|
|
74
74
|
|
|
75
75
|
- Edit, resolve, reopen, and delete comments with `comments edit`, `comments resolve`, `comments reopen`, and `comments delete` using IDs from `comments list`. Comment deletion cannot be undone; omit `--message-id` from `comments delete` only when the user wants the whole thread deleted.
|
|
76
|
-
- Change post-share settings with `edit <target>`: `--title`, `--visibility private|workspace|link`, `--link-expires-at <RFC3339 UTC>`, `--no-link-expiry`, `--grant-email`, `--revoke-email`, `--project-id`, `--home`. The expiry options are mutually exclusive; omit both to preserve an existing link expiry.
|
|
76
|
+
- Change post-share settings with `edit <target>`: `--title`, `--visibility private|workspace|project|link`, `--link-expires-at <RFC3339 UTC>`, `--no-link-expiry`, `--grant-email`, `--revoke-email`, `--project-id`, `--home`. The expiry options are mutually exclusive; omit both to preserve an existing link expiry. Project visibility requires the artifact to be in a project after the edit; use --project-id <id> in the same request if needed. An explicit --visibility project at home (including --home) is refused without changes. Moving a project-visible artifact home makes it private only when project visibility is not explicitly requested. `move` remains for placement-only automation; prefer `edit`.
|
|
77
77
|
- For link errors, `link_sharing_plan_required` is a legacy code (Free can use link sharing now),
|
|
78
78
|
`link_sharing_disabled` means the workspace owner (or a Team admin) must resume the workspace
|
|
79
79
|
setting, and `link_expiry_invalid` means the timestamp must be future and
|