# Publish

`publish` copies a staged shareable dataset bundle into shared space.

Usage:

```bash
./publish <owner> <dataset-uuid> [--force] [--source-root <path>] [--target-root <path>]
```

Example:

```bash
./publish user1 fec0edc4-007a-4437-993e-0cd17fe4df55
```

This copies:

```text
./users/user1/datasets/share/fec0edc4-007a-4437-993e-0cd17fe4df55
```

to:

```text
./shared/datasets/fec0edc4-007a-4437-993e-0cd17fe4df55
```

If the target already exists, use:

```bash
./publish user1 <dataset-uuid> --force
```

For sandboxed test runs, override the roots so the copy stays inside the sandbox:

```bash
./publish user1 <dataset-uuid> \
  --source-root ./sandbox/two-console-demo/users \
  --target-root ./sandbox/two-console-demo/shared/datasets
```
