---
title: CLI
weight: 20
generated: true
---

<!-- Generated by scripts/gen-cli-docs.sh from the libfossil --help output. Do not edit; change the help text in cli/ and run make docs-gen. -->

The `libfossil` command, one page per command group. Every page is the output of the binary's own `--help`.

```text
Usage: libfossil <command> [flags]

Fossil-compatible repository tool (pure Go)

Flags:
  -h, --help           Show context-sensitive help.
  -R, --repo=STRING    Path to repository file
  -v, --verbose        Verbose output

Commands:
  repo new [<path>] [flags]
    Create a new repository

  repo clone [<url> [<path>]] [flags]
    Clone a remote repository

  repo ci --message=STRING [<files> ...] [flags]
    Checkin file changes

  repo co [<version>] [flags]
    Checkout a version

  repo ls [<version>] [flags]
    List files in a version

  repo timeline [flags]
    Show repository history

  repo snapshot --message=STRING --path=STRING [flags]
    Commit a file's bytes onto trunk, no checkout needed

  repo log --path=STRING [flags]
    Show the check-ins that changed a path

  repo cat <artifact> [flags]
    Output artifact content

  repo info
    Repository statistics

  repo hash <files> ... [flags]
    Hash files (SHA1 or SHA3)

  repo delta create <source> <target> [flags]
    Create a delta between two files

  repo delta apply <source> <delta> [flags]
    Apply a delta to a source file

  repo config ls
    List all config entries

  repo config get <key>
    Get a config value

  repo config set <key> <value>
    Set a config value

  repo query <sql>
    Execute SQL against repository

  repo verify [flags]
    Verify repository integrity

  repo resolve <name>
    Resolve symbolic name to UUID

  repo extract [<files> ...] [flags]
    Extract files from a version

  repo wiki ls
    List wiki pages

  repo wiki export <page> [flags]
    Export a wiki page

  repo tag ls [<version>]
    List tags on an artifact

  repo tag add <tag> [<value>] [flags]
    Add a tag to an artifact

  repo open [<dir>] [flags]
    Open a checkout in a directory

  repo status [flags]
    Show working directory changes

  repo add <files> ... [flags]
    Stage files for addition

  repo rm <files> ... [flags]
    Stage files for removal

  repo rename <from> <to> [flags]
    Rename a tracked file

  repo revert [<files> ...] [flags]
    Undo staging changes

  repo diff [<version> [<to> [<path>]]] [flags]
    Show changes vs a version

  repo merge <version> [flags]
    Merge a divergent version

  repo conflicts ls [flags]
    List all conflicts

  repo conflicts show <file> [flags]
    Show all versions of a conflicted file

  repo conflicts pick <file> [flags]
    Resolve by picking one version

  repo conflicts merge <file> [flags]
    Resolve by re-merging with a different strategy

  repo conflicts extract <file> [flags]
    Extract all versions to disk for manual editing

  repo mark-resolved <file> [flags]
    Mark a conflict as resolved

  repo undo [flags]
    Undo last operation

  repo redo [flags]
    Redo undone operation

  repo stash save [flags]
    Stash working changes

  repo stash pop [flags]
    Apply top stash and drop it

  repo stash apply [<id>] [flags]
    Apply stash without dropping

  repo stash ls
    List stash entries

  repo stash drop <id>
    Remove stash entry

  repo stash clear
    Remove all stash entries

  repo bisect good [<version>] [flags]
    Mark version as good

  repo bisect bad [<version>] [flags]
    Mark version as bad

  repo bisect next [flags]
    Check out midpoint version

  repo bisect skip [<version>] [flags]
    Skip current version

  repo bisect reset [flags]
    Clear bisect state

  repo bisect ls [flags]
    Show bisect path

  repo bisect status [flags]
    Show bisect state

  repo annotate <file> [flags]
    Annotate file lines with version history

  repo blame <file> [flags]
    Alias for annotate

  repo branch ls [flags]
    List branches

  repo branch new <name> [flags]
    Create new branch

  repo branch close <name> [flags]
    Close a branch

  repo uv ls
    List unversioned files

  repo uv put <name> <file>
    Add or update an unversioned file

  repo uv get <name> [flags]
    Retrieve an unversioned file

  repo uv delete <name>
    Delete an unversioned file (creates tombstone)

  repo schema add --columns=STRING <name> [flags]
    Register a new synced table

  repo schema list
    List registered synced tables

  repo schema show <name>
    Show table schema details

  repo schema remove <name>
    Remove a synced table registration

  repo user add --cap=STRING <login>
    Create a new user

  repo user list
    List all users

  repo user update --cap=STRING <login>
    Update user capabilities

  repo user rm <login>
    Delete a user

  repo user passwd <login>
    Reset user password

  repo invite --cap=STRING <login> [flags]
    Generate invite token for a user

  repo serve [flags]
    Serve repository over HTTP for sync/clone

  repo submanifests enable [flags]
    Write new check-ins as sub-manifest trees

  repo submanifests retune --k=INT
    Re-pin the partition parameter for later commits

  repo submanifests disable
    Write new check-ins as flat manifests again

  repo submanifests status
    Show the sub-manifest settings and whether trees exist

  repo cone show [flags]
    List the cone's members ("dense" when there is none)

  repo cone add <paths> ... [flags]
    Widen the cone, or with --not carve paths out of it

  repo cone remove <paths> ... [flags]
    Remove members of either polarity

  repo cone set <paths> ... [flags]
    Replace the cone

  repo cone dense [flags]
    Drop the cone and materialize every file

  repo cone test <paths> ... [flags]
    Classify paths against the cone and name the deciding member

  repo cone store [<paths> ...] [flags]
    Show or replace the repository's store cone, fetching what widening covers

  repo cone deepen <checkin> [flags]
    Move the store's horizon down to reach a check-in, fetching the history it
    keeps

  repo cone compact
    Drop held blobs the store cone elides (irreversible locally)

  repo cone cost <checkin>
    Report what each horizon rule would hold at a check-in, from this repository

  version [flags]
    Print version information

Run "libfossil <command> --help" for more information on a command.
```

