Skip to content

feat(cli): jss install --bundle <source> (Phase 6 of #464) - #486

Merged
melvincarvalho merged 1 commit into
gh-pagesfrom
issue-485-install-bundle
May 18, 2026
Merged

feat(cli): jss install --bundle <source> (Phase 6 of #464)#486
melvincarvalho merged 1 commit into
gh-pagesfrom
issue-485-install-bundle

Conversation

@melvincarvalho

Copy link
Copy Markdown
Contributor

Fixes #485. Phase 6 — apt-style meta-packages on top of the install atom.

What

jss install --bundle ./media.jsonld                     # local file
jss install --bundle media                              # solid-apps/bundles/main/media.jsonld
jss install --bundle <org>/<repo>                       # that repo's main/bundle.jsonld
jss install --bundle https://example.com/bundle.jsonld  # any URL
jss install --bundle media chrome                       # bundle + ad-hoc additions

Same auth, same target flags as bare install — --pod / --user / --password / --nostr-privkey all work identically.

Bundle shape

JSON-LD schema:ItemList (per the #464 comment):

{
  "@context": { "schema": "https://schema.org/", "app": "urn:jss:app:" },
  "@type": "schema:ItemList",
  "schema:name": "Media stack",
  "schema:itemListElement": [
    "playlist",
    "pdf",
    { "app:spec": "foo/bar=mybar", "app:label": "Custom name" }
  ]
}

Items are bare strings (any Phase 1+2 spec) or objects with app:spec (required). The optional app:label / app:description are for UI tooling that consumes bundles; the install path ignores them.

Verified end-to-end

  • Local-file bundle (./media.jsonld) → all items installed
  • Absolute-path bundle (/tmp/.../bundle.jsonld) → works
  • Items as bare strings + as objects + with rename suffix (e.g. foo/bar=mybar)
  • Bundle + ad-hoc positional args composed (3 from bundle + 1 ad-hoc → 4 installs)
  • Bare-name shorthand resolves correctly to solid-apps/bundles/main/<name>.jsonld (404s today because the repo doesn't exist yet — populating that is a follow-up data task, not a code issue)
  • Malformed JSON, missing items, invalid spec → clear errors, exit 1

URL resolution detail

Uses raw.githubusercontent.com for the shorthand URLs so the fetch returns the raw JSON-LD body, not GitHub's HTML page wrapper.

Out of scope (follow-ups)

  • Phase 6.5: pod-self-recording<pod>/.installed.jsonld written by each install, restorable via jss install --restore <pod-url> for cross-server migration
  • Populate solid-apps/bundles repo — needed for the bare-name shorthand to actually serve content. Separate data task.

Apt-style meta-packages on top of the install atom. Bundles are
JSON-LD ItemList docs naming app specs to install. Same auth, same
target, same per-app status; composes with positional ad-hoc names.

  jss install --bundle ./media.jsonld
  jss install --bundle media                   # → solid-apps/bundles/main/media.jsonld
  jss install --bundle <org>/<repo>            # → that repo's main/bundle.jsonld
  jss install --bundle https://example.com/.jsonld
  jss install --bundle media chrome vellum     # bundle + ad-hoc

Bundle items are bare strings (any Phase 1+2 spec) OR objects with
required app:spec + optional app:label / app:description. The install
path normalizes both forms and feeds them through the existing
parseAppSpec + installOne machinery.

Bundle header (name + description) prints once. Per-app failures
report individually; continue-on-error; exit non-zero if any failed.

Resolves to raw.githubusercontent.com for the URL shorthands so the
fetch returns the raw JSON-LD body (not GitHub's HTML page wrapper).

Verified end-to-end:
  - local-file bundle (./media.jsonld) → all items installed
  - absolute-path bundle (/tmp/...) → works
  - items as bare strings + items as objects + items with rename suffix
  - bundle + ad-hoc args composed
  - bare-name shorthand → correctly fetches solid-apps/bundles/main/<name>.jsonld
  - malformed JSON, missing items, invalid spec — clear errors, exit 1

Fixes #485
@melvincarvalho
melvincarvalho merged commit 99d8bcb into gh-pages May 18, 2026
1 check passed
@melvincarvalho
melvincarvalho deleted the issue-485-install-bundle branch May 18, 2026 04:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

jss install --bundle <source> — apt-style meta-packages (Phase 6 of #464)

1 participant