> ## Documentation Index
> Fetch the complete documentation index at: https://demoman.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Add to your repo

> Save a flow's DemoScript in the repo, so every clone and every CI run can record it again.

<ol />

A video goes stale when the app changes. Adding its flow to the repo saves the
flow as a DemoScript, which CI records again in the next step.

## Add it

In the repo, with a flow your agent recorded:

```bash theme={null}
npx demoman add "Add a task" --to docs/add-task.mp4
```

It writes the DemoScript, a receipt with its screens, and the export. Commit everything it wrote:

| File | What it is |
| - | - |
| `.demoman/flows/add-task.json` | The flow's DemoScript: every step a new video needs. See [Flows and DemoScripts](https://demoman.io/docs/concepts/flows.md) |
| `.demoman/receipts/add-task.json` | What the export shows, for a refresh to compare against |
| `.demoman/receipts/add-task.screens/` | A folder of the screens the receipt describes, as pictures |
| `docs/add-task.mp4` | The export, at the path you named |

`--gif <path>` adds a GIF, and `--to` may repeat. To keep videos out of git
and upload them yourself, see `--deliver files` on [add](https://demoman.io/docs/reference/add.md).

The flow's id is in the DemoScript, so every machine that clones the repo
shares it. When your agent later records into a flow in the repo, its
DemoScript follows the new script.

## From the Studio

![The Studio's Add to repo sheet: Folder, File name, Video (Commit or Files) and Quality](https://mintcdn.com/demoman/O3tJ6P1Ez8jWdNCL/media/studio/add-to-repo.png?fit=max\&auto=format\&n=O3tJ6P1Ez8jWdNCL\&q=85\&s=016413af021918af34a83a47fc59676f)

**Add to repo** is on a flow's card and row in the Studio, and in the
editor's Export panel. Its sheet asks for the path, the delivery and the
quality, writes the same files, and ends on each with Reveal. After a
**Commit** add in a repo with no CI yet, it offers the next step's setup.

## When add refuses

Add writes nothing for a flow a new video cannot reproduce, and names why:

* **Studio edits** a new video does not carry: a cut, a split, a mask, a
  hold, a gap, a zoom you placed, or an end trim that can't be placed.
  Remove the edit, or record the flow again. A trim and a click's zoom are
  carried: they are written into the DemoScript.
* **Your own sign-in.** A flow recorded after `signin` needs a demo account
  first ([Sign in](https://demoman.io/docs/get-started/sign-in.md)).
* **Typed text the video never read.** Record the flow again.
* **No settled screen.** The detail says the output "has no settled screen
  to compare against": the page never settled after any step, so a refresh
  would have nothing to check. The detail names why for each screen, such
  as `the DOM never went quiet` or `1 request(s) in flight`. Record the
  flow again once the page can settle.
* **A video from before page screens.** The detail says it "has no page
  screens to compare: it was recorded before page screens". Record the flow
  again.

The reasons that need you, with what to do, are on [Refusals](https://demoman.io/docs/reference/refusals.md#adding-a-flow).

> [card] [Next · 06](https://demoman.io/docs/get-started/ci.md)
>
> Keep videos current


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.