# Command line

Last updated: 16 October 2026

The `fyle` command: sign in, copy files, see versions, review changes, run agents and serve MCP. Every command takes `--json` for scripts and agents.

## Sign in

```bash
fyle login     # shows a code; approve it in the browser
fyle whoami
fyle status    # account, connection, queued changes, conflicts
fyle doctor    # checks every step to the server and says what to fix
```

## Files

Remote paths look like `fyle:WORKSPACE/PATH`; anything else is local.

```bash
fyle ls fyle:Projects/docs
fyle cp ./plan.md fyle:Projects/docs/
fyle cp fyle:Projects/docs/plan.md . --version 3
fyle mv fyle:Projects/a.md fyle:Projects/archive/
fyle rm fyle:Projects/old.md          # restorable
fyle versions fyle:Projects/docs/plan.md
fyle restore fyle:Projects/docs/plan.md --version 2
```

Copying over an existing file is based on the version the command just saw. If someone saves in between, your upload becomes a branch for review, never an overwrite (`fyle conflicts` lists yours).

## Reviews

```bash
fyle review ls            # waiting for you (--all, --decided)
fyle review show ID
fyle review diff ID
fyle review decide ID take --reason "looks right"
```

## Agents and MCP

```bash
fyle agent claude                     # run in a session (Linux)
fyle agent ls | show ID | land ID | discard ID
fyle mcp --mode branch_only --paths 'docs/**'
fyle grant create | ls | revoke ID
```

## Linux mounts

```bash
fyle mount Projects          # until Ctrl-C
fyle service install         # every workspace under ~/Fyle, at login
fyle sync --once             # push queued changes, pull remote ones
```
