Commit Graph

257 Commits

Author SHA1 Message Date
Fabien Salathe
79d8b97531
Add more PHP keywords (#16720)
Release Notes:

- Improved PHP highlights by adding more language keywords
2024-08-23 09:51:07 +03:00
Thorsten Ball
59dd7c9138
zig: Bump to v0.3.0 (#16669)
This PR bumps the Zig extension to v0.3.0

Changes:

- #16645

Release Notes:

- N/A
2024-08-22 15:56:09 +02:00
versecafe
bb725d3158
zig: Unpin Zig LSP grab newest version off GH releases, and download from zigtools.org (#16645)
Fixed Zig LSP being pinned to 0.11.0 due to discontinuation of `.tar.gz`

Release Notes:

- N/A
2024-08-22 15:45:04 +02:00
Marshall Bowers
77c08fade5
elixir: Bump to v0.0.8 (#16495)
This PR bumps the Elixir extension to v0.0.8.

Changes:

- #16382

Release Notes:

- N/A
2024-08-19 19:15:41 -04:00
Stanislav Alekseev
8993a9f2ee
elixir: Make two more files required by lexical executable (#16382)
I still haven't fixed building dev extensions with rust managed by nix,
so I'd appreciate testing this for me

Release Notes:

- N/A
2024-08-19 18:48:05 -04:00
Nathan Sobo
43e13df9f3
Add a /perplexity slash command in an extension (#16438)
Release Notes:

- N/A
2024-08-18 16:34:55 -06:00
Marshall Bowers
cb423bcb6f
Remove tooltip_text from extension manifests (#16312)
This PR removes the `tooltip_text` from the extension manifests.

We stopped reading this value in #16306, as it wasn't being used, so we
don't need to include it in the manifest anymore.

Release Notes:

- N/A
2024-08-15 15:54:53 -04:00
Marshall Bowers
5a30e29848
Add example extension to showcase slash commands (#16300)
This PR adds an example extension to showcase how to write slash
commands in an extension.

Release Notes:

- N/A
2024-08-15 12:26:13 -04:00
Marshall Bowers
1117d89057
zig: Bump to v0.2.0 (#16261)
This PR bumps the Zig extension to v0.2.0.

Changes:

- https://github.com/zed-industries/zed/pull/16260

Release Notes:

- N/A
2024-08-14 18:57:43 -04:00
Marshall Bowers
0df4d12234
zig: Upgrade zed_extension_api to v0.1.0 (#16260)
This PR updates the Zig extension to use v0.1.0 of the Zed extension
API.

This allows us to pin ZLS to v0.11.0, as the more recent releases of ZLS
don't have `.tar.gz` assets available.

Release Notes:

- N/A
2024-08-14 18:40:27 -04:00
Marshall Bowers
a6461f90a1
gleam: Bump to v0.2.0 (#16258)
This PR bumps the Gleam extension to v0.2.0.

Changes:

- Added `/gleam-project` slash command
- Added `gleam-hexdocs` provider for the `/docs` slash command
- https://github.com/zed-industries/zed/pull/12221
- https://github.com/zed-industries/zed/pull/15659

Release Notes:

- N/A
2024-08-14 18:14:19 -04:00
Marshall Bowers
2e1750d5e2
gleam: Switch to published version of zed_extension_api (#16256)
This PR updates the Gleam extension to use the published version of the
`zed_extension_api`.

Release Notes:

- N/A
2024-08-14 18:04:05 -04:00
Marshall Bowers
6365000b68
gleam: Clean up slash commands in preparation for release (#16232)
This PR cleans up the slash command functionality in preparation for an
upcoming release:

- Removed arguments to `/gleam-project` that were just used as an
example
- Removed `/gleam-docs` in favor of `/docs` with the `gleam-hexdocs`
provider
- Pulled a list of all Gleam packages to use as suggestions

Release Notes:

- N/A
2024-08-14 12:22:22 -04:00
Marshall Bowers
340a1d145e
haskell: Bump to v0.1.1 (#16228)
This PR bumps the Haskell extension to v0.1.1.

Changes:

- https://github.com/zed-industries/zed/pull/13268
- https://github.com/zed-industries/zed/pull/15998

Release Notes:

- N/A
2024-08-14 11:57:47 -04:00
Thanabodee Charoenpiriyakij
f5532afaa7
erlang: Update tree-sitter grammar and query files (#15973)
Hi, I bump the tree-sitter-erlang to a newest version and sync the
hightlight query to fix long standing issue in the Zed erlang extension
about incorrect function highlighting, not support the triple quote
string and many more.

Release Notes:

- N/A

Signed-off-by: Thanabodee Charoenpiriyakij <wingyminus@gmail.com>
2024-08-14 11:07:54 -04:00
Kirill Bulatov
8fe2de1737
Further improve /tabs command and slash arguments completion (#16216)
* renames `/tabs` to `/tab`
* allows to insert multiple tabs when fuzzy matching by the names
* improve slash command completion API, introduce a notion of multiple
arguments
* properly fire off commands on arguments' completions with
`run_command: true`

Release Notes:

- N/A

---------

Co-authored-by: Marshall Bowers <marshall@zed.dev>
2024-08-14 17:11:51 +03:00
Marshall Bowers
aa12ae0e3c
Allow extensions to suggest packages for /docs completions (#16185)
This PR gives extensions the ability to suggest packages to show up in
`/docs` completions by default.

Release Notes:

- N/A
2024-08-13 16:50:57 -04:00
Marshall Bowers
8a9c58e515
zed_extension_api: Add HttpRequestBuilder (#16165)
This PR adds an `HttpRequestBuilder` to the extension API to allow for a
more ergonomic way for constructing HTTP requests within extensions.

The HTTP client functionality is now also exposed via the
`zed_extension_api::http_client` module instead of top-level.

Release Notes:

- N/A
2024-08-13 11:12:10 -04:00
Marshall Bowers
4450ebff6b
Allow extensions to control the redirect policy for the HTTP client (#16162)
This PR extends the extension API with support for controlling the
redirect policy used by the HTTP client.

Release Notes:

- N/A
2024-08-13 10:40:21 -04:00
Stanislav Alekseev
f956257638
haskell: Pass environment to hls (#15998)
Fixed environment not being passed to hls, breaking local nix-based
installations

Release Notes:

- N/A
2024-08-12 18:38:23 -04:00
Nathan Sobo
fc64843dd5
Enhance HTTP API for extensions (#16067)
# HTTP Client Improvements for Extension API

This PR enhances the HTTP client functionality in the Zed extension API,
providing more control over requests and allowing for streaming
responses.

## Key Changes

1. Extended `HttpRequest` struct:
   - Added `method` field to specify HTTP method
   - Added `headers` field for custom headers
   - Added optional `body` field for request payload

2. Introduced `HttpMethod` enum for supported HTTP methods

3. Updated `HttpResponse` struct:
   - Added `headers` field to access response headers
- Changed `body` type from `String` to `Vec<u8>` for binary data support

4. Added streaming support:
   - New `fetch_stream` function to get a response stream
   - Introduced `HttpResponseStream` resource for chunked reading

5. Updated internal implementations to support these new features

6. Modified the Gleam extension to use the new API structure

## Motivation

These changes provide extension developers with more flexibility and
control over HTTP requests. The streaming support is particularly useful
for handling large responses efficiently or ideally streaming into the
UI.

## Testing

- [x] Updated existing tests
- [ ] Added new tests for streaming functionality

## Next Steps

- Consider adding more comprehensive examples in the documentation
- Evaluate performance impact of streaming for large responses

Please review and let me know if any adjustments are needed.

Release Notes:

- N/A

---------

Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
2024-08-12 10:36:49 -04:00
Jonathan Dickinson
864c443f4b
csharp: Use lsp settings to locate binary if present (#15885)
C# extension now honors the "lsp" config section

Release Notes:

- N/A

---------

Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
2024-08-07 10:58:13 -04:00
Marshall Bowers
5ce6c374b0
gleam: Revert version bump (#15908)
This PR reverts a version bump to the Gleam extension that was included
in #15866, as we're not ready to publish a new version.

Release Notes:

- N/A
2024-08-07 10:27:34 -04:00
Piotr Osiewicz
2db2b636f2
assistant: Add annotations to more languages (#15866)
Release Notes:

- N/A
2024-08-07 13:47:21 +02:00
Xander
4f69336024
php: Add bracket highlighting (#15881)
Improved PHP extension by adding bracket highlighting 

Release Notes:

- N/A

Screenshot: 
<img width="402" alt="image"
src="https://github.com/user-attachments/assets/4dd02b41-8637-49b8-b3ce-41791227f945">

<img width="537" alt="image"
src="https://github.com/user-attachments/assets/b6dc7091-4588-460b-9051-4675eb0df538">
2024-08-06 17:36:40 -04:00
Marshall Bowers
591b579ccf
elixir: Bump to v0.0.7 (#15867)
This PR bumps the Elixir extension to v0.0.7.

Changes:

- #14831

Release Notes:

- N/A
2024-08-06 13:07:47 -04:00
Vitaly Slobodin
889a14a2c2
ruby: Bump to v0.1.0 (#15855)
ruby: Bump extension version to v0.1.0 Why not v0.0.9? I think the Ruby
extension is mature, and it's time to release the first minor version.
But I am totally OK with changing it to 0.0.9.

Included changes:

- https://github.com/zed-industries/zed/pull/15778
- https://github.com/zed-industries/zed/pull/15762
- https://github.com/zed-industries/zed/pull/15110
- https://github.com/zed-industries/zed/pull/15297

Release Notes:

- N/A

---------

Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
2024-08-06 09:53:02 -04:00
Marshall Bowers
a054a2a9a3
ruff: Refactor language server loading (#15852)
This PR refactors the language server loading in the Ruff extension to
mirror our other extensions.

Also fixed an issue where the cached binary path was not being
respected.

Release Notes:

- N/A
2024-08-06 09:10:18 -04:00
Vitaly Slobodin
1c3f303594
ruby: Support "binary" settings for Rubocop and Solargraph (#15110)
Hello, this pull request adds support for specifying and using the
"binary" settings for Rubocop and Solargraph LSPs. AFAIK, Ruby LSP does
not require the bundler context but that could be added later easily.

In Ruby world, like in Node.js world, almost all
projects rely on project specific packages (gems) and their versions.
Solargraph and Rubocop gems are usually installed as project
dependencies. Attempting to use global installation of them fail in most
cases due to incompatible or missing dependencies (gems).

To avoid that, Ruby engineers have the `bundler`
gem that provides the `exec` command. This command executes the given
command in the context of the bundle.

This pull request adds support for pulling the `binary` settings to use
them in starting both LSPs. For instance, to start the Solargraph gem in
the context of the bundler, the end user must configure the binary
settings in the folder-specific settings file like so:

```json
{
  "lsp": {
    "solargraph": {
      "binary": {
        "path": "/Users/vslobodin/Development/festivatica/bin/rubocop"
      }
    }
  }
}
```

The `path` key must be an absolute path to the `binstub` of the
`solargraph` gem. The same applies to the "rubocop" gem. Side note but
it would be awesome to use Zed specific environment variables to make
this a bit easier. For instance, we could use the `ZED_WORKTREE_ROOT`
environment variable:

```json
{
  "lsp": {
    "solargraph": {
      "binary": {
        "path": "${ZED_WORKTREE_ROOT}/bin/rubocop"
      }
    }
  }
}
```

But this is out of the scope of this pull request. The code is a bit
messy and repeatable in some places, I am happy to improve it here or
later.

References:
- https://bundler.io/v2.4/man/bundle-exec.1.html
- https://solargraph.org/guides/troubleshooting
- https://bundler.io/v2.5/man/bundle-binstubs.1.html

This pull request is based on these two pull requests:

- https://github.com/zed-industries/zed/pull/14655
- https://github.com/zed-industries/zed/issues/15001

Closes https://github.com/zed-industries/zed/issues/5109.

Release Notes:

- N/A

---------

Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
2024-08-06 08:36:14 -04:00
Vitaly Slobodin
45afe9dffa
ruby: Add support for *.rbs files (#15778)
Hi, this pull request adds support for RBS files for the Ruby language.
[RBS](https://github.com/ruby/rbs) is a language to describe the
structure of Ruby programs.

This pull request:

- adds a new grammar to the Ruby extension for RBS
https://github.com/joker1007/tree-sitter-rbs
- configures the Ruby extension to use the added grammar.

Release Notes:

- N/A
2024-08-06 09:51:44 +02:00
Reese is on Codeberg
49e736d8ef
ruby: Recognize Steepfiles as Ruby (#15762)
Release Notes:

- N/A
2024-08-04 11:57:34 -04:00
Joseph T Lyons
35a3b00255 Add link to docs for configuring ruff 2024-08-02 11:06:01 -04:00
Marshall Bowers
906d9736d5
gleam: Update Tree-sitter grammar for label shorthand syntax (#15659)
This PR updates the Gleam Tree-sitter grammar to support label shorthand
syntax.

Release Notes:

- N/A
2024-08-01 17:46:23 -04:00
Marshall Bowers
771424e4f9
extension: Make worktree argument to run_slash_command optional (#15658)
This PR updates the extension API to make the `worktree` argument to
`run_slash_command` optional.

We may not always have a worktree, and not all slash commands need them,
so by making it optional we can allow individual slash commands to
decide what to do when there is no worktree.

Release Notes:

- N/A
2024-08-01 17:34:44 -04:00
Vitaly Slobodin
769ae8b101
ruby: Adjust language servers languages (#15297)
Hi. This is a small pull request that changes the "language" field to
the "languages" field
because the `language` field is deprecated.
Additionally, allow the Ruby LSP to run in `*.erb` files.

Release Notes:

- N/A
2024-07-26 15:58:50 -04:00
Marshall Bowers
fe23504eba
uiua: Upgrade zed_extension_api to v0.0.6 (#15240)
This PR upgrades the Uiua extension to use v0.0.6 of the
`zed_extension_api`.

Release Notes:

- N/A
2024-07-25 20:43:15 -04:00
Marshall Bowers
f31c55a76f
zig: Bump to v0.1.5 (#15203)
This PR bumps the Zig extension to v0.1.5.

Changes:

- #15197

Release Notes:

- N/A
2024-07-25 11:36:50 -04:00
Uberlicious
cd9dd5ccf7
zig: Add Windows support (#15197)
Release Notes:

- N/A

Currently Windows environments do not have a `shell_env`. This causes
the Zig extension to error when trying to call `worktree.shell_env()`
since extensions api isn't yet on `0.0.7` and thus not using wasm-host
`0.0.7` we need to only call for the shell env only on non-windows
systems. 0.0.7 and onward at the moment return a Result from
`shell_env()`. The binary path is also slightly different on windows.

---------

Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
2024-07-25 11:30:02 -04:00
Marshall Bowers
8ba392bba6
purescript: Upgrade zed_extension_api to v0.0.6 (#15181)
This PR upgrades the PureScript extension to use v0.0.6 of the
`zed_extension_api`.

Release Notes:

- N/A
2024-07-25 08:55:16 -04:00
Marshall Bowers
fbbea7ab01
prisma: Upgrade zed_extension_api to v0.0.6 (#15180)
This PR upgrades the Prisma extension to use v0.0.6 of the
`zed_extension_api`.

Release Notes:

- N/A
2024-07-25 08:46:17 -04:00
Marshall Bowers
aded3dfb05
emmet: Upgrade zed_extension_api to v0.0.6 (#15177)
This PR upgrades the Emmet extension to use v0.0.6 of the
`zed_extension_api`.

Release Notes:

- N/A
2024-07-25 08:34:45 -04:00
Marshall Bowers
3053f98652
csharp: Upgrade zed_extension_api to v0.0.6 (#15175)
This PR upgrades the C# extension to use v0.0.6 of the
`zed_extension_api`.

Release Notes:

- N/A
2024-07-25 08:26:04 -04:00
Marshall Bowers
5e44f5fa44
terraform: Bump to v0.0.4 (#15174)
This PR bumps the Terraform extension to v0.0.4.

Changes:

- #10937
- #15171

Release Notes:

- N/A
2024-07-25 08:22:28 -04:00
Marshall Bowers
a07122d78f
deno: Bump to v0.0.2 (#15173)
This PR bumps the Deno extension to v0.0.2.

Changes:

- #14410

Release Notes:

- N/A
2024-07-25 08:19:43 -04:00
Marshall Bowers
6a079cbdc3
astro: Bump to v0.1.0 (#15172)
This PR bumps the Astro extension to v0.1.0.

Changes:

- #14849
- #15010
- #15011

Release Notes:

- N/A
2024-07-25 08:16:28 -04:00
Marshall Bowers
c7e2d5bd89
terraform: Make downloaded language server binary executable (#15171)
This PR updates the Terraform extension to make the downloaded language
server binary executable.

Resolves #14502.

Release Notes:

- N/A
2024-07-25 08:08:38 -04:00
Fabian
a0d687c24a
astro: Ensure Typescript is present (#14849)
The current Astro Extension fails to load properly if it can't find a
`tsserver.js` file in the current workspaces' `node_modules` folder.
This happens pretty frequently, either if `typescript` is not installed
in the project (which it isn't by default), or if `node_modules` is not
in the workspace root.

This PR adds a fallback method of installing `typescript` alongside the
extensions' language server if it is not found in the workspaces'
`node_modules`, as well as correctly setting the `tsdk` path in the
initialization options.

Release Notes:

- N/A

---------

Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
2024-07-23 10:39:25 -04:00
Marshall Bowers
5f57efb266
astro: Align version numbers in extension.toml and Cargo.toml (#15011)
This PR aligns the version numbers in `extension.toml` and `Cargo.toml`
for the Astro extension, as they had gotten out-of-sync.

Release Notes:

- N/A
2024-07-23 10:28:09 -04:00
Marshall Bowers
6398b45084
astro: Upgrade zed_extension_api to v0.0.6 (#15010)
This PR upgrades the Astro extension to use v0.0.6 of the
`zed_extension_api`.

Release Notes:

- N/A
2024-07-23 10:12:40 -04:00
Piotr Osiewicz
5d77a7dc6c
Ruff: Do not pass --preview flag, respect binary settings (#15001)
Bumps version to 0.0.2 as well.

Release Notes:

- N/A
2024-07-23 09:57:42 +02:00