Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: move common Cargo.toml keys into the workspace and inherit them #3019

Merged
merged 1 commit into from
Feb 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 7 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,14 @@ members = ["cli", "cli/config", "cli/loader", "lib", "tags", "highlight"]
resolver = "2"

[workspace.package]
authors = ["Max Brunsfeld <maxbrunsfeld@gmail.com>"]
edition = "2021"
rust-version = "1.70"
homepage = "https://tree-sitter.github.io/tree-sitter"
repository = "https://github.com/tree-sitter/tree-sitter"
license = "MIT"
keywords = ["incremental", "parsing"]
categories = ["command-line-utilities", "parsing"]

[profile.optimize]
inherits = "release"
Expand Down
15 changes: 8 additions & 7 deletions cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,15 @@
name = "tree-sitter-cli"
description = "CLI tool for developing, testing, and using Tree-sitter parsers"
version = "0.20.9"
authors = ["Max Brunsfeld <maxbrunsfeld@gmail.com>"]
edition = "2021"
license = "MIT"
readme = "README.md"
keywords = ["incremental", "parsing"]
categories = ["command-line-utilities", "parsing"]
repository = "https://github.com/tree-sitter/tree-sitter"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
readme = "README.md"
homepage.workspace = true
repository.workspace = true
license.workspace = true
keywords.workspace = true
categories.workspace = true

[[bin]]
name = "tree-sitter"
Expand Down
15 changes: 8 additions & 7 deletions cli/config/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,15 @@
name = "tree-sitter-config"
description = "User configuration of tree-sitter's command line programs"
version = "0.19.0"
authors = ["Max Brunsfeld <maxbrunsfeld@gmail.com>"]
edition = "2021"
license = "MIT"
readme = "README.md"
keywords = ["incremental", "parsing"]
categories = ["command-line-utilities", "parsing"]
repository = "https://github.com/tree-sitter/tree-sitter"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
readme = "README.md"
homepage.workspace = true
repository.workspace = true
license.workspace = true
keywords.workspace = true
categories.workspace = true

[dependencies]
anyhow.workspace = true
Expand Down
15 changes: 8 additions & 7 deletions cli/loader/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,15 @@
name = "tree-sitter-loader"
description = "Locates, builds, and loads tree-sitter grammars at runtime"
version = "0.20.0"
authors = ["Max Brunsfeld <maxbrunsfeld@gmail.com>"]
edition = "2021"
license = "MIT"
readme = "README.md"
keywords = ["incremental", "parsing"]
categories = ["command-line-utilities", "parsing"]
repository = "https://github.com/tree-sitter/tree-sitter"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
readme = "README.md"
homepage.workspace = true
repository.workspace = true
license.workspace = true
keywords.workspace = true
categories.workspace = true

[features]
wasm = ["tree-sitter/wasm"]
Expand Down
4 changes: 2 additions & 2 deletions cli/src/tests/proc_macro/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
[package]
name = "tree-sitter-tests-proc-macro"
version = "0.0.0"
edition = "2021"
publish = false
edition.workspace = true
rust-version.workspace = true
publish = false

[lib]
proc-macro = true
Expand Down
13 changes: 7 additions & 6 deletions highlight/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,17 @@ name = "tree-sitter-highlight"
description = "Library for performing syntax highlighting with Tree-sitter"
version = "0.20.2"
authors = [
"Max Brunsfeld <maxbrunsfeld@gmail.com>",
"Tim Clem <timothy.clem@gmail.com>",
"Max Brunsfeld <maxbrunsfeld@gmail.com>",
"Tim Clem <timothy.clem@gmail.com>",
]
license = "MIT"
edition.workspace = true
rust-version.workspace = true
readme = "README.md"
edition = "2021"
homepage.workspace = true
repository.workspace = true
license.workspace = true
keywords = ["incremental", "parsing", "syntax", "highlighting"]
categories = ["parsing", "text-editors"]
repository = "https://github.com/tree-sitter/tree-sitter"
rust-version.workspace = true

[lib]
crate-type = ["lib", "staticlib"]
Expand Down
25 changes: 13 additions & 12 deletions lib/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,26 @@
name = "tree-sitter"
description = "Rust bindings to the Tree-sitter parsing library"
version = "0.20.10"
authors = ["Max Brunsfeld <maxbrunsfeld@gmail.com>"]
edition = "2021"
license = "MIT"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
readme = "binding_rust/README.md"
keywords = ["incremental", "parsing"]
homepage.workspace = true
repository.workspace = true
license.workspace = true
keywords.workspace = true
categories = ["api-bindings", "parsing", "text-editors"]
repository = "https://github.com/tree-sitter/tree-sitter"
rust-version.workspace = true

build = "binding_rust/build.rs"
links = "tree-sitter"

include = [
"/binding_rust/*",
"/Cargo.toml",
"/src/*.h",
"/src/*.c",
"/src/unicode/*",
"/include/tree_sitter/api.h",
"/binding_rust/*",
"/Cargo.toml",
"/src/*.h",
"/src/*.c",
"/src/unicode/*",
"/include/tree_sitter/api.h",
]

[features]
Expand Down
13 changes: 7 additions & 6 deletions tags/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,17 @@ name = "tree-sitter-tags"
description = "Library for extracting tag information"
version = "0.20.2"
authors = [
"Max Brunsfeld <maxbrunsfeld@gmail.com>",
"Patrick Thomson <patrickt@github.com>",
"Max Brunsfeld <maxbrunsfeld@gmail.com>",
"Patrick Thomson <patrickt@github.com>",
]
license = "MIT"
edition.workspace = true
rust-version.workspace = true
readme = "README.md"
edition = "2021"
homepage.workspace = true
repository.workspace = true
license.workspace = true
keywords = ["incremental", "parsing", "syntax", "tagging"]
categories = ["parsing", "text-editors"]
repository = "https://github.com/tree-sitter/tree-sitter"
rust-version.workspace = true

[lib]
crate-type = ["lib", "staticlib"]
Expand Down