Skip to content

settings: Extract project settings JSON schema#47939

Merged
dinocosta merged 2 commits intomainfrom
project-settings-json-schema
Jan 30, 2026
Merged

settings: Extract project settings JSON schema#47939
dinocosta merged 2 commits intomainfrom
project-settings-json-schema

Conversation

@dinocosta
Copy link
Copy Markdown
Member

Currently, the same JSON schema is used for both user settings, ~/.config/zed/settings.json, and project settings, .zed/settings.json, which can lead to confusion as not every setting is supported at the project level and will override the user-defined ones, for example, auto_update, telemetry, etc.

These changes add a project-specific JSON schema to be used when dealing with a project settings file, .zed/settings.json, so the JSON language server only suggests settings that are valid at the project level.

Release Notes:

  • Improved autocomplete for the project settings file (.zed/settings.json) to only include settings that are valid at the project level, excluding user-only settings.

Introduces a separate JSON schema for project settings that excludes
user-only settings like `auto_update`, `telemetry`, `vim_mode`, etc.
This provides more accurate autocomplete and validation when editing the
project-specific settings file, `.zed/settings.json`.

- Add `SettingsStore::project_json_schema`
- Map `.zed/settings.json` to `zed://schemas/project_settings` schema
  URL
Extract `SettingsStore::configure_schema_generator` helper to reduce
duplication between `SettingsStore.json_schema` and
`SettingsStore.project_json_schema`.

Both methods now share the common logic for language and LSP settings
schema replacements.
@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Jan 29, 2026
@maxdeviant maxdeviant changed the title settings: Extract project settings json schema settings: Extract project settings JSON schema Jan 29, 2026
@dinocosta dinocosta merged commit b029238 into main Jan 30, 2026
30 checks passed
@dinocosta dinocosta deleted the project-settings-json-schema branch January 30, 2026 18:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed The user has signed the Contributor License Agreement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant