All pages

Lesson 3.2 · Organize your work · 10 min

Files and review

Browse, preview and edit files, then send review notes on the diff.

Listen

After this lesson you can browse and edit your project's files from the right sidebar, pin the important ones into the agent's context, and review the agent's changes line by line before anything is committed.

Time: 10 minutes · Works on: macOS app. Linux and Windows have a smaller Files pane and Review page.

Open the Files tab

  1. Press ⌘⇧\ to show the right sidebar if it's hidden.
  2. Click Files. You see a tree rooted at the current project's folder. The header shows the project's name. With no project, the tree follows the focused pane's working directory, and shows No folder when there's nothing to show.
  3. Click a folder's chevron to expand it. Folders sort before files.

A few buttons sit above the tree:

  • The eye icon shows or hides dotfiles.
  • Refresh reloads every expanded folder. You rarely need it: expanded folders are watched, so the tree updates by itself when a build, a checkout or the agent changes files.
  • The scope icon jumps the tree to the focused pane's working directory instead of the project root.

Preview and edit a file

  1. Click a file. It opens in the preview below the tree.
    • Text files are syntax-highlighted.
    • Markdown is rendered. Use Source to see it as written.
    • Images and PDFs are previewed.
  2. Click the pencil to edit in place. A • next to the name means you have unsaved changes.
  3. Press ⌘S to save, or Esc to discard. TRMNLY asks before throwing away unsaved edits.

Very large text files preview truncated, and a truncated file can't be edited, because saving would drop the part you can't see.

Act on a file

Select a file and use the action bar, or right-click it:

  • Pin to agent keeps the file in the agent's context for this project.
  • Edit in TRMNLY opens the inline editor.
  • Open With opens it in an external editor. Only editors you have installed appear.
  • Reveal in Finder shows it in Finder.
  • cd here, on a folder, sends cd <path> to the focused pane.

Pinning vs. letting the agent read

Pinning puts the file's contents into the agent's context on every turn, up to 24 KB per file. Pin the few files the agent should always have in mind, such as a schema or a style guide. Let it read everything else on demand with its own file tools.

Try it now:

  1. Pin a small file, such as your package.json or README.md.
  2. In the Agent tab, ask "What's in the pinned file?" without naming it.

Review the agent's changes

The Review tab shows the diff you're working on and lets you leave notes on any line. Then you send all the notes to the agent as one message. It's the review you do before anything is pushed.

  1. Ask the agent to make a small change, for example "rename the variable data to rows in one file."
  2. Open the right sidebar's More ▾ menu and choose Review.
  3. The tab shows your uncommitted changes. When the tree is clean, it shows what the branch changes against its base instead.
  4. Click a line and write a note, such as "use a clearer name than rows." Notes are Markdown. To comment on a whole file, use Comment on the whole file….
  5. Add a second note on another line.
  6. Click Send to agent. Every pending note goes to this window's agent as a single message, grouped by file.

The notes you sent stay in the tab, greyed out, so you can see what you already asked for. Use the ⋯ menu to Show sent notes or Clear sent notes.

If the agent is in the middle of a turn, sending is refused and your notes stay pending. Wait for the turn to finish and send again.

Notes follow their line

Once the agent edits the file, line numbers shift. Each note remembers the text of the line it was written on. When notes are listed or sent, each is checked again and reports itself as exact, moved to line N, or lost. A lost note quotes its original line, so the agent never acts on whatever now sits at the old number.

The Review tab follows the window's worktree. In a worktree window, you review that worktree's diff.

Check yourself

  • You edited and saved a file from the Files tab, and the change shows in git diff.
  • A pinned file is something the agent can describe without opening it.
  • You sent two review notes in one message, and the agent answered both.
  • After the agent edited the file, your sent notes still point at the right lines.

Go further

  • Files — previews, limits, and browsing a folder on another machine over SSH
  • Review — note scopes, limits, and the diff_comment_* tools agents use
  • Context and memory — pinned files alongside notes and memory