13 Commits

Author SHA1 Message Date
Olli Paloviita 9a3966d650 Export --select, runner detection, per-owner preview slots
Add `screenci export --select`: each finished render becomes the served
version of its language. Off by default, never implied in CI; the init
workflow template shows it on the export line.

Every upload now reports where the CLI runs (`runner: 'ci' | 'local'`,
from the usual CI environment variables with a `SCREENCI_CI=1/0`
override), on upload start and on the preview-started ping, so the
service can attribute exports and keep CI previews apart from each
person's own preview.

Docs: cli reference, version history, public URLs, CI setup, editor,
and the agent skill describe selection without the auto-select toggle.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01KQgcfo9BeSAKAQL8JsEjJC
2026-09-15 15:21:28 +03:00
Olli Paloviita 1c3b7facc7 Add screenci start: setup codes, service-hosted sources, source sync
The web app's Add project / Add video / Edit buttons hand a coding agent a
one-time setup code. `screenci start <code>` exchanges it for a
project-scoped SCREENCI_SECRET and editor token, scaffolds or pulls the
./screenci workspace, and prints a task brief. Service-managed islands
(projectId in the config, or uploadSources: true) upload their text
sources before every preview and export and report the finished run so
the originating browser tab can open the result.

- src/start.ts: the start command (exchange, workspace resolution with
  pre-exchange refusal of repository-managed islands, pull/scaffold/sync,
  credentials, brief and JSON line, shell-secret warning)
- src/sourceBundle.ts: island source collection honoring the island
  .gitignore and skipping dot-directories, media, env files and lockfiles;
  cap measured on the serialized bundle; safe apply with conflict refusal
- src/sourceSync.ts: best-effort bundle upload, run-complete report, pull
- src/configLite.ts: import-free config readers (moved from cli.ts)
- init.ts: scaffold core extracted for reuse; stale next-steps text fixed
- config: projectId and uploadSources
- docs: new create-from-web-app guide, CLI/configuration/overview updates,
  skill quick start for setup codes

Claude-Session: https://claude.ai/code/session_01PrQjfaGjMuTrMCHR5RPS2w
2026-09-02 14:35:28 +03:00
Olli Paloviita e801ef6b29 Add --share to screenci export: share finished versions with permanent public URLs
--share waits for the renders, shares each finished version via
/cli/share-versions, prints the version-pinned public URLs, and skips
the download. Combining it with --no-wait errors, since sharing needs
finished renders.
2026-09-02 12:57:34 +03:00
Olli Paloviita 74d702ba22 Remove the anon per-run video cap and the preview freshness skip
- Anonymous trials no longer cap videos per recording; export remains paid-only.
- screenci preview always re-records the matched videos (all declared without a pattern); the up-to-date skip, --force-record, and the staleness machinery in devStartup are gone.
2026-09-02 08:59:16 +03:00
Olli Paloviita 7168495a7a Link the run listing page whenever a run has several passes, including one video in several languages 2026-09-02 08:50:05 +03:00
Olli Paloviita b7c9e5602d Drop sync from the no-command Available commands listing 2026-09-02 08:39:38 +03:00
Olli Paloviita ce688f03ac Remove code-sync (sync command, --watch, implicit drains); link the video overview page
- Drop the sync command, preview --watch/--no-watch/--no-sync, --record-kill-window, and the queued-edit drains before test/export/preview. Editor edits now live in the web editor and are not written back to sources.
- Delete codeSync, applyCodegen, editorOptionsSync, devWatch, codegenFailureLog and their specs; trim devListen to register/sync-state/deregister.
- preview is always one-shot; generated CI workflows run plain screenci preview.
- CLI links point at the video overview page: preview prints /project/<pid>/video/<vid>, a single-video export prints ...?export=<recordId>, multi-video runs keep the run pages. Held-video notices deep-link ?editor.
- Rewrite docs, skill files, and the narration guidance: narrate the flow rather than each click, use the product's own vocabulary, and fill forms with fictitious example data (Emma Carter, emma@aperturebio.com).
2026-09-01 23:32:36 +03:00
Olli Paloviita 66fc112d74 Add preview --no-sync and switch the generated CI workflow to it
preview --no-sync skips draining queued editor edits (CI checkouts stay
read-only; a best-effort warning surfaces pending edits instead). The
init-generated GitHub workflow now records with preview --no-sync by
default and keeps export --no-wait as a commented-out alternative. The
one-shot preview also writes the GitHub Actions screenci_project_url
output so the workflow's environment URL keeps working. Docs, skill, and
agent guides updated; includes an existing test for export --no-wait.

Claude-Session: https://claude.ai/code/session_01GxXzWaAmE3qJfiwSkfkZ4F
2026-08-26 19:44:51 +03:00
Olli Paloviita 5ba841d443 cli: fix multi-language export upload accounting
uploadedVideoNames and held-video names now report declared (base) video
names, deduped across per-language passes, instead of the suffixed display
names ('Demo [en]'). The export success check compares requested names
against uploaded ones, so suffixed names could never match for a
multi-language video and export aborted with 'Recording upload failed;
nothing to export' after fully successful uploads. Saved source hashes and
held filtering matched against kept recordings by the same names and were
silently empty too. Display names stay on the per-pass upload lines and
failure messages.
2026-08-24 16:30:29 +03:00
Olli Paloviita 5c9f99b61f Rename screenci edit to screenci preview; notify the backend when a preview recording starts
The bridge mode moves behind preview --watch (one video at a time as
before); a one-shot preview has no single-video limit. Printed links now
point at the new per-video preview page. Before a preview pass records,
the CLI tells the backend which videos are about to record (fire and
forget) so the web preview page can show a live recording indicator.
Docs and the agent skill updated for the new command shape.
2026-08-18 12:48:56 +03:00
Olli Paloviita 679c9db2bf Auto-mint the editor token from the org secret; queue edits while the bridge is offline
screenci edit no longer needs a hand-created SCREENCI_EDIT_TOKEN: the
CLI exchanges the org secret for a machine-scoped editor token minted
by the server (idempotent per machine, revocable on the Secrets page).

Edits made in the web editor while no bridge is connected queue as
deferred codegen requests; the next screenci edit run drains them into
the script before listening. Export skips Studio-held videos instead of
waiting on renders that will never start, and reports when everything
is held. Docs updated to match.
2026-08-18 10:53:42 +03:00
Olli Paloviita 578ff0e536 Let the anonymous trial run screenci edit; require an account for export
The anonymous trial is now preview-only. screenci edit works without a
SCREENCI_SECRET: the anon session token doubles as the dev token, and a
claimed trial self-upgrades in place (the claim-minted org secret and
personal editor token are persisted into .env and the bridge reconnects
without stopping). Expired or claimed-elsewhere sessions get clear
next steps.

screenci export now refuses the anonymous trial up front and points at
edit for the free live preview and at sign-up for exporting; a claimed
trial self-upgrades to the real secret and proceeds.

Docs and the agent skill are updated to match.
2026-08-13 12:18:18 +03:00
Olli Paloviita 96fddbaa6c editor: rename record command to export, edit specs, export run updates 2026-08-12 19:59:23 +03:00