Commit Graph

20962 Commits

Author SHA1 Message Date
Kyle Kelley
6dfb0a4a70
repl: Push button to clear outputs (#14873) 2024-07-20 11:32:03 -07:00
claytonrcarter
a1670551bf
Fix description of -l flag in bundle-mac (#14864)
This removes mention of "copy bundle to `/Applications`" from the help
text for `bundle-mac` because, as far as I can tell, the `-l` flag only
controls the build, not the copy/install. (The copy/install is
controlled by using the `-i` flag in conjunction with `-l`.)


Release Notes:

- N/A
2024-07-20 19:16:54 +03:00
Piotr Osiewicz
71cbfc65b1
Ruff: pass initialization_options from settings (#14866)
No version bump, as the extension is not out yet.
Release Notes:

- N/A
2024-07-20 16:09:53 +02:00
Piotr Osiewicz
1218a846c1
extensions: Add Ruff extension (#14198)
Release Notes:

- Added extension for [Ruff](https://docs.astral.sh/ruff/), an extremely fast Python linter and code formatter, written in Rust.
2024-07-20 15:18:02 +02:00
versecafe
48c253feb8
Expand terminal menu actions (#14828)
<img width="422" alt="image"
src="https://github.com/user-attachments/assets/73195894-81a7-4b8e-b5cf-ae60bf5b1fb9">

Release Notes:

- Added `Copy`, `Paste`, `Select All`, & `New Terminal` into terminal's context menu
2024-07-20 12:20:53 +03:00
Kevin Wang
46b7fa9bcb
Add Sign Out link for Supermaven (#14834)
Adds a menu item to sign out from a linked Supermaven account.


![image](https://github.com/user-attachments/assets/6af3c39f-9ca4-4ac2-a5c0-c7cb3c3aaac2)


Release Notes:

- Added the ability to sign out of a Supermaven account ([#12715(https://github.com/zed-industries/zed/issues/12715))
2024-07-20 03:53:24 +03:00
Max Brunsfeld
022e662815 Start work on showing progress when initializing ssh remoting 2024-07-19 17:25:28 -07:00
Max Brunsfeld
d89e2592a1
Fix file name conflict when downloading app update (#14847)
This fixes broken auto-updates on nightly. Unfortunately, nightly users
will need to re-download.

Release Notes:

- N/A
2024-07-19 16:33:41 -07:00
Fabian
a072caab0b
node_runtime: Bump downloaded Node.js version to Current (Jod) (#14687)
This PR bumps the hard-coded Node.js version from v18.x (Hydrogen), which was LTS until October 2023, to v22.x (Jod) which will be the next LTS release in October 2024.

Release Notes:

- Updated Zed's node version (v18.x -> v22.x)
2024-07-20 01:18:56 +03:00
Max Brunsfeld
fbe30c6f2e
Fixes for SSH remoting infrastructure (#14844)
* Fixed mis-named macOS remote server archives in actions and packaging
scripts
* Fixed an issue with the ask pass script on linux
* Download nightly versions of remote servers in dev mode (not stable)

Release Notes:

- N/A
2024-07-19 15:08:10 -07:00
Marshall Bowers
a5b8094082
editor: Implement From instead of Into for converting BlockIds to ElementIds (#14839)
This PR replaces the `Into<ElementId> for BlockId` implementation with
`From<BlockId> for ElementId`.

This keeps in line with Rust's guidance for preferring implementing
`From`, and gives us more flexibility when converting.

Release Notes:

- N/A
2024-07-19 16:24:12 -04:00
Conrad Irwin
d2efa12e16
vim: Fix gv after actions (#14829)
Fixes: #13720

Co-Authored-By: <tobbe@tlundberg.com>



Release Notes:

- vim: Fixed `gv` after `y`, `d`, etc.
([#13760](https://github.com/zed-industries/zed/issues/13760)).
2024-07-19 13:26:55 -06:00
Marshall Bowers
5e635b8914
ui: Remove absolute positioning for tab slots (#14836)
This PR reworks the `Tab` component to not use absolute positioning in
order to position the tab slots.

This should make any further adjustments we want to make to the spacing
easier to do.

Release Notes:

- N/A
2024-07-19 15:11:27 -04:00
Jason Lee
0a02691778
Fix tooltips sometimes continuously displaying when the button is selected (#14832)
Release Notes:

- Fixed sometime tooltip will continuously display when the button is
selected.

---

@mrnugget The #13857 This change has led into a bug, the selected item
before tooltip will continuous display if there are no other tooltips.



https://github.com/user-attachments/assets/06b4a9a4-dede-4c18-b020-e20b6090341f
2024-07-19 12:49:08 -06:00
Conrad Irwin
1dc4d4200f
Add command aliases (#14826)
Co-Authored-By: <tobbe@tlundberg.com>

Release Notes:

- Added `"command_aliases"` setting to let you abbreviate commands
2024-07-19 12:48:48 -06:00
Max Brunsfeld
b22718e643 Fix log file path for dsymutil in bundle-mac 2024-07-19 11:35:31 -07:00
Max Brunsfeld
bc16c2f85d Fix error in bundle-mac 2024-07-19 11:22:46 -07:00
Max Brunsfeld
1805986d82 Suppress noisy output from dsymutil in bundle-mac 2024-07-19 11:22:46 -07:00
Marshall Bowers
ee0dfe9c44
elixir: Make start_lexical.sh executable (#14831)
This PR fixes an issue in the Lexical language server installation where
the `start_lexical.sh` script was not being made executable when
installed from GitHub.

Release Notes:

- N/A
2024-07-19 14:17:04 -04:00
Max Brunsfeld
f4074d784c Remove spurious self-hosted label for bundle-linux-arm job 2024-07-19 11:08:20 -07:00
Max Brunsfeld
e58db43ed8 Remove stray step from release nightly workflow 2024-07-19 10:49:34 -07:00
Richard Feldman
ec487d8f64
Extract completion provider crate (#14823)
We will soon need `semantic_index` to be able to use
`CompletionProvider`. This is currently impossible due to a cyclic crate
dependency, because `CompletionProvider` lives in the `assistant` crate,
which depends on `semantic_index`.

This PR breaks the dependency cycle by extracting two crates out of
`assistant`: `language_model` and `completion`.

Only one piece of logic changed: [this
code](922fcaf5a6 (diff-3857b3707687a4d585f1200eec4c34a7a079eae8d303b4ce5b4fce46234ace9fR61-R69)).
* As of https://github.com/zed-industries/zed/pull/13276, whenever we
ask a given completion provider for its available models, OpenAI
providers would go and ask the global assistant settings whether the
user had configured an `available_models` setting, and if so, return
that.
* This PR changes it so that instead of eagerly asking the assistant
settings for this info (the new crate must not depend on `assistant`, or
else the dependency cycle would be back), OpenAI completion providers
now store the user-configured settings as part of their struct, and
whenever the settings change, we update the provider.

In theory, this change should not change user-visible behavior...but
since it's the only change in this large PR that's more than just moving
code around, I'm mentioning it here in case there's an unexpected
regression in practice! (cc @amtoaer in case you'd like to try out this
branch and verify that the feature is still working the way you expect.)

Release Notes:

- N/A

---------

Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
2024-07-19 13:35:34 -04:00
Max Brunsfeld
b9a53ffa0b
Add the ability to edit remote directories over SSH (#14530)
This is a first step towards allowing you to edit remote projects
directly over SSH. We'll start with a pretty bare-bones feature set, and
incrementally add further features.

### Todo

Distribution
* [x] Build nightly releases of `zed-remote-server` binaries
    * [x] linux (arm + x86)
    * [x] mac (arm + x86)
* [x] Build stable + preview releases of `zed-remote-server`
* [x] download and cache remote server binaries as needed when opening
ssh project
* [x] ensure server has the latest version of the binary


Auth
* [x] allow specifying password at the command line
* [x] auth via ssh keys
* [x] UI password prompt

Features
* [x] upload remote server binary to server automatically
* [x] opening directories
* [x] tracking file system updates
* [x] opening, editing, saving buffers
* [ ] file operations (rename, delete, create)
* [ ] git diffs
* [ ] project search

Release Notes:

- N/A

---------

Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
2024-07-19 10:27:26 -07:00
Kyle Kelley
7733bf686b
Repl reorder keybinding (#14824)
Ensures that the assistant keybinding for cmd-enter takes precedence
over `repl::Run`.

On Linux, `ctrl-enter` (the equivalent), issues `repl::Run` when in a
jupyter context.

Release Notes:

- N/A
2024-07-19 10:05:08 -07:00
Marshall Bowers
edddc68da6
client: Remove leftover http.rs file (#14822)
This PR removes an empty `http.rs` file that was leftover from a
previous PR.

Release Notes:

- N/A
2024-07-19 12:22:31 -04:00
Thorsten Ball
5de5d5bc56
go: Fix quoting of targeting expression for non-fish shells (#14821)
This fixes #14818.

The change in #14055 broke the tasks in `zsh` (and I suspect in `bash`,
`sh` too), because what was executed was NOT

    $ go test . -run '^TestThis$'

but instead this:

    $ go test . -run \'^TestThis$\'

And in `zsh` this means that `'` is part of the argument passed to `go`,
which means the targeting string is wrong.

Since the problem in `fish` doesn't seem to be the `^` but the `$`, we
can only escape that, which makes the escaped string work in `zsh` and
`fish` and `bash` (in which I've tested this change here)

Release Notes:

- go: Fix running single tests by changing the quoted expression in the
`go test` command to work again in `bash`, `zsh`, etc.
([#14818](https://github.com/zed-industries/zed/issues/14818))
2024-07-19 18:05:31 +02:00
Kyle Kelley
5467e18a5b
repl: Refactor editor registration (#14819)
Cleans up action registration with the editors and also fixes a major
bug where only one workspace's panel was getting session info (due to my
not understanding that `cx.observe_new_views` is for the whole app).

Release Notes:

- N/A

Co-authored-by: Conrad <conrad@zed.dev>
2024-07-19 08:58:57 -07:00
Antonio Scandurra
4c7f1032a4
Allow an initial prompt to be associated with inline assist (#14816)
Release Notes:

- Added the ability to create custom inline assist bindings that
pre-fill a prompt from your keymap, e.g.:
    ```json
    [
        {
            "context": "Editor && mode == full",
            "bindings": {
                "ctrl-shift-enter": [
                    "assistant::InlineAssist",
                    { "prompt": "Build a snake game" }
                ]
            }
        }
    ]
    ```

---------

Co-authored-by: Nathan <nathan@zed.dev>
2024-07-19 17:13:48 +02:00
Antonio Scandurra
d61eaea4b9
Avoid losing focus when block decorations go offscreen (#14815)
Release Notes:

- Fixed a bug that caused focus to be lost when renames and inline
assists were scrolled offscreen.

---------

Co-authored-by: Nathan <nathan@zed.dev>
2024-07-19 17:04:18 +02:00
Richard Feldman
f5d50f2b1e
Delete obsolete and unused remote_projects.rs (#14811)
See
https://github.com/zed-industries/zed/pull/11301#issuecomment-2234239630
for context

Release Notes:

- N/A
2024-07-19 08:50:49 -06:00
Kyle Kelley
be4b19babb
repl: Create action to refresh kernelspecs (#14786)
Adds a command to refresh kernelspecs. Also added the kernelspecs to the
runtime panel when none are running. That's just for now until we move
out of the panel completely.

Release Notes:

- N/A
2024-07-19 07:42:18 -07:00
Marshall Bowers
272be98ec8
php: Bump to v0.1.2 (#14808)
This PR bumps the PHP extension to v0.1.2.

Changes:

- #14806

Release Notes:

- N/A
2024-07-19 09:13:23 -04:00
Marshall Bowers
e3d5eff858
Use ui::prelude::* in a few more spots (#14807)
This PR updates a couple files to make use of the `ui::prelude::*`
import.

Release Notes:

- N/A
2024-07-19 08:57:51 -04:00
Marshall Bowers
9cb17ac630
php: Respect LSP settings for Intelephense (#14806)
This PR updates the PHP extension with support for reading LSP settings
when using Intelephense as the language server.

Addresses #4258.

Release Notes:

- N/A
2024-07-19 08:51:44 -04:00
Jason Lee
fb541accb2
gpui: Update Menu name to use SharedString type to support more types (#14791)
Release Notes:

- N/A
2024-07-19 08:51:31 -04:00
Marshall Bowers
836f623800
Update icon positioning in tabs (#14804)
This PR updates the icon positioning in tabs to make give them even
spacing on either side.

Without file icons:

<img width="901" alt="Screenshot 2024-07-19 at 7 55 39 AM"
src="https://github.com/user-attachments/assets/89cc80cd-1323-424e-90a5-79d8586e8725">

With file icons:

<img width="956" alt="Screenshot 2024-07-19 at 7 55 52 AM"
src="https://github.com/user-attachments/assets/c5b47b4e-e6c3-4dbd-aeb3-fb09a0032105">

Release Notes:

- N/A
2024-07-19 08:04:57 -04:00
Kirill Bulatov
18c2e8f6ca
Rework mouse handling of git hunks diff (#14727)
Closes https://github.com/zed-industries/zed/issues/12404

![Screenshot 2024-07-18 at 14 02
31](https://github.com/user-attachments/assets/a8addd22-0ed9-4f4b-852a-f347314c27ce)

![Screenshot 2024-07-18 at 14 02
43](https://github.com/user-attachments/assets/0daaed10-b9f3-4d4b-b8d7-189aa7e013b9)

Video:


https://github.com/user-attachments/assets/58e62527-da75-4017-a43e-a37803bd7b49


* now shows a context menu on left click instead of expanding the hunk
diff
* hunk diffs can be toggled with a single cmd-click still
* adds a X mark into gutter for every hunk expanded
* makes `editor::ToggleDiffHunk` to work inside the deleted hunk editors

Additionally, changes the way editor context menus behave when the
editor is scrolled — right click and diff hunks context menu now will
stick to the place it was invoked at, instead of staying onscreen at the
same pixel positions.

Release Notes:

- Improved the way git hunks diff can be toggled with mouse
([#12404](https://github.com/zed-industries/zed/issues/12404))

---------

Co-authored-by: Nate Butler <nate@zed.dev>
Co-authored-by: Conrad Irwin <conrad@zed.dev>
2024-07-19 13:48:04 +03:00
0x2CA
bf4645b1fe
Fix vim <CTRL-J> slines downward linewise, Not Join Lines (#14796)
https://vimhelp.org/motion.txt.html#CTRL-J

Release Notes:

- vim: Added `ctrl-j` as a new binding that's equivalent to `j`.
2024-07-19 11:52:37 +02:00
Antonio Scandurra
4d177918c1
Start on adding support for editing via the assistant panel (#14795)
Note that this shouldn't have any visible user-facing behavior yet. The
feature is incomplete but we wanna merge early to avoid a long-running
branch.

Release Notes:

- N/A

---------

Co-authored-by: Nathan <nathan@zed.dev>
2024-07-19 11:13:15 +02:00
Conrad Irwin
87457f9ae8
Fix off-by-one errors in syntax highlighting (#14780)
In the case that a line ended with a 0-length run, we would get our
highlights offset by one position.

Release Notes:

- Fixed syntax highlights being offset from syntax in diagnostics
popovers.
2024-07-18 22:37:30 -06:00
Vishal Bhavsar
be45f32753
vim: Fix 'Y' to yank to end of line (#14783)
Instead of yanking the entire line.

Release Notes:

- vim: Updated `Y` to yank to end of line (like neovim)
https://github.com/zed-industries/zed/issues/14771
2024-07-18 22:34:40 -06:00
versecafe
18b5a87298
Add gpt-4o-mini as an available model (#14770)
Release Notes:

- Fixes #14769
2024-07-18 22:32:56 -06:00
Kyle Kelley
48211e8ce2
repl: Check process status and propagate to output (#14782)
<img width="582" alt="image"
src="https://github.com/user-attachments/assets/14bd321d-f5fc-4cc0-9386-f435423057ad">

Release Notes:

- N/A
2024-07-18 19:35:05 -07:00
Conrad Irwin
5008a388e6
Use -f in ssh remoting too (#14773)
Release Notes:

- N/A
2024-07-18 19:24:59 -06:00
versecafe
3c417864e6
typescript: Highlight using keyword (#14772)
Release Notes:

- Added syntax highlighting for the `using` keyword in TypeScript
([#14762](https://github.com/zed-industries/zed/issues/14762)).
2024-07-18 17:33:13 -04:00
Marshall Bowers
ad3055076d
assistant: Allow /docs to perform JIT indexing when run (#14768)
This PR updates the `/docs` slash command with the ability to
just-in-time index a package when there are not yet any results in the
index.

When running a `/docs` slash command, we fist check to see if there are
any results in the index that would match the search.

If there are, we go ahead and return them, as we do today.

However, if there are not yet any results we kick off an indexing task
as part of the command execution to fetch the results.

Release Notes:

- N/A
2024-07-18 17:01:48 -04:00
Peter Tripp
7c63f26aa9
Add duplicate and support as core github issue labels (#14735) 2024-07-18 16:21:30 -04:00
Conrad Irwin
f15a441c9d
Fix video rendering on docs (#14764)
Release Notes:

- N/A
2024-07-18 13:34:25 -06:00
Kyle Kelley
cb217381ce
repl: Scroll down after running code (#14759)
Go to the next line after running code. Allows for fluid coding and
running.


https://github.com/user-attachments/assets/d11ac05d-7801-4191-b275-3b20302e54c5

Release Notes:

- N/A
2024-07-18 11:22:43 -07:00
Kevin Wang
862f5a0561
Handle supermaven account status messages (#14749)
Sets the account status state to allow the Supermaven button to move out
of the "Supermaven is initializing..." state. We also need to add the
ability to sign out and change tiers but I will do that in a separate
PR.

Release Notes:

- Improved Supermaven status messages
([#12715](https://github.com/zed-industries/zed/issues/12715)).
2024-07-18 11:22:30 -07:00