zed/crates/language
Kyle Kelley 74e747a6c7
repl: Support kernel language aliases in REPL (#49762)
Add a `kernel_language_names` field to `LanguageConfig` that allows
languages to declare alternative names that Jupyter kernels may use.
This fixes REPL matching for cases where a kernel reports a different
language identifier than Zed's language name.

For example, the Nu extension would set `kernel_language_names =
["nushell", "nu"]` in its config.toml, enabling REPL support for
nu-jupyter-kernel which reports `"language": "nushell"` in its
kernelspec.

The change consolidates kernel language matching logic into a single
`Language::matches_kernel_language()` method that checks the code fence
block name, language name, and the new aliases list (all
case-insensitive).

- [x] Done a self-review taking into account security and performance
aspects

Release Notes:

- Added `kernel_language_names` field for extensions to self identify
REPL mappings
2026-03-04 11:58:51 -06:00
..
src repl: Support kernel language aliases in REPL (#49762) 2026-03-04 11:58:51 -06:00
build.rs Fix context line handline in project diagnostic view 2021-12-21 11:46:47 -08:00
Cargo.toml ztracing: Enable memory profiling and callstack sampling (#47052) 2026-01-17 19:29:19 +00:00
LICENSE-GPL chore: Change AGPL-licensed crates to GPL (except for collab) (#4231) 2024-01-24 00:26:58 +01:00