default.json

  1{
  2  // The name of the Zed theme to use for the UI
  3  "theme": "One Dark",
  4  // The name of a base set of key bindings to use.
  5  // This setting can take four values, each named after another
  6  // text editor:
  7  //
  8  // 1. "VSCode"
  9  // 2. "JetBrains"
 10  // 3. "SublimeText"
 11  // 4. "Atom"
 12  "base_keymap": "VSCode",
 13  // Features that can be globally enabled or disabled
 14  "features": {
 15    // Show Copilot icon in status bar
 16    "copilot": true
 17  },
 18  // The name of a font to use for rendering text in the editor
 19  "buffer_font_family": "Zed Mono",
 20  // The OpenType features to enable for text in the editor.
 21  "buffer_font_features": {
 22    // Disable ligatures:
 23    // "calt": false
 24  },
 25  // The default font size for text in the editor
 26  "buffer_font_size": 15,
 27  // Set the buffer's line height.
 28  // May take 3 values:
 29  //  1. Use a line height that's comfortable for reading (1.618)
 30  //         "line_height": "comfortable"
 31  //  2. Use a standard line height, (1.3)
 32  //         "line_height": "standard",
 33  //  3. Use a custom line height
 34  //         "line_height": {
 35  //           "custom": 2
 36  //         },
 37  "buffer_line_height": "comfortable",
 38  // The factor to grow the active pane by. Defaults to 1.0
 39  // which gives the same size as all other panes.
 40  "active_pane_magnification": 1.0,
 41  // Whether to enable vim modes and key bindings
 42  "vim_mode": false,
 43  // Whether to show the informational hover box when moving the mouse
 44  // over symbols in the editor.
 45  "hover_popover_enabled": true,
 46  // Whether to confirm before quitting Zed.
 47  "confirm_quit": false,
 48  // Whether the cursor blinks in the editor.
 49  "cursor_blink": true,
 50  // Whether to pop the completions menu while typing in an editor without
 51  // explicitly requesting it.
 52  "show_completions_on_input": true,
 53  // Whether to use additional LSP queries to format (and amend) the code after
 54  // every "trigger" symbol input, defined by LSP server capabilities.
 55  "use_on_type_format": true,
 56  // Controls whether copilot provides suggestion immediately
 57  // or waits for a `copilot::Toggle`
 58  "show_copilot_suggestions": true,
 59  // Whether to show tabs and spaces in the editor.
 60  // This setting can take two values:
 61  //
 62  // 1. Draw tabs and spaces only for the selected text (default):
 63  //    "selection"
 64  // 2. Do not draw any tabs or spaces:
 65  //   "none"
 66  // 3. Draw all invisible symbols:
 67  //   "all"
 68  "show_whitespaces": "selection",
 69  // Settings related to calls in Zed
 70  "calls": {
 71    // Join calls with the microphone muted by default
 72    "mute_on_join": true
 73  },
 74  // Scrollbar related settings
 75  "scrollbar": {
 76    // When to show the scrollbar in the editor.
 77    // This setting can take four values:
 78    //
 79    // 1. Show the scrollbar if there's important information or
 80    //    follow the system's configured behavior (default):
 81    //   "auto"
 82    // 2. Match the system's configured behavior:
 83    //    "system"
 84    // 3. Always show the scrollbar:
 85    //    "always"
 86    // 4. Never show the scrollbar:
 87    //    "never"
 88    "show": "auto",
 89    // Whether to show git diff indicators in the scrollbar.
 90    "git_diff": true,
 91    // Whether to show selections in the scrollbar.
 92    "selections": true
 93  },
 94  // Inlay hint related settings
 95  "inlay_hints": {
 96    // Global switch to toggle hints on and off, switched off by default.
 97    "enabled": false,
 98    // Toggle certain types of hints on and off, all switched on by default.
 99    "show_type_hints": true,
100    "show_parameter_hints": true,
101    // Corresponds to null/None LSP hint type value.
102    "show_other_hints": true
103  },
104  "project_panel": {
105    // Whether to show the git status in the project panel.
106    "git_status": true,
107    // Whether to show file icons in the project panel.
108    "file_icons": true,
109    // Where to dock project panel. Can be 'left' or 'right'.
110    "dock": "left",
111    // Default width of the project panel.
112    "default_width": 240
113  },
114  "assistant": {
115    // Where to dock the assistant. Can be 'left', 'right' or 'bottom'.
116    "dock": "right",
117    // Default width when the assistant is docked to the left or right.
118    "default_width": 640,
119    // Default height when the assistant is docked to the bottom.
120    "default_height": 320
121  },
122  // Whether the screen sharing icon is shown in the os status bar.
123  "show_call_status_icon": true,
124  // Whether to use language servers to provide code intelligence.
125  "enable_language_server": true,
126  // When to automatically save edited buffers. This setting can
127  // take four values.
128  //
129  // 1. Never automatically save:
130  //     "autosave": "off",
131  // 2. Save when changing focus away from the Zed window:
132  //     "autosave": "on_window_change",
133  // 3. Save when changing focus away from a specific buffer:
134  //     "autosave": "on_focus_change",
135  // 4. Save when idle for a certain amount of time:
136  //     "autosave": { "after_delay": {"milliseconds": 500} },
137  "autosave": "off",
138  // Settings related to the editor's tabs
139  "tabs": {
140    // Show git status colors in the editor tabs.
141    "git_status": false,
142    // Position of the close button on the editor tabs.
143    "close_position": "right"
144  },
145  // Whether or not to remove any trailing whitespace from lines of a buffer
146  // before saving it.
147  "remove_trailing_whitespace_on_save": true,
148  // Whether to start a new line with a comment when a previous line is a comment as well.
149  "extend_comment_on_newline": true,
150  // Whether or not to ensure there's a single newline at the end of a buffer
151  // when saving it.
152  "ensure_final_newline_on_save": true,
153  // Whether or not to perform a buffer format before saving
154  "format_on_save": "on",
155  // How to perform a buffer format. This setting can take two values:
156  //
157  // 1. Format code using the current language server:
158  //     "formatter": "language_server"
159  // 2. Format code using an external command:
160  //     "formatter": {
161  //       "external": {
162  //         "command": "prettier",
163  //         "arguments": ["--stdin-filepath", "{buffer_path}"]
164  //       }
165  //     }
166  "formatter": "language_server",
167  // How to soft-wrap long lines of text. This setting can take
168  // three values:
169  //
170  // 1. Do not soft wrap.
171  //      "soft_wrap": "none",
172  // 2. Soft wrap lines that overflow the editor:
173  //      "soft_wrap": "editor_width",
174  // 3. Soft wrap lines at the preferred line length
175  //      "soft_wrap": "preferred_line_length",
176  "soft_wrap": "none",
177  // The column at which to soft-wrap lines, for buffers where soft-wrap
178  // is enabled.
179  "preferred_line_length": 80,
180  // Whether to indent lines using tab characters, as opposed to multiple
181  // spaces.
182  "hard_tabs": false,
183  // How many columns a tab should occupy.
184  "tab_size": 4,
185  // Control what info is collected by Zed.
186  "telemetry": {
187    // Send debug info like crash reports.
188    "diagnostics": true,
189    // Send anonymized usage data like what languages you're using Zed with.
190    "metrics": true
191  },
192  // Automatically update Zed
193  "auto_update": true,
194  // Git gutter behavior configuration.
195  "git": {
196    // Control whether the git gutter is shown. May take 2 values:
197    // 1. Show the gutter
198    //      "git_gutter": "tracked_files"
199    // 2. Hide the gutter
200    //      "git_gutter": "hide"
201    "git_gutter": "tracked_files"
202  },
203  "copilot": {
204    // The set of glob patterns for which copilot should be disabled
205    // in any matching file.
206    "disabled_globs": [
207      ".env"
208    ]
209  },
210  // Settings specific to journaling
211  "journal": {
212    // The path of the directory where journal entries are stored
213    "path": "~",
214    // What format to display the hours in
215    // May take 2 values:
216    // 1. hour12
217    // 2. hour24
218    "hour_format": "hour12"
219  },
220  // Settings specific to the terminal
221  "terminal": {
222    // What shell to use when opening a terminal. May take 3 values:
223    // 1. Use the system's default terminal configuration in /etc/passwd
224    //      "shell": "system"
225    // 2. A program:
226    //      "shell": {
227    //        "program": "sh"
228    //      }
229    // 3. A program with arguments:
230    //     "shell": {
231    //         "with_arguments": {
232    //           "program": "/bin/bash",
233    //           "arguments": ["--login"]
234    //         }
235    //     }
236    "shell": "system",
237    // Where to dock terminals panel. Can be 'left', 'right', 'bottom'.
238    "dock": "bottom",
239    // Default width when the terminal is docked to the left or right.
240    "default_width": 640,
241    // Default height when the terminal is docked to the bottom.
242    "default_height": 320,
243    // What working directory to use when launching the terminal.
244    // May take 4 values:
245    // 1. Use the current file's project directory.  Will Fallback to the
246    //    first project directory strategy if unsuccessful
247    //      "working_directory": "current_project_directory"
248    // 2. Use the first project in this workspace's directory
249    //      "working_directory": "first_project_directory"
250    // 3. Always use this platform's home directory (if we can find it)
251    //     "working_directory": "always_home"
252    // 4. Always use a specific directory. This value will be shell expanded.
253    //    If this path is not a valid directory the terminal will default to
254    //    this platform's home directory  (if we can find it)
255    //      "working_directory": {
256    //        "always": {
257    //          "directory": "~/zed/projects/"
258    //        }
259    //      }
260    //
261    //
262    "working_directory": "current_project_directory",
263    // Set the cursor blinking behavior in the terminal.
264    // May take 4 values:
265    //  1. Never blink the cursor, ignoring the terminal mode
266    //         "blinking": "off",
267    //  2. Default the cursor blink to off, but allow the terminal to
268    //     set blinking
269    //         "blinking": "terminal_controlled",
270    //  3. Always blink the cursor, ignoring the terminal mode
271    //         "blinking": "on",
272    "blinking": "terminal_controlled",
273    // Set whether Alternate Scroll mode (code: ?1007) is active by default.
274    // Alternate Scroll mode converts mouse scroll events into up / down key
275    // presses when in the alternate screen (e.g. when running applications
276    // like vim or  less). The terminal can still set and unset this mode.
277    // May take 2 values:
278    //  1. Default alternate scroll mode to on
279    //         "alternate_scroll": "on",
280    //  2. Default alternate scroll mode to off
281    //         "alternate_scroll": "off",
282    "alternate_scroll": "off",
283    // Set whether the option key behaves as the meta key.
284    // May take 2 values:
285    //  1. Rely on default platform handling of option key, on macOS
286    //     this means generating certain unicode characters
287    //         "option_to_meta": false,
288    //  2. Make the option keys behave as a 'meta' key, e.g. for emacs
289    //         "option_to_meta": true,
290    "option_as_meta": false,
291    // Whether or not selecting text in the terminal will automatically
292    // copy to the system clipboard.
293    "copy_on_select": false,
294    // Any key-value pairs added to this list will be added to the terminal's
295    // environment. Use `:` to separate multiple values.
296    "env": {
297      // "KEY": "value1:value2"
298    },
299    // Set the terminal's line height.
300    // May take 3 values:
301    //  1. Use a line height that's comfortable for reading, 1.618
302    //         "line_height": "comfortable"
303    //  2. Use a standard line height, 1.3. This option is useful for TUIs,
304    //      particularly if they use box characters
305    //         "line_height": "standard",
306    //  3. Use a custom line height.
307    //         "line_height": {
308    //           "custom": 2
309    //         },
310    "line_height": "comfortable"
311    // Set the terminal's font size. If this option is not included,
312    // the terminal will default to matching the buffer's font size.
313    // "font_size": "15"
314    // Set the terminal's font family. If this option is not included,
315    // the terminal will default to matching the buffer's font family.
316    // "font_family": "Zed Mono"
317  },
318  // Difference settings for vector_store
319  "vector_store": {
320    "enabled": false,
321    "reindexing_delay_seconds": 600
322  },
323  // Different settings for specific languages.
324  "languages": {
325    "Plain Text": {
326      "soft_wrap": "preferred_line_length"
327    },
328    "Elixir": {
329      "tab_size": 2
330    },
331    "Go": {
332      "tab_size": 4,
333      "hard_tabs": true
334    },
335    "Markdown": {
336      "soft_wrap": "preferred_line_length"
337    },
338    "JavaScript": {
339      "tab_size": 2
340    },
341    "TypeScript": {
342      "tab_size": 2
343    },
344    "TSX": {
345      "tab_size": 2
346    },
347    "YAML": {
348      "tab_size": 2
349    },
350    "JSON": {
351      "tab_size": 2
352    }
353  },
354  // LSP Specific settings.
355  "lsp": {
356    // Specify the LSP name as a key here.
357    // As of 8/10/22, supported LSPs are:
358    // pyright
359    // gopls
360    // rust-analyzer
361    // typescript-language-server
362    // vscode-json-languageserver
363    // "rust-analyzer": {
364    //     //These initialization options are merged into Zed's defaults
365    //     "initialization_options": {
366    //         "checkOnSave": {
367    //             "command": "clippy"
368    //         }
369    //     }
370    // }
371  }
372}