-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathCargo.toml
More file actions
74 lines (66 loc) · 3.07 KB
/
Copy pathCargo.toml
File metadata and controls
74 lines (66 loc) · 3.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
[package]
name = "sqlglot-rust"
version = "0.10.2"
edition = "2024"
description = "A SQL parser, optimizer, and transpiler library inspired by Python's sqlglot"
license = "MIT"
readme = "README.md"
repository = "https://github.com/protegrity/sql-glot-rust"
homepage = "https://github.com/protegrity/sql-glot-rust"
documentation = "https://github.com/protegrity/sql-glot-rust/blob/master/docs/guide.md"
keywords = ["sql", "parser", "transpiler", "ast", "database"]
categories = ["parser-implementations", "database"]
exclude = ["packaging/test/", ".dockerignore", ".github/"]
[lib]
crate-type = ["rlib", "cdylib", "staticlib"]
[features]
default = []
cli = ["clap"]
[dependencies]
thiserror = "2"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
log = "0.4"
clap = { version = "4", features = ["derive"], optional = true }
[[bin]]
name = "sqlglot"
path = "src/bin/sqlglot.rs"
required-features = ["cli"]
[dev-dependencies]
pretty_assertions = "1"
criterion = { version = "0.8", features = ["html_reports"] }
assert_cmd = "2"
predicates = "3"
tempfile = "3"
serde_json = "1"
[[bench]]
name = "parser_bench"
harness = false
# ── Debian package (cargo-deb) ────────────────────────────────────────────
[package.metadata.deb]
maintainer = "Protegrity <engineering@protegrity.com>"
copyright = "2024-2026 Protegrity"
extended-description = """\
sqlglot-rust is a SQL parser, optimizer, and transpiler library \
supporting 30 SQL dialects. This package provides the sqlglot CLI \
and shared/static C FFI libraries."""
section = "database"
priority = "optional"
assets = [
["target/release/sqlglot", "usr/bin/sqlglot", "755"],
["target/release/libsqlglot_rust.so", "usr/lib/libsqlglot_rust.so", "644"],
["target/release/libsqlglot_rust.a", "usr/lib/libsqlglot_rust.a", "644"],
["target/ffi/include/sqlglot.h", "usr/include/sqlglot.h", "644"],
["README.md", "usr/share/doc/sqlglot-rust/README.md", "644"],
["LICENSE", "usr/share/doc/sqlglot-rust/LICENSE", "644"],
]
# ── RPM package (cargo-generate-rpm) ─────────────────────────────────────
[package.metadata.generate-rpm]
assets = [
{ source = "target/release/sqlglot", dest = "/usr/bin/sqlglot", mode = "0755" },
{ source = "target/release/libsqlglot_rust.so", dest = "/usr/lib64/libsqlglot_rust.so", mode = "0644" },
{ source = "target/release/libsqlglot_rust.a", dest = "/usr/lib64/libsqlglot_rust.a", mode = "0644" },
{ source = "target/ffi/include/sqlglot.h", dest = "/usr/include/sqlglot.h", mode = "0644" },
{ source = "README.md", dest = "/usr/share/doc/sqlglot-rust/README.md", mode = "0644" },
{ source = "LICENSE", dest = "/usr/share/doc/sqlglot-rust/LICENSE", mode = "0644" },
]