---
title: "af op"
description: "Read the repository's operation log"
---

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

# af op

<!-- Generated by tools/gen-reference.mjs from `af op --help`. Change the help text in crates/atoll-forge-cli/src/main.rs, then run `npm run gen:reference`. -->

Every write to the repository is an operation: a start, a snapshot, a rebase, an undo. The log lists them newest first, as `jj op log` does, each with what it did, who did it, and whether it was undone. An undo candidate is an active write of yours, or of an agent you started; `af undo` checks it again, and refuses it if one of its changes was written since, submitted or landed.

## Usage

```text
af op [OPTIONS] <COMMAND>
```

## Commands

| Command | What it does |
| --- | --- |
| [`log`](#af-op-log) | List the operations, newest first |
| [`show`](#af-op-show) | Show an operation: what it did, and each change it wrote |
| [`diff`](#af-op-diff) | Compare two operations: each change as it stood at each |

## Global options

Every `af` command also takes the [global options](https://docs.forge.workreef.dev/reference/af/#global-options).

## Examples

```sh
af op log
af op show 3f2a9c1e
```

## af op log {#af-op-log}

List the operations, newest first

### Usage

```text
af op log [OPTIONS]
```

### Options

- `-n, --limit <LIMIT>`

  How many operations to list

  Default: `50`

### Global options

Every `af` command also takes the [global options](https://docs.forge.workreef.dev/reference/af/#global-options).

## af op show {#af-op-show}

Show an operation: what it did, and each change it wrote

Shows OPERATION as `jj op show` does: when it ended, what it did and who did it, whether it was undone, its parents, and each change it wrote as it was before and after, with the paths it changed there (a start, against the commit it started on). Name it by the start of its id as `af op log` shows it, or all of it.

### Usage

```text
af op show [OPTIONS] <OPERATION>
```

### Arguments

- `<OPERATION>`

  The operation, by the start of its id or all of it

### Options

- `--paths <PATHS>`

  How many changed paths to list for each change

  Default: `20`

### Global options

Every `af` command also takes the [global options](https://docs.forge.workreef.dev/reference/af/#global-options).

## af op diff {#af-op-diff}

Compare two operations: each change as it stood at each

Compares two operations as `jj op diff` does: each change as it stood at the first and at the second, with the paths that changed between, and main at each if it moved. A change that ended as it began is left out. Here it is the changes the forge published between the two operations' moments. Name each operation by the start of its id as `af op log` shows it, or all of it.

### Usage

```text
af op diff [OPTIONS]
```

### Options

- `--from <FROM>`

  The first operation; the second's parent if omitted

- `--to <TO>`

  The second operation; the newest if omitted

- `--paths <PATHS>`

  How many changed paths to list for each change

  Default: `20`

### Global options

Every `af` command also takes the [global options](https://docs.forge.workreef.dev/reference/af/#global-options).

Source: https://docs.forge.workreef.dev/reference/af/op/index.mdx
