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