ZIm/crates
Julia Ryan 4a7c84f490
Fix nix build (#26270)
This PR includes lots of small fixes to get our `build.nix` and
`shell.nix` back to a working state.

I've tested this by running `cargo run` (inside the devshell) and `nix
run` on x86 nixos and arm64 darwin machines. I'd appreciate it if others
could test building inside the devshell to double-check that it's not
just working because I happen to have some system-level packages
installed, as well as seeing if it works on other platforms (non-nixos
linux, arm linux, x86 darwin).

I couldn't get the full test suite (`cargo nextest run --workspace`)
passing in the devshell on darwin, but they _are_ all passing on nixos.
nixpkgs [disables some of our
tests](92d11f06d5/pkgs/by-name/ze/zed-editor/package.nix (L226-L234))
that apparently fail or are flakey on hydra, but they don't know why.
I'm going to punt on debugging those for now, especially given that they
seem to be working for me. I'm also unsure of whether we actually want
the nix checkPhase to run the full test suite (it's currently not
passing `--workspace`) given that we have separate CI that should
enforce that those pass on all PRs.

Here's an overview of the changes made:
- Fix our `generate-licenses` script
- Relaxes the `cargo-about` version requirement slightly so it doesn't
try to install an older binary when the nixpkgs one is newer than our
requirement
- Add a workaround for [this cargo-about
issue](https://github.com/zed-industries/zed/issues/19971) obviating the
need for the patching done in the nixpkgs package
- Set the new `--frozen` flag to avoid network access/mutating the
lockfile
- Use dynamic webrtc lib from nixpkgs, and fixes up the build script in
webrtc-sys that hardcodes it to be statically linked.
- Use `inputsFrom` in `shell.nix` and avoid duplicating everything from
`build.nix`
- Add a temporary workaround for an [upstream crane
bug](https://github.com/ipetkov/crane/issues/808).
- Fix shebangs in our `script` dir to not hard-code `/bin/bash`

There are still a bunch of issues that aren't resolved here, I'll make a
tracking issue for those and try to land this first just to get back to
an unbroken state. Eventually among other things I'd like to use a
`libgit2` from `staticPkgs` and musl cross compilation to build the
remote server under nix, and then add that as a separate flake output
and include it in the shell's `inputsFrom` list.

Thanks @niklaskorz, @GaetanLepage, @bbigras and all the other nixpkgs
maintainers that have kept the `zed-editor` package working and up to
date! I seriously considered just making our flake `overrideAttrs` the
package in nixpkgs given how well maintained it is.

Thanks @WeetHet for your volunteer maintinance of this flake. I
referenced #24953 while working on these fixes, and I'd love to
collaborate on adding some of those pieces like treefmt and a github
action. If you're interested I'd really appreciate some help debugging
why crane's `buildDepsOnly` isn't working for us. I'm assuming it'd make
our `nix build` times go way down from the improved dep caching if we
could get it working.

Thanks @rrbutani for all the help on this PR 💙.

Release Notes:

- N/A

---------

Co-authored-by: Rahul Butani <rrbutani@users.noreply.github.com>
Co-authored-by: Rahul Butani <rr.butani@gmail.com>
2025-03-10 01:06:11 -07:00
..
activity_indicator Remove worktree and project notifies (#26244) 2025-03-07 10:51:46 -07:00
anthropic Add Anthropic Claude 3.7 support (#25497) 2025-02-24 16:10:26 -05:00
askpass Git askpass (#25953) 2025-03-06 05:20:06 +00:00
assets Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
assistant Refactor Completions to allow non-LSP ones better (#26300) 2025-03-07 20:19:28 +00:00
assistant2 assistant: Make scripting a first-class concept instead of a tool (#26338) 2025-03-09 09:01:49 +00:00
assistant_context_editor Refactor Completions to allow non-LSP ones better (#26300) 2025-03-07 20:19:28 +00:00
assistant_scripting Add support for querying file outline in assistant script (#26351) 2025-03-10 05:26:17 +00:00
assistant_settings assistant: Add Bedrock support (#21092) 2025-02-24 18:10:12 -05:00
assistant_slash_command Revert "file_finder: Remove common segments of long paths in search results (#25049)" (#25163) 2025-02-19 15:32:29 +00:00
assistant_slash_commands chore: Extract PromptStore out of prompt_library (#25837) 2025-03-01 00:34:28 +01:00
assistant_tool assistant_tool: Pass an Entity<Project> to Tool::run (#26312) 2025-03-07 23:30:56 +00:00
assistant_tools assistant_tool: Pass an Entity<Project> to Tool::run (#26312) 2025-03-07 23:30:56 +00:00
audio Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
auto_update cx.background_executor().spawn(...) -> cx.background_spawn(...) (#25103) 2025-02-18 20:30:33 +00:00
auto_update_ui Add user-visible output for remote operations (#25849) 2025-03-03 09:20:15 +00:00
aws_http_client Add aws_http_client and bedrock crates (#25490) 2025-02-24 20:28:20 +00:00
bedrock bedrock: Add Claude 3.7 Sonnet (#25583) 2025-02-25 13:52:42 -05:00
breadcrumbs Add user-visible output for remote operations (#25849) 2025-03-03 09:20:15 +00:00
buffer_diff Clear pending staged/unstaged diff hunks hunks when writing to the git index fails (#26173) 2025-03-05 18:45:09 -08:00
call cx.background_executor().spawn(...) -> cx.background_spawn(...) (#25103) 2025-02-18 20:30:33 +00:00
channel Rust 1.85 (#25272) 2025-02-28 18:33:35 +01:00
cli cli: Add extra paths in detect() on Windows (#25765) 2025-03-02 00:17:55 +08:00
client Git telemetry (#26222) 2025-03-06 10:56:28 -07:00
clock chore: Use workspace fields for edition and publish (#23291) 2025-01-17 17:39:22 +01:00
collab git_ui: Add support for generating commit messages with an LLM (#26227) 2025-03-06 19:47:52 +00:00
collab_ui Refactor Completions to allow non-LSP ones better (#26300) 2025-03-07 20:19:28 +00:00
collections chore: Use workspace fields for edition and publish (#23291) 2025-01-17 17:39:22 +01:00
command_palette cx.background_executor().spawn(...) -> cx.background_spawn(...) (#25103) 2025-02-18 20:30:33 +00:00
command_palette_hooks vim: :set support (#24209) 2025-02-11 04:55:40 +00:00
component component_preview: Add component pages (#26284) 2025-03-07 18:56:17 +00:00
component_preview component_preview: Add component pages (#26284) 2025-03-07 18:56:17 +00:00
context_server assistant_tool: Pass an Entity<Project> to Tool::run (#26312) 2025-03-07 23:30:56 +00:00
context_server_settings Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
copilot copilot: Fix missing sign-out button when Zed is the edit prediction provider (#26340) 2025-03-09 21:39:14 +05:30
credentials_provider Use the development credentials provider in development by default (#25273) 2025-02-20 19:07:16 +00:00
db cx.background_executor().spawn(...) -> cx.background_spawn(...) (#25103) 2025-02-18 20:30:33 +00:00
deepseek Add DeepSeek support (#23551) 2025-01-27 13:40:59 -05:00
diagnostics diagnostics: Fix losing focus when activating from diagnostics view (#25517) 2025-03-08 22:17:20 +00:00
docs_preprocessor Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
editor Avoid modifying the LSP message before resolving it (#26347) 2025-03-10 00:12:53 +02:00
evals Revert "file_finder: Remove common segments of long paths in search results (#25049)" (#25163) 2025-02-19 15:32:29 +00:00
extension extension: Require that grammar names are written in snake_case (#26295) 2025-03-07 19:02:35 +00:00
extension_api Rust 1.85 (#25272) 2025-02-28 18:33:35 +01:00
extension_cli extension_cli: Make use of scrollbar_thumb.background a hard error (#25932) 2025-03-03 15:55:15 +00:00
extension_host extension: Add capabilities for the process API (#26224) 2025-03-06 11:55:00 -05:00
extensions_ui gpui: Rename rounded_md to rounded_sm (#26228) 2025-03-06 17:57:31 +00:00
feature_flags zeta: Remove predict-edits-launch feature flag (#24829) 2025-02-13 21:48:09 +00:00
feedback gpui: Rename rounded_md to rounded_sm (#26228) 2025-03-06 17:57:31 +00:00
file_finder Worktree paths in git panel, take 2 (#26047) 2025-03-06 22:55:28 +00:00
file_icons Allow icon themes to provide their own file associations (#24926) 2025-02-15 00:35:13 +00:00
fs Clear pending staged/unstaged diff hunks hunks when writing to the git index fails (#26173) 2025-03-05 18:45:09 -08:00
fsevent Deflake fs::test_event_stream_simple (#24013) 2025-01-30 23:53:36 -07:00
fuzzy workspace: Add trailing / to directories on completion when using OpenPathPrompt (#25430) 2025-03-04 14:01:08 +08:00
git Improve when the commit suggestions would show (#26313) 2025-03-07 23:33:48 +00:00
git_hosting_providers git_hosting_providers: Add support for Chromium repositories (#24881) 2025-02-20 19:11:32 -05:00
git_ui Restore git panel header (#26354) 2025-03-10 07:08:10 +00:00
go_to_line project: Fine-grained language server management (#24038) 2025-02-14 15:41:49 +01:00
google_ai Partially fix assistant onboarding (#25313) 2025-02-24 07:29:55 +00:00
gpui Change the default staging and unstaging state display (#26299) 2025-03-07 19:56:24 +00:00
gpui_macros gpui: Add rounded_md token (#26179) 2025-03-06 13:41:21 -05:00
gpui_tokio Make the gpui_tokio crate generic over the context it spawns (#23995) 2025-01-31 02:00:55 +00:00
html_to_markdown Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
http_client Rust 1.85 (#25272) 2025-02-28 18:33:35 +01:00
image_viewer image_viewer: Hide breadcrumb (#25654) 2025-02-26 17:24:35 +01:00
indexed_docs Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
inline_completion edit predictions: Show user if current project is open source (#24587) 2025-02-10 22:28:56 -03:00
inline_completion_button Support absolute disabled_globs (#25755) 2025-02-27 15:29:32 -03:00
install_cli Fix missed renames in #22632 (#23688) 2025-01-26 23:37:34 +00:00
journal Worktree paths in git panel, take 2 (#26047) 2025-03-06 22:55:28 +00:00
language Follow-up fixes for recent multi buffer optimizations (#26345) 2025-03-09 22:15:38 -07:00
language_extension Rust 1.85 (#25272) 2025-02-28 18:33:35 +01:00
language_model Rust 1.85 (#25272) 2025-02-28 18:33:35 +01:00
language_model_selector Fix language model selector (#26138) 2025-03-05 12:48:10 -05:00
language_models copilot: Fix missing sign-out button when Zed is the edit prediction provider (#26340) 2025-03-09 21:39:14 +05:30
language_selector Refactor to use SharedString in more places (#23813) 2025-01-28 19:04:21 -05:00
language_tools Make buffer search aware of search direction (#24974) 2025-03-04 19:27:37 -07:00
languages Revert "Highlight super and this as keywords in JS/TS/TSX" (#26342) 2025-03-09 16:11:37 +00:00
livekit_api Change license of crates/livekit_api from AGPL to GPL (#25206) 2025-02-19 23:32:51 +00:00
livekit_client cx.background_executor().spawn(...) -> cx.background_spawn(...) (#25103) 2025-02-18 20:30:33 +00:00
livekit_client_macos Rename livekit_server to livekit_api (#24984) 2025-02-16 20:24:12 +00:00
lmstudio lmstudio: Support missing quantization in model metadata (#24054) 2025-01-31 22:28:11 +00:00
lsp lsp: Add support for clangd's inactiveRegions extension (#26146) 2025-03-06 21:30:05 +00:00
markdown Silence a couple of noisy logs (#26262) 2025-03-06 22:45:47 -05:00
markdown_preview Worktree paths in git panel, take 2 (#26047) 2025-03-06 22:55:28 +00:00
media chore: Use workspace fields for edition and publish (#23291) 2025-01-17 17:39:22 +01:00
menu keymap: Update Prev to Previous for consistency (#25909) 2025-03-03 17:44:49 +05:30
migrator migrator: Add versioned migrations (#26215) 2025-03-06 23:04:48 +05:30
mistral assistant: Add Mistral support (#24879) 2025-02-14 13:07:41 -05:00
multi_buffer Fix performance bottlenecks when multi buffers have huge numbers of buffers (#26308) 2025-03-08 02:15:15 +00:00
node_runtime node_runtime: Use user/global configuration when using system node installation (#26209) 2025-03-06 12:50:42 +01:00
notifications Add StatusToast & the ToastLayer (#26232) 2025-03-06 20:37:54 +00:00
ollama Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
open_ai Update Assistant context limits (#25087) 2025-02-19 11:06:20 -05:00
outline keymap: Update Prev to Previous for consistency (#25909) 2025-03-03 17:44:49 +05:30
outline_panel Worktree paths in git panel, take 2 (#26047) 2025-03-06 22:55:28 +00:00
panel git: Fix git commit font fallbacks (#26184) 2025-03-06 04:06:00 +00:00
paths Settings/keymap backup path next to files + update notification messages (#24517) 2025-02-09 16:51:37 -07:00
picker git: Make repo selector wider (#26149) 2025-03-05 13:02:29 -07:00
prettier lsp: Use available workspace folders in initialize params (#25753) 2025-02-27 16:45:59 +01:00
project Avoid modifying the LSP message before resolving it (#26347) 2025-03-10 00:12:53 +02:00
project_panel Worktree paths in git panel, take 2 (#26047) 2025-03-06 22:55:28 +00:00
project_symbols Add user-visible output for remote operations (#25849) 2025-03-03 09:20:15 +00:00
prompt_library gpui: Rename rounded_md to rounded_sm (#26228) 2025-03-06 17:57:31 +00:00
prompt_store chore: Extract PromptStore out of prompt_library (#25837) 2025-03-01 00:34:28 +01:00
proto Avoid modifying the LSP message before resolving it (#26347) 2025-03-10 00:12:53 +02:00
recent_projects gpui: Rename rounded_md to rounded_sm (#26228) 2025-03-06 17:57:31 +00:00
refineable windows: Fix tests on Windows (#22616) 2025-02-05 14:30:09 +00:00
release_channel windows: Missing commit of #25412 (#25732) 2025-02-27 08:00:42 +00:00
remote Git askpass (#25953) 2025-03-06 05:20:06 +00:00
remote_server Git askpass (#25953) 2025-03-06 05:20:06 +00:00
repl gpui: Rename rounded_md to rounded_sm (#26228) 2025-03-06 17:57:31 +00:00
reqwest_client Redact Google Gemini API keys from error messaging and log (#24884) 2025-02-17 11:42:22 -05:00
rich_text Add user-visible output for remote operations (#25849) 2025-03-03 09:20:15 +00:00
rope Add support for auto-closing of JSX tags (#25681) 2025-03-06 08:36:10 -06:00
rpc extensions_ui: Add general structure for filtering extensions by what they provide (#24325) 2025-02-06 00:09:37 +00:00
schema_generator Improve schema_generator CLI (#25898) 2025-03-06 04:59:57 +00:00
search Make buffer search aware of search direction (#24974) 2025-03-04 19:27:37 -07:00
semantic_index Revert "file_finder: Remove common segments of long paths in search results (#25049)" (#25163) 2025-02-19 15:32:29 +00:00
semantic_version chore: Use workspace fields for edition and publish (#23291) 2025-01-17 17:39:22 +01:00
session cx.background_executor().spawn(...) -> cx.background_spawn(...) (#25103) 2025-02-18 20:30:33 +00:00
settings copilot: Fix onboarding into Copilot requires Zed restart (#26330) 2025-03-09 03:19:09 +05:30
settings_ui Fix UI font size changes not applying (#25307) 2025-02-21 06:24:02 -03:00
snippet Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
snippet_provider snippets: Fix snippets not updating while containing comments (#23755) 2025-01-28 10:37:48 +01:00
snippets_ui Worktree paths in git panel, take 2 (#26047) 2025-03-06 22:55:28 +00:00
sqlez Rust 1.85 (#25272) 2025-02-28 18:33:35 +01:00
sqlez_macros windows: Fix tests on Windows (#22616) 2025-02-05 14:30:09 +00:00
story gpui: Rename rounded_md to rounded_sm (#26228) 2025-03-06 17:57:31 +00:00
storybook keymap: Update Prev to Previous for consistency (#25909) 2025-03-03 17:44:49 +05:30
streaming_diff chore: Use workspace fields for edition and publish (#23291) 2025-01-17 17:39:22 +01:00
sum_tree Clear pending staged/unstaged diff hunks hunks when writing to the git index fails (#26173) 2025-03-05 18:45:09 -08:00
supermaven Include prediction ID on edit prediction accepted/discarded events (#24480) 2025-02-07 22:06:37 +00:00
supermaven_api Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
tab_switcher Fix left clicking the close button in the switcher (#25979) 2025-03-05 11:50:39 -08:00
task vim: Fix tab title when using !! and disable rerun button for terminal tasks (#26122) 2025-03-05 08:47:49 -07:00
tasks_ui Worktree paths in git panel, take 2 (#26047) 2025-03-06 22:55:28 +00:00
telemetry Git telemetry (#26222) 2025-03-06 10:56:28 -07:00
telemetry_events Add build SHA to panic reports and zed --version (on nightly/dev) (#24258) 2025-02-06 02:09:24 -07:00
terminal vim: Fix tab title when using !! and disable rerun button for terminal tasks (#26122) 2025-03-05 08:47:49 -07:00
terminal_view Fix nix build (#26270) 2025-03-10 01:06:11 -07:00
text Rust 1.85 (#25272) 2025-02-28 18:33:35 +01:00
theme Add file icon for Luau (#26293) 2025-03-07 15:27:00 -03:00
theme_extension theme: Don't log errors for missing themes until extensions have loaded (#25098) 2025-02-18 17:47:25 +00:00
theme_importer Add schema_generator for generating JSON schemas (#23991) 2025-01-31 01:22:10 +00:00
theme_selector icon_theme_selector: Add footer and related docs (#25042) 2025-02-20 00:02:24 +00:00
time_format Add an undo button to the git panel (#24593) 2025-02-12 15:57:08 -07:00
title_bar Remove worktree and project notifies (#26244) 2025-03-07 10:51:46 -07:00
toolchain_selector Revert "file_finder: Remove common segments of long paths in search results (#25049)" (#25163) 2025-02-19 15:32:29 +00:00
ui Improve the generate commit message design (#26233) 2025-03-07 01:21:20 +00:00
ui_input Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
ui_macros Add StatusToast & the ToastLayer (#26232) 2025-03-06 20:37:54 +00:00
util Worktree paths in git panel, take 2 (#26047) 2025-03-06 22:55:28 +00:00
util_macros windows: Fix tests on Windows (#22616) 2025-02-05 14:30:09 +00:00
vim Fix auto-indent when pasting multi-line content that was copied start… (#26246) 2025-03-06 22:13:34 +00:00
vim_mode_setting Eliminate GPUI View, ViewContext, and WindowContext types (#22632) 2025-01-26 03:02:45 +00:00
welcome gpui: Rename rounded_md to rounded_sm (#26228) 2025-03-06 17:57:31 +00:00
workspace Fix performance bottlenecks when multi buffers have huge numbers of buffers (#26308) 2025-03-08 02:15:15 +00:00
worktree Improve when the commit suggestions would show (#26313) 2025-03-07 23:33:48 +00:00
zed assistant: Make scripting a first-class concept instead of a tool (#26338) 2025-03-09 09:01:49 +00:00
zed_actions Add git branch switching aliases (#26315) 2025-03-08 00:02:57 +00:00
zeta gpui: Rename rounded_md to rounded_sm (#26228) 2025-03-06 17:57:31 +00:00