mirror of
https://github.com/zed-industries/zed.git
synced 2026-11-25 18:11:20 +01:00
98f75a23bc
## Summary Some dependencies were originally introduced for only a few specific functions that can either be fulfilled by existing dependencies or easily implemented in-tree. This PR removes or replaces them: 1. `json_dotpath`: Removed. We do not use the dot-path query feature; standard methods in `serde_json` are sufficient for our use case. 2. `crossbeam`: Replaced with the more lightweight `crossbeam-queue`. 3. `take-until`: Removed. Calls to `take_until` are replaced with `take_while_inclusive` from `itertools`, which is already widely used in Zed. 4. `x11-clipboard`: Removed. It is deprecated and was only an unused entry left in `Cargo.toml`. 5. `portable-pty`: Removed. We only used the `ExitStatus` transformation logic from this crate, which has now been inlined into the Zed codebase. Together, these changes reduce the total crate count from 1,727 to 1,717 during a Linux `cargo build`, slightly improving compile times. ## Testing This is a refactoring PR with no functional changes. Existing tests were run locally to ensure no regressions were introduced. ## Self-review - [x] I've reviewed my diff for quality, security, reliability, and performance. - [ ] UI changes follow the [checklist](https://zed.dev/docs/development/ui-checklist). - [ ] Tests cover the new or changed behavior. Release Notes: - N/A - [GPUI] N/A
71 lines
1.7 KiB
TOML
71 lines
1.7 KiB
TOML
[package]
|
|
name = "util"
|
|
version = "0.1.0"
|
|
edition.workspace = true
|
|
publish = false
|
|
license = "Apache-2.0"
|
|
description = "A collection of utility structs and functions used by Zed and GPUI"
|
|
|
|
|
|
[lints]
|
|
workspace = true
|
|
|
|
[lib]
|
|
path = "src/util.rs"
|
|
doctest = true
|
|
|
|
[features]
|
|
test-support = ["rand", "util_macros", "path/test-support"]
|
|
# Embed `fs_embed!` assets at compile time even in debug builds.
|
|
debug-embed = ["rust-embed/debug-embed"]
|
|
|
|
[dependencies]
|
|
anyhow.workspace = true
|
|
async_zip.workspace = true
|
|
collections.workspace = true
|
|
dunce.workspace = true
|
|
futures-lite.workspace = true
|
|
futures.workspace = true
|
|
globset.workspace = true
|
|
itertools.workspace = true
|
|
log.workspace = true
|
|
rand = { workspace = true, optional = true }
|
|
regex.workspace = true
|
|
rust-embed.workspace = true
|
|
schemars.workspace = true
|
|
serde.workspace = true
|
|
serde_json.workspace = true
|
|
serde_json_lenient.workspace = true
|
|
shlex.workspace = true
|
|
tempfile.workspace = true
|
|
unicase.workspace = true
|
|
url.workspace = true
|
|
percent-encoding.workspace = true
|
|
util_macros = { workspace = true, optional = true }
|
|
gpui_util.workspace = true
|
|
path = { workspace = true, features = ["serde"] }
|
|
|
|
[target.'cfg(not(target_family = "wasm"))'.dependencies]
|
|
smol.workspace = true
|
|
which.workspace = true
|
|
async-fs.workspace = true
|
|
walkdir.workspace = true
|
|
dirs.workspace = true
|
|
|
|
[target.'cfg(unix)'.dependencies]
|
|
command-fds = "0.3.1"
|
|
libc.workspace = true
|
|
nix = { workspace = true, features = ["resource", "user"] }
|
|
|
|
[target.'cfg(target_os = "macos")'.dependencies]
|
|
mach2.workspace = true
|
|
|
|
[target.'cfg(windows)'.dependencies]
|
|
tendril = "0.5"
|
|
windows.workspace = true
|
|
|
|
[dev-dependencies]
|
|
rand.workspace = true
|
|
util_macros.workspace = true
|
|
path = { workspace = true, features = ["test-support"] }
|