default.json

  1{
  2    // The name of the Zed theme to use for the UI
  3    "theme": "One Dark",
  4    // The name of a font to use for rendering text in the editor
  5    "buffer_font_family": "Zed Mono",
  6    // The default font size for text in the editor
  7    "buffer_font_size": 15,
  8    // The factor to grow the active pane by. Defaults to 1.0
  9    // which gives the same size as all other panes.
 10    "active_pane_magnification": 1.0,
 11    // Whether to enable vim modes and key bindings
 12    "vim_mode": false,
 13    // Whether to show the informational hover box when moving the mouse
 14    // over symbols in the editor.
 15    "hover_popover_enabled": true,
 16    // Whether to confirm before quitting Zed.
 17    "confirm_quit": false,
 18    // Whether the cursor blinks in the editor.
 19    "cursor_blink": true,
 20    // Whether to pop the completions menu while typing in an editor without
 21    // explicitly requesting it.
 22    "show_completions_on_input": true,
 23    // Whether the screen sharing icon is showed in the os status bar.
 24    "show_call_status_icon": true,
 25    // Whether new projects should start out 'online'. Online projects
 26    // appear in the contacts panel under your name, so that your contacts
 27    // can see which projects you are working on. Regardless of this
 28    // setting, projects keep their last online status when you reopen them.
 29    "projects_online_by_default": true,
 30    // Whether to use language servers to provide code intelligence.
 31    "enable_language_server": true,
 32    // When to automatically save edited buffers. This setting can
 33    // take four values.
 34    //
 35    // 1. Never automatically save:
 36    //     "autosave": "off",
 37    // 2. Save when changing focus away from the Zed window:
 38    //     "autosave": "on_window_change",
 39    // 3. Save when changing focus away from a specific buffer:
 40    //     "autosave": "on_focus_change",
 41    // 4. Save when idle for a certain amount of time:
 42    //     "autosave": { "after_delay": {"milliseconds": 500} },
 43    "autosave": "off",
 44    // Where to place the dock by default. This setting can take three
 45    // values:
 46    //
 47    // 1. Position the dock attached to the bottom of the workspace
 48    //     "default_dock_anchor": "bottom"
 49    // 2. Position the dock to the right of the workspace like a side panel
 50    //     "default_dock_anchor": "right"
 51    // 3. Position the dock full screen over the entire workspace"
 52    //     "default_dock_anchor": "expanded"
 53    "default_dock_anchor": "right",
 54    // Whether or not to remove trailing whitespace from lines before saving.
 55    "remove_trailing_whitespace_on_save": true,
 56    // Whether or not to perform a buffer format before saving
 57    "format_on_save": "on",
 58    // How to perform a buffer format. This setting can take two values:
 59    //
 60    // 1. Format code using the current language server:
 61    //     "format_on_save": "language_server"
 62    // 2. Format code using an external command:
 63    //     "format_on_save": {
 64    //       "external": {
 65    //         "command": "prettier",
 66    //         "arguments": ["--stdin-filepath", "{buffer_path}"]
 67    //       }
 68    //     }
 69    "formatter": "language_server",
 70    // How to soft-wrap long lines of text. This setting can take
 71    // three values:
 72    //
 73    // 1. Do not soft wrap.
 74    //      "soft_wrap": "none",
 75    // 2. Soft wrap lines that overflow the editor:
 76    //      "soft_wrap": "editor_width",
 77    // 3. Soft wrap lines at the preferred line length
 78    //      "soft_wrap": "preferred_line_length",
 79    "soft_wrap": "none",
 80    // The column at which to soft-wrap lines, for buffers where soft-wrap
 81    // is enabled.
 82    "preferred_line_length": 80,
 83    // Whether to indent lines using tab characters, as opposed to multiple
 84    // spaces.
 85    "hard_tabs": false,
 86    // How many columns a tab should occupy.
 87    "tab_size": 4,
 88    // Control what info is collected by Zed.
 89    "telemetry": {
 90        // Send debug info like crash reports.
 91        "diagnostics": true,
 92        // Send anonymized usage data like what languages you're using Zed with.
 93        "metrics": true
 94    },
 95    // Automatically update Zed
 96    "auto_update": true,
 97    // Git gutter behavior configuration.
 98    "git": {
 99        // Control whether the git gutter is shown. May take 2 values:
100        // 1. Show the gutter
101        //      "git_gutter": "tracked_files"
102        // 2. Hide the gutter
103        //      "git_gutter": "hide"
104        "git_gutter": "tracked_files"
105    },
106    // Settings specific to journaling
107    "journal": {
108        // The path of the directory where journal entries are stored
109        "path": "~",
110        // What format to display the hours in
111        // May take 2 values:
112        // 1. hour12
113        // 2. hour24
114        "hour_format": "hour12"
115    },
116    // Settings specific to the terminal
117    "terminal": {
118        // What shell to use when opening a terminal. May take 3 values:
119        // 1. Use the system's default terminal configuration (e.g. $TERM).
120        //      "shell": "system"
121        // 2. A program:
122        //      "shell": {
123        //        "program": "sh"
124        //      }
125        // 3. A program with arguments:
126        //     "shell": {
127        //         "with_arguments": {
128        //           "program": "/bin/bash",
129        //           "arguments": ["--login"]
130        //         }
131        //     }
132        "shell": "system",
133        // What working directory to use when launching the terminal.
134        // May take 4 values:
135        // 1. Use the current file's project directory.  Will Fallback to the
136        //    first project directory strategy if unsuccessful
137        //      "working_directory": "current_project_directory"
138        // 2. Use the first project in this workspace's directory
139        //      "working_directory": "first_project_directory"
140        // 3. Always use this platform's home directory (if we can find it)
141        //     "working_directory": "always_home"
142        // 4. Always use a specific directory. This value will be shell expanded.
143        //    If this path is not a valid directory the terminal will default to
144        //    this platform's home directory  (if we can find it)
145        //      "working_directory": {
146        //        "always": {
147        //          "directory": "~/zed/projects/"
148        //        }
149        //      }
150        //
151        //
152        "working_directory": "current_project_directory",
153        // Set the cursor blinking behavior in the terminal.
154        // May take 4 values:
155        //  1. Never blink the cursor, ignoring the terminal mode
156        //         "blinking": "off",
157        //  2. Default the cursor blink to off, but allow the terminal to
158        //     set blinking
159        //         "blinking": "terminal_controlled",
160        //  3. Always blink the cursor, ignoring the terminal mode
161        //         "blinking": "on",
162        "blinking": "terminal_controlled",
163        // Set whether Alternate Scroll mode (code: ?1007) is active by default.
164        // Alternate Scroll mode converts mouse scroll events into up / down key
165        // presses when in the alternate screen (e.g. when running applications
166        // like vim or  less). The terminal can still set and unset this mode.
167        // May take 2 values:
168        //  1. Default alternate scroll mode to on
169        //         "alternate_scroll": "on",
170        //  2. Default alternate scroll mode to off
171        //         "alternate_scroll": "off",
172        "alternate_scroll": "off",
173        // Set whether the option key behaves as the meta key.
174        // May take 2 values:
175        //  1. Rely on default platform handling of option key, on macOS
176        //     this means generating certain unicode characters
177        //         "option_to_meta": false,
178        //  2. Make the option keys behave as a 'meta' key, e.g. for emacs
179        //         "option_to_meta": true,
180        "option_as_meta": false,
181        // Whether or not selecting text in the terminal will automatically
182        // copy to the system clipboard.
183        "copy_on_select": false,
184        // Any key-value pairs added to this list will be added to the terminal's
185        // enviroment. Use `:` to seperate multiple values.
186        "env": {
187            // "KEY": "value1:value2"
188        }
189        // Set the terminal's font size. If this option is not included,
190        // the terminal will default to matching the buffer's font size.
191        // "font_size": "15"
192        // Set the terminal's font family. If this option is not included,
193        // the terminal will default to matching the buffer's font family.
194        // "font_family": "Zed Mono"
195    },
196    // Different settings for specific languages.
197    "languages": {
198        "Plain Text": {
199            "soft_wrap": "preferred_line_length"
200        },
201        "C": {
202            "tab_size": 2
203        },
204        "C++": {
205            "tab_size": 2
206        },
207        "Elixir": {
208            "tab_size": 2
209        },
210        "Go": {
211            "tab_size": 4,
212            "hard_tabs": true
213        },
214        "Markdown": {
215            "soft_wrap": "preferred_line_length"
216        },
217        "Rust": {
218            "tab_size": 4
219        },
220        "JavaScript": {
221            "tab_size": 2
222        },
223        "TypeScript": {
224            "tab_size": 2
225        },
226        "TSX": {
227            "tab_size": 2
228        },
229        "YAML": {
230            "tab_size": 2
231        }
232    },
233    // LSP Specific settings.
234    "lsp": {
235        // Specify the LSP name as a key here.
236        // As of 8/10/22, supported LSPs are:
237        // pyright
238        // gopls
239        // rust-analyzer
240        // typescript-language-server
241        // vscode-json-languageserver
242        // "rust-analyzer": {
243        //     //These initialization options are merged into Zed's defaults
244        //     "initialization_options": {
245        //         "checkOnSave": {
246        //             "command": "clippy"
247        //         }
248        //     }
249        // }
250    }
251}