ZIm/crates/vim/src
Marshall Bowers 7c5bc3c26f
Add the ability for extensions to provide language settings (#10296)
This PR adds the ability for extensions to provide certain language
settings via the language `config.toml`.

These settings are then merged in with the rest of the settings when the
language is loaded from the extension.

The language settings that are available are:

- `tab_size`
- `hard_tabs`
- `soft_wrap`

Additionally, for bundled languages we moved these settings out of the
`settings/default.json` and into their respective `config.toml`s .

For languages currently provided by extensions, we are leaving the
values in the `settings/default.json` temporarily until all released
versions of Zed are able to load these settings from the extension.

---

Along the way we ended up refactoring the `Settings::load` method
slightly, introducing a new `SettingsSources` struct to better convey
where the settings are being loaded from.

This makes it easier to load settings from specific locations/sets of
locations in an explicit way.

Release Notes:

- N/A

---------

Co-authored-by: Max <max@zed.dev>
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2024-04-08 19:17:12 -04:00
..
normal vim: Allow search with operators & visual mode (#10226) 2024-04-08 15:20:14 -06:00
test Fix assorted linux issues (#10061) 2024-04-01 17:22:59 -07:00
command.rs Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
editor_events.rs vim: Allow search with operators & visual mode (#10226) 2024-04-08 15:20:14 -06:00
insert.rs vim: Keep multi-cursor on escape (#8464) 2024-02-26 22:54:02 -07:00
mode_indicator.rs vim: Fix some problems with visual mode testing (#8461) 2024-02-26 20:15:27 -07:00
motion.rs vim: Allow search with operators & visual mode (#10226) 2024-04-08 15:20:14 -06:00
normal.rs Add surrounds support for vim (#9400) 2024-04-08 11:41:06 -06:00
object.rs Add surrounds support for vim (#9400) 2024-04-08 11:41:06 -06:00
replace.rs Fix undo in replace mode (#10086) 2024-04-03 11:35:04 -06:00
state.rs vim: Allow search with operators & visual mode (#10226) 2024-04-08 15:20:14 -06:00
surrounds.rs vim: Allow search with operators & visual mode (#10226) 2024-04-08 15:20:14 -06:00
test.rs Fix panic in visual line mode with folds (#10284) 2024-04-08 11:39:06 -06:00
utils.rs Compute scrollbar markers asynchronously (#10080) 2024-04-03 12:21:17 +02:00
vim.rs Add the ability for extensions to provide language settings (#10296) 2024-04-08 19:17:12 -04:00
visual.rs vim: Fix cgn backwards movement when there is no matches (#10237) 2024-04-08 14:51:36 -06:00