Extract core stuff into own crates
This commit extracts five new crates:
- nu-source, which contains the core source-code handling logic in Nu,
including Text, Span, and also the pretty.rs-based debug logic
- nu-parser, which is the parser and expander logic
- nu-protocol, which is the bulk of the types and basic conveniences
used by plugins
- nu-errors, which contains ShellError, ParseError and error handling
conveniences
- nu-textview, which is the textview plugin extracted into a crate
One of the major consequences of this refactor is that it's no longer
possible to `impl X for Spanned<Y>` outside of the `nu-source` crate, so
a lot of types became more concrete (Value became a concrete type
instead of Spanned<Value>, for example).
This also turned a number of inherent methods in the main nu crate into
plain functions (impl Value {} became a bunch of functions in the
`value` namespace in `crate::data::value`).
2019-11-26 03:30:48 +01:00
|
|
|
[package]
|
2022-03-22 21:25:38 +01:00
|
|
|
authors = ["The Nushell Project Developers"]
|
2022-04-11 20:17:06 +02:00
|
|
|
description = "Nushell's internal protocols, including its abstract syntax tree"
|
2022-08-14 14:21:20 +02:00
|
|
|
repository = "https://github.com/nushell/nushell/tree/main/crates/nu-protocol"
|
2022-03-22 21:25:38 +01:00
|
|
|
edition = "2021"
|
|
|
|
license = "MIT"
|
2020-07-05 22:12:44 +02:00
|
|
|
name = "nu-protocol"
|
2024-01-09 21:16:29 +01:00
|
|
|
version = "0.89.0"
|
2021-09-02 03:29:43 +02:00
|
|
|
|
|
|
|
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
|
|
|
|
2023-02-12 23:22:00 +01:00
|
|
|
[lib]
|
|
|
|
bench = false
|
|
|
|
|
2021-09-02 03:29:43 +02:00
|
|
|
[dependencies]
|
2024-01-09 21:16:29 +01:00
|
|
|
nu-utils = { path = "../nu-utils", version = "0.89.0" }
|
|
|
|
nu-path = { path = "../nu-path", version = "0.89.0" }
|
|
|
|
nu-system = { path = "../nu-system", version = "0.89.0" }
|
2022-08-04 21:51:02 +02:00
|
|
|
|
2023-05-26 17:32:48 +02:00
|
|
|
byte-unit = "4.0"
|
2023-06-23 22:05:04 +02:00
|
|
|
chrono = { version = "0.4", features = [ "serde", "std", "unstable-locales" ], default-features = false }
|
2023-05-26 17:32:48 +02:00
|
|
|
chrono-humanize = "0.2"
|
2023-12-21 17:10:33 +01:00
|
|
|
fancy-regex = "0.12"
|
2023-11-07 16:36:34 +01:00
|
|
|
indexmap = "2.1"
|
2023-10-18 23:00:11 +02:00
|
|
|
lru = "0.12"
|
2023-07-17 08:25:04 +02:00
|
|
|
miette = { version = "5.10", features = ["fancy-no-backtrace"] }
|
2023-05-26 17:32:48 +02:00
|
|
|
num-format = "0.4"
|
2023-08-21 19:04:34 +02:00
|
|
|
serde = { version = "1.0", default-features = false }
|
2022-08-04 21:51:02 +02:00
|
|
|
serde_json = { version = "1.0", optional = true }
|
2023-05-26 17:32:48 +02:00
|
|
|
thiserror = "1.0"
|
|
|
|
typetag = "0.2"
|
2021-11-19 03:51:42 +01:00
|
|
|
|
|
|
|
[features]
|
|
|
|
plugin = ["serde_json"]
|
|
|
|
|
|
|
|
[dev-dependencies]
|
|
|
|
serde_json = "1.0"
|
2023-07-10 13:35:23 +02:00
|
|
|
strum = "0.25"
|
2023-07-17 08:23:17 +02:00
|
|
|
strum_macros = "0.25"
|
2024-01-09 21:16:29 +01:00
|
|
|
nu-test-support = { path = "../nu-test-support", version = "0.89.0" }
|
2023-08-22 23:09:23 +02:00
|
|
|
rstest = "0.18"
|
2023-11-29 16:17:22 +01:00
|
|
|
|
|
|
|
[package.metadata.docs.rs]
|
|
|
|
all-features = true
|