Skip to content

Commit b58e1ac

Browse files
committed
refactor: make cocoindex crate a sub crate under the workspace
1 parent b8344f6 commit b58e1ac

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

103 files changed

+134
-22
lines changed

Cargo.toml

Lines changed: 9 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,8 @@
1-
[package]
2-
name = "cocoindex"
3-
# Version used for local development is always higher than others to take precedence.
4-
# Will be overridden for specific release versions.
5-
version = "999.0.0"
6-
edition = "2024"
7-
rust-version = "1.89"
8-
license = "Apache-2.0"
1+
[workspace]
2+
members = ["rust/cocoindex"]
3+
resolver = "2"
94

10-
[profile.release]
11-
codegen-units = 1
12-
strip = "symbols"
13-
lto = true
14-
15-
[lib]
16-
name = "cocoindex_engine"
17-
crate-type = ["cdylib"]
18-
19-
[features]
20-
default = ["legacy-states-v0"]
21-
legacy-states-v0 = []
22-
23-
[dependencies]
5+
[workspace.dependencies]
246
pyo3 = { version = "0.25.1", features = [
257
"abi3-py311",
268
"auto-initialize",
@@ -157,3 +139,8 @@ redis = { version = "0.31.0", features = ["tokio-comp", "connection-manager"] }
157139
expect-test = "1.5.0"
158140
encoding_rs = "0.8.35"
159141
tokio-util = { version = "0.7.16", features = ["rt"] }
142+
143+
[profile.release]
144+
codegen-units = 1
145+
strip = "symbols"
146+
lto = true

pyproject.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ python-source = "python"
6060
module-name = "cocoindex._engine"
6161
features = ["pyo3/extension-module"]
6262
include = ["THIRD_PARTY_NOTICES.html"]
63+
# Point to the crate within the workspace
64+
manifest-path = "rust/cocoindex/Cargo.toml"
6365

6466
[project.optional-dependencies]
6567
dev = ["pytest", "pytest-asyncio", "ruff", "mypy", "pre-commit"]

rust/cocoindex/Cargo.toml

Lines changed: 123 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
[package]
2+
name = "cocoindex"
3+
# Version used for local development is always higher than others to take precedence.
4+
# Will be overridden for specific release versions.
5+
version = "999.0.0"
6+
edition = "2024"
7+
rust-version = "1.89"
8+
license = "Apache-2.0"
9+
10+
[lib]
11+
name = "cocoindex_engine"
12+
crate-type = ["cdylib"]
13+
14+
[features]
15+
default = ["legacy-states-v0"]
16+
legacy-states-v0 = []
17+
18+
[dependencies]
19+
pyo3 = { workspace = true }
20+
pythonize = { workspace = true }
21+
pyo3-async-runtimes = { workspace = true }
22+
23+
anyhow = { workspace = true }
24+
async-trait = { workspace = true }
25+
axum = { workspace = true }
26+
axum-extra = { workspace = true }
27+
base64 = { workspace = true }
28+
chrono = { workspace = true }
29+
config = { workspace = true }
30+
const_format = { workspace = true }
31+
futures = { workspace = true }
32+
log = { workspace = true }
33+
regex = { workspace = true }
34+
serde = { workspace = true }
35+
serde_json = { workspace = true }
36+
sqlx = { workspace = true }
37+
tokio = { workspace = true }
38+
tower = { workspace = true }
39+
tower-http = { workspace = true }
40+
indexmap = { workspace = true }
41+
blake2 = { workspace = true }
42+
pgvector = { workspace = true }
43+
phf = { workspace = true }
44+
indenter = { workspace = true }
45+
indicatif = { workspace = true }
46+
itertools = { workspace = true }
47+
derivative = { workspace = true }
48+
hex = { workspace = true }
49+
schemars = { workspace = true }
50+
env_logger = { workspace = true }
51+
reqwest = { workspace = true }
52+
async-openai = { workspace = true }
53+
54+
tree-sitter = { workspace = true }
55+
tree-sitter-language = { workspace = true }
56+
# Per language tree-sitter parsers
57+
tree-sitter-c = { workspace = true }
58+
tree-sitter-cpp = { workspace = true }
59+
tree-sitter-c-sharp = { workspace = true }
60+
tree-sitter-css = { workspace = true }
61+
tree-sitter-fortran = { workspace = true }
62+
tree-sitter-go = { workspace = true }
63+
tree-sitter-html = { workspace = true }
64+
tree-sitter-java = { workspace = true }
65+
tree-sitter-javascript = { workspace = true }
66+
tree-sitter-json = { workspace = true }
67+
# The other more popular crate tree-sitter-kotlin requires tree-sitter < 0.23 for now
68+
tree-sitter-kotlin-ng = { workspace = true }
69+
tree-sitter-md = { workspace = true }
70+
tree-sitter-pascal = { workspace = true }
71+
tree-sitter-php = { workspace = true }
72+
tree-sitter-python = { workspace = true }
73+
tree-sitter-r = { workspace = true }
74+
tree-sitter-ruby = { workspace = true }
75+
tree-sitter-rust = { workspace = true }
76+
tree-sitter-scala = { workspace = true }
77+
tree-sitter-sequel = { workspace = true }
78+
tree-sitter-swift = { workspace = true }
79+
tree-sitter-toml-ng = { workspace = true }
80+
tree-sitter-typescript = { workspace = true }
81+
tree-sitter-xml = { workspace = true }
82+
tree-sitter-yaml = { workspace = true }
83+
tree-sitter-solidity = { workspace = true }
84+
85+
globset = { workspace = true }
86+
unicase = { workspace = true }
87+
google-drive3 = { workspace = true }
88+
hyper-util = { workspace = true }
89+
hyper-rustls = { workspace = true }
90+
yup-oauth2 = { workspace = true }
91+
rustls = { workspace = true }
92+
http-body-util = { workspace = true }
93+
yaml-rust2 = { workspace = true }
94+
urlencoding = { workspace = true }
95+
qdrant-client = { workspace = true }
96+
uuid = { workspace = true }
97+
tokio-stream = { workspace = true }
98+
async-stream = { workspace = true }
99+
neo4rs = { workspace = true }
100+
bytes = { workspace = true }
101+
rand = { workspace = true }
102+
indoc = { workspace = true }
103+
owo-colors = { workspace = true }
104+
json5 = { workspace = true }
105+
aws-config = { workspace = true }
106+
aws-sdk-s3 = { workspace = true }
107+
aws-sdk-sqs = { workspace = true }
108+
time = { workspace = true }
109+
numpy = { workspace = true }
110+
infer = { workspace = true }
111+
serde_with = { workspace = true }
112+
google-cloud-aiplatform-v1 = { workspace = true }
113+
google-cloud-gax = { workspace = true }
114+
115+
azure_identity = { workspace = true }
116+
azure_core = { workspace = true }
117+
azure_storage = { workspace = true }
118+
azure_storage_blobs = { workspace = true }
119+
serde_path_to_error = { workspace = true }
120+
redis = { workspace = true }
121+
expect-test = { workspace = true }
122+
encoding_rs = { workspace = true }
123+
tokio-util = { workspace = true }
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)