home blog portfolio Ian Fisher

Evaluating Zed

Template: Evaluating a text editor

Zed is a "next-generation" code editor. I tested it out after becoming increasingly unsatisfied with VS Code.

Critical

Important

Nice-to-have

Customizations

Keymap

Make Ctrl+Tab, Ctrl+Shift+Tab, Ctrl+PgDn, and Ctrl+PgUp behave like Chrome:

  {
    "context": "Pane",
    "bindings": {
      "ctrl-tab": "pane::ActivateNextItem",
      "ctrl-shift-tab": "pane::ActivatePreviousItem",
      "ctrl-pagedown": "pane::ActivateNextItem",
      "ctrl-pageup": "pane::ActivatePreviousItem"
    }
  },
  {
    "context": "Editor",
    "bindings": {
      "ctrl-pagedown": "pane::ActivateNextItem",
      "ctrl-pageup": "pane::ActivatePreviousItem"
    }
  }

Vim mode keybindings:

{
  "context": "vim_mode == insert",
  "bindings": {
    "j j": "vim::NormalBefore"
  }
}

Make Opt+Enter work in the terminal (macOS):

{
  "context": "Terminal",
  "bindings": { "alt-enter": ["terminal::SendKeystroke", "alt-enter"] }
}

Settings

Apparently both pylsp and pyright were enabled by default for Python, which caused issues – duplicate tooltips, autocomplete didn't work. I solved it by only enabling pyright:

"languages": {
  "Python": {
    "language_servers": ["pyright"]
  }
}

Auto-format Python files on save using black:

"languages": {
  "Python": {
    "format_on_save": "on",
    "formatter": { "external": { "command": "black", "arguments": ["-"]
  }
}

Enable Vim mode:

"vim_mode": true

Make Opt key on macOS function as Meta in the integrated terminal:

"terminal": {
  "option_as_meta": true
}

Known bugs