Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix use_on_type_format setting being unused per language #18387

Merged
merged 1 commit into from
Sep 26, 2024

Conversation

mrnugget
Copy link
Member

Before this change, use_on_type_format would only have an effect when defined on a global level in our settings.

But our default.json settings would also document that it's used in language settings, i.e.:

{
  "languages": {
    "C": {
      "use_on_type_format": false
    },
    "C++": {
      "use_on_type_format": false
    }
  }
}

But this did not work.

With the change, it now works globally and per-language.

Release Notes:

  • Fixed use_on_type_format setting not working when defined inside "languages" in the settings. This change will now change the default behavior for C, C++, and Markdown, by turning language server's OnTypeFormatting completions off by default.

Before this change, `use_on_type_format` would only have an effect when
defined on a global level in our settings.

But our default.json settings would also document that it's used in
language settings, i.e.:

```json
{
  "languages": {
    "C": {
      "use_on_type_format": false
    },
    "C++": {
      "use_on_type_format": false
    }
  }
}
```

But this did **not** work.

With the change, it now works globally and per-language.

Release Notes:

- Fixed `use_on_type_format` setting not working when defined inside
  `"languages"` in the settings. This change will now change the default
  behavior for C, C++, and Markdown, by turning language server's
  `OnTypeFormatting` completions off by default.

Co-authored-by: Bennet <bennet@zed.dev>
@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Sep 26, 2024
@mrnugget mrnugget merged commit 3f415f3 into main Sep 26, 2024
9 checks passed
@mrnugget mrnugget deleted the fix-use-on-type-format branch September 26, 2024 10:27
schpet added a commit to schpet/zed that referenced this pull request Sep 27, 2024
…reee

* origin/main:
  git blame gutter: Use smallest possible space (zed-industries#18145)
  Fix minimum gutter line number spacing (zed-industries#18021)
  terraform: Bump to v0.1.1 (zed-industries#18382)
  lsp: Do not notify all language servers on file save (zed-industries#17756)
  Remove leftover println statements (zed-industries#18389)
  Fix `use_on_type_format` setting being unused per language (zed-industries#18387)
  Avoid panic by only restoring workspace if UI has launched (zed-industries#18386)
  Fix Typo in rust language guide (zed-industries#18383)
  editor: Fix cursor shape not restoring when setting removed (zed-industries#18379)
  Avoid unwrap in file finder (zed-industries#18374)
noaccOS pushed a commit to noaccOS/zed that referenced this pull request Oct 19, 2024
…tries#18387)

Before this change, `use_on_type_format` would only have an effect when
defined on a global level in our settings.

But our default.json settings would also document that it's used in
language settings, i.e.:

```json
{
  "languages": {
    "C": {
      "use_on_type_format": false
    },
    "C++": {
      "use_on_type_format": false
    }
  }
}
```

But this did **not** work.

With the change, it now works globally and per-language.

Release Notes:

- Fixed `use_on_type_format` setting not working when defined inside
`"languages"` in the settings. This change will now change the default
behavior for C, C++, and Markdown, by turning language server's
`OnTypeFormatting` completions off by default.

Co-authored-by: Bennet <bennet@zed.dev>
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