Skip to content

Editing

Fresh provides a powerful set of editing features with intuitive keybindings.

Platform Note

Some keybindings may not work or may differ on your system due to differences in keyboard layouts, terminal emulators, and operating systems. Terminals capture and report key events differently, and some key combinations may be intercepted by your OS or terminal before reaching Fresh. If a keybinding doesn't work, check the command palette (Ctrl+P) for alternative bindings or use the keyboard configuration to customize bindings.

Multiple Cursors

Edit multiple locations simultaneously:

ShortcutAction
Ctrl+DAdd cursor at next occurrence of selection
Ctrl+Alt+↑Add cursor above
Ctrl+Alt+↓Add cursor below
EscRemove secondary cursors

Selection

ShortcutAction
Ctrl+WSelect word under cursor
Ctrl+LSelect current line
Ctrl+ASelect all
Shift+ArrowExtend selection in direction
Ctrl+Shift+←/→Select word left/right
Shift+Home/EndSelect to line start/end
Ctrl+Shift+Home/EndSelect to document start/end
Shift+PgUp/PgDnSelect page up/down

Block Selection

ShortcutAction
Alt+Shift+↑/↓Block select up/down
Alt+Shift+←/→Block select left/right

Basic Editing

ShortcutAction
Ctrl+CCopy
Ctrl+XCut
Ctrl+VPaste
Ctrl+ZUndo
Ctrl+YRedo
TabIndent
Shift+TabDedent
Ctrl+/Toggle comment
Ctrl+TTranspose characters

Deletion

ShortcutAction
BackspaceDelete backward
DelDelete forward
Ctrl+BackspaceDelete word backward
Ctrl+DelDelete word forward
Ctrl+KDelete to end of line

Case Conversion

ShortcutAction
Alt+UConvert to uppercase
Alt+LConvert to lowercase

Search and Replace

ShortcutAction
Ctrl+FSearch in buffer
Ctrl+RReplace in buffer
Ctrl+Alt+RInteractive replace (y/n/!/q for each match)
F3Find next match
Shift+F3Find previous match TODO - use command palette
Alt+N / Ctrl+F3Find next occurrence of selection
Alt+P / Ctrl+Shift+F3Find previous occurrence of selection TODO - use command palette

See Search and Replace for more details.

Macros

Record and replay sequences of keystrokes:

ShortcutAction
Alt+Shift+0-9Toggle macro recording for slot 0-9
Ctrl+0-9Play macro from slot 0-9 TODO - use command palette
F5Stop macro recording

Bookmarks

Jump quickly between locations in your code:

ShortcutAction
Ctrl+Shift+0-9Set bookmark 0-9
Alt+0-9Jump to bookmark 0-9

Shell Integration

Run shell commands on your buffer or selection:

ShortcutAction
Alt+|Run shell command on buffer/selection (output shown)
Alt+Shift+|Run shell command and replace selection with output
ShortcutAction
Ctrl+GGo to line number
Ctrl+]Go to matching bracket
F8Jump to next error/diagnostic
Shift+F8Jump to previous error/diagnostic
Alt+←Navigate back in history
Alt+→Navigate forward in history

See Navigation for more details.

Released under the Apache 2.0 License