## Command groups

- [`libfossil repo new`](/docs/reference/cli/repo-new/): Create a new repository
- [`libfossil repo clone`](/docs/reference/cli/repo-clone/): Clone a remote repository
- [`libfossil repo ci`](/docs/reference/cli/repo-ci/): Checkin file changes
- [`libfossil repo co`](/docs/reference/cli/repo-co/): Checkout a version
- [`libfossil repo ls`](/docs/reference/cli/repo-ls/): List files in a version
- [`libfossil repo timeline`](/docs/reference/cli/repo-timeline/): Show repository history
- [`libfossil repo snapshot`](/docs/reference/cli/repo-snapshot/): Commit a file's bytes onto trunk, no checkout needed
- [`libfossil repo log`](/docs/reference/cli/repo-log/): Show the check-ins that changed a path
- [`libfossil repo cat`](/docs/reference/cli/repo-cat/): Output artifact content
- [`libfossil repo info`](/docs/reference/cli/repo-info/): Repository statistics
- [`libfossil repo hash`](/docs/reference/cli/repo-hash/): Hash files (SHA1 or SHA3)
- [`libfossil repo delta`](/docs/reference/cli/repo-delta/): Delta create/apply operations
- [`libfossil repo config`](/docs/reference/cli/repo-config/): Repository configuration
- [`libfossil repo query`](/docs/reference/cli/repo-query/): Execute SQL against repository
- [`libfossil repo verify`](/docs/reference/cli/repo-verify/): Verify repository integrity
- [`libfossil repo resolve`](/docs/reference/cli/repo-resolve/): Resolve symbolic name to UUID
- [`libfossil repo extract`](/docs/reference/cli/repo-extract/): Extract files from a version
- [`libfossil repo wiki`](/docs/reference/cli/repo-wiki/): Wiki page operations
- [`libfossil repo tag`](/docs/reference/cli/repo-tag/): Tag operations
- [`libfossil repo open`](/docs/reference/cli/repo-open/): Open a checkout in a directory
- [`libfossil repo status`](/docs/reference/cli/repo-status/): Show working directory changes
- [`libfossil repo add`](/docs/reference/cli/repo-add/): Stage files for addition
- [`libfossil repo rm`](/docs/reference/cli/repo-rm/): Stage files for removal
- [`libfossil repo rename`](/docs/reference/cli/repo-rename/): Rename a tracked file
- [`libfossil repo revert`](/docs/reference/cli/repo-revert/): Undo staging changes
- [`libfossil repo diff`](/docs/reference/cli/repo-diff/): Show changes vs a version
- [`libfossil repo merge`](/docs/reference/cli/repo-merge/): Merge a divergent version
- [`libfossil repo conflicts`](/docs/reference/cli/repo-conflicts/): List/manage unresolved conflicts
- [`libfossil repo mark-resolved`](/docs/reference/cli/repo-mark-resolved/): Mark a conflict as resolved
- [`libfossil repo undo`](/docs/reference/cli/repo-undo/): Undo last operation
- [`libfossil repo redo`](/docs/reference/cli/repo-redo/): Redo undone operation
- [`libfossil repo stash`](/docs/reference/cli/repo-stash/): Stash working changes
- [`libfossil repo bisect`](/docs/reference/cli/repo-bisect/): Binary search for bugs
- [`libfossil repo annotate`](/docs/reference/cli/repo-annotate/): Annotate file lines with version history
- [`libfossil repo blame`](/docs/reference/cli/repo-blame/): Alias for annotate
- [`libfossil repo branch`](/docs/reference/cli/repo-branch/): Branch operations
- [`libfossil repo uv`](/docs/reference/cli/repo-uv/): Unversioned file operations
- [`libfossil repo schema`](/docs/reference/cli/repo-schema/): Synced table schema operations
- [`libfossil repo user`](/docs/reference/cli/repo-user/): User management
- [`libfossil repo invite`](/docs/reference/cli/repo-invite/): Generate invite token for a user
- [`libfossil repo serve`](/docs/reference/cli/repo-serve/): Serve repository over HTTP for sync/clone
- [`libfossil repo submanifests`](/docs/reference/cli/repo-submanifests/): Sub-manifest tree settings
- [`libfossil repo cone`](/docs/reference/cli/repo-cone/): Show or edit a checkout's sparse cone
- [`libfossil version`](/docs/reference/cli/version/): Print version information
