agex
Docs menuEditor and panes

Tools

Editor and panes

Edit files in editor tabs, read git blame and diffs, and arrange panes, side panes and the split right panel.

Editor tabs

Files open in a code editor with syntax colors, line numbers, indent guides, highlighted occurrences, a minimap and scrollbars. The minimap's toggle is in the editor's header.

KeyAction
⌘SSave. The tab shows ● until you do, and closing it asks.
⌘Z / ⇧⌘ZUndo / redo
⌘/Toggle comments
⌥↑ / ⌥↓Move lines up / down
⇧⌥↓Duplicate lines
⌘LSelect the line
Tab / ⇧TabIndent / outdent
⌘F / ⌥⌘FFind / replace in the file

In the find bar, ↵ and ⇧↵ (or ⌘G and ⇧⌘G) go to the next and previous match, ⌥⌘↵ replaces all, and ⌥⌘C, ⌥⌘W and ⌥⌘R toggle match case, whole word and regular expression.

Files reload when they change on disk. If you have unsaved edits, you choose which version to keep.

Select lines to copy a path:12-20 reference, or to send it to the active terminal or agent.

The editor settings cover the rest: font size and line height, tab size, line numbers, indent guides, highlighting, the cursor, preview tabs, trimming whitespace and a final newline on save, auto save ("off", "after_delay" or "on_focus_change"), and editor.max_file_size_mb, above which a file shows a note instead of opening. See Settings.

Git blame

The cursor's line shows who last changed it, when, and the commit message. Turn this off with editor.inline_blame.

The blame button in the editor's header adds a column with the author and age of each change, with a stripe that runs from warm for recent changes to faint for old ones. Click an entry to open that commit. editor.blame_column sets whether the column starts shown.

Unsaved edits show as uncommitted, and blame refreshes after you commit.

Diff tabs

Click a file, commit or stash, in Source control for example, to open its diff as a tab in the current pane.

  • Diffs have syntax colors.
  • Switch between a unified and a side-by-side view. diff.view sets how they start: "unified" or "split".
  • Step to the previous or next change.
  • Stage, unstage or discard a whole hunk.
  • Click changed lines, or shift-click for a range, to act on just those lines.

Panes

Each split is a floating card with its own tabs.

  • Split in any direction: ⌘D splits right and ⇧⌘D splits down.
  • Resize by dragging the gaps between cards. Double-click a gap to even out the sizes.
  • Drag a tab onto another card to move it there, or drop it on a card's edge to split.
KeyAction
⌘[ / ⌘]Previous / next pane
⇧⌘[ / ⇧⌘], ⌃TabPrevious / next tab
⌘WClose tab

Side panes

The sessions sidebar and the right panel slide open and closed. Toggle the sidebar with ⌘B or the top bar's sidebar button, and the right panel with a panel's shortcut, such as ⇧⌘G for Source Control.

Drag a pane's edge to resize it:

  • The edge snaps to the default width as you pass it. The grip turns blue, and a Force Touch trackpad ticks. Double-click the edge to go back to the default width.
  • At its narrowest, the pane holds still. Keep pushing and it folds away; drag back in the same motion to bring it back.
  • A pane folded this way reopens at the width it had before.

Split the right panel

The right panel can show two panels, one over the other.

  • Open a second panel: ⌥-click another panel's toggle in the top bar to open it below the one showing. For example, with Files showing, ⌥-click the Source Control toggle to get Files over Source Control.
  • Or drag it in: drag a panel's toggle onto the right side and let go over the lower half. Let go over the upper half and it shows there instead.

Once split, each half has a small title:

  • Drag a title onto the other half to swap the two.
  • Drag a title back up onto the top bar to close that half. Its ×, or clicking its toggle, closes it too.

Drag the bar between the halves to share out the height. It snaps to the middle; double-click it to go back there.