Repository navigation
Expand file tree
/
Copy pathCargo.toml
More file actions
123 lines (117 loc) · 6.22 KB
/
Copy pathCargo.toml
File metadata and controls
123 lines (117 loc) · 6.22 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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
# SPDX-License-Identifier: GPL-2.0-only
[workspace]
resolver = "3"
members = ["crates/*"]
[workspace.package]
# The in-repo version. Every frontend reports it via CARGO_PKG_VERSION (the GUI
# About card, `modrix --version`), and the in-app updater compares it to the
# latest GitHub release tag. The Release workflow re-stamps this from the pushed
# `v*` tag, so a tag is always authoritative and code/About/release stay in sync.
version = "0.1.0-beta.3"
edition = "2024"
rust-version = "1.99"
license = "GPL-2.0-only"
authors = ["Modrix contributors"]
[workspace.dependencies]
# --- internal crates ---
modrix-core = { path = "crates/modrix-core" }
modrix-plugin = { path = "crates/modrix-plugin" }
modrix-download = { path = "crates/modrix-download" }
modrix-ipc = { path = "crates/modrix-ipc" }
modrix-il2cpp = { path = "crates/modrix-il2cpp" }
modrix-interop-gen = { path = "crates/modrix-interop-gen" }
modrix-mcp = { path = "crates/modrix-mcp" }
modrix-registry = { path = "crates/modrix-registry" }
modrix-service = { path = "crates/modrix-service" }
modrix-update = { path = "crates/modrix-update" }
# --- external (pinned; further deps added per phase as they are used) ---
anyhow = "1"
thiserror = "2"
directories = "5"
rusqlite = { version = "0.43", features = ["bundled"] }
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
clap = { version = "4", features = ["derive", "env"] }
tempfile = "3"
# --- async runtime (Phase 2) ---
# The HTTP client is assembled from hyper + rustls (ring provider) + the OS
# trust store. It is small and already audited against our usage; it is a
# choice, not a rule (see docs/ARCHITECTURE.md §11).
tokio = { version = "1", default-features = false, features = [
"rt-multi-thread", "macros", "net", "io-util", "fs", "sync", "time",
] }
hyper = { version = "1", features = ["client", "http1"] }
hyper-util = { version = "0.1", default-features = false, features = ["tokio"] }
http-body-util = "0.1"
tokio-rustls = { version = "0.26", default-features = false, features = ["tls12", "logging"] }
rustls = { version = "0.23", default-features = false, features = ["std", "tls12", "logging", "ring"] }
rustls-native-certs = "0.8" # OS trust store (avoids CDLA webpki-roots)
getrandom = "0.3"
# Native GPU UI: Rune's renderer, layout, text and springs, plus its
# component kit. Pinned to one `dev` rev; the [patch.crates-io] block at the
# bottom must use the same URL and rev (Rune ships patched winit/wgpu-hal/etc).
rune = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7", features = ["native-file-dialog"] }
rune-kit = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7", default-features = false }
# FOMOD installer config parsing (read-only XML DOM).
roxmltree = "0.20"
# Decode Steam artwork + bake the per-game backdrop / extract accent colors
# (GUI only).
image = { version = "0.24", default-features = false, features = ["jpeg", "png"] }
# Sandboxed Lua host for Tier-2 game plugins (vendors Lua 5.4).
mlua = { version = "0.10", default-features = false, features = ["lua54", "vendored"] }
# Native file-open dialogs via the XDG portal (no GTK linkage).
rfd = { version = "0.15", default-features = false, features = ["xdg-portal", "tokio"] }
serde = { version = "1", features = ["derive"] }
wiremock = "0.6"
serde_json = "1"
# Semantic-version comparison for the in-app updater.
semver = "1"
toml = "0.8"
# Windows registry reads for non-Steam store detection (GOG / Xbox / Uplay /
# vendor keys like Bethesda Softworks). Target-gated to cfg(windows). Its
# FFI `unsafe` lives inside the crate, not ours (workspace forbids unsafe).
winreg = "0.52"
sha2 = "0.10"
md-5 = "0.10" # Nexus publishes file MD5s; RustCrypto
# zip for reading mod archives. We DECOMPRESS only, so the pure-Rust flate2
# (miniz_oxide) backend is all that is needed; `deflate` (zopfli) would add a
# compressor we never use.
zip = { version = "9", default-features = false, features = ["deflate-flate2"] }
flate2 = { version = "1", default-features = false, features = ["rust_backend"] }
proptest = "1"
# --- Power of Ten for Rust - enforced workspace-wide (see docs/ARCHITECTURE.md §9.3) ---
[workspace.lints.rust]
unsafe_code = "forbid"
unreachable_code = "deny"
unreachable_patterns = "deny"
unused = { level = "deny", priority = -1 }
[workspace.lints.clippy]
pedantic = { level = "warn", priority = -1 }
unwrap_used = "deny" # `.unwrap()` is a silent abort-on-error
panic = "deny"
todo = "deny"
unimplemented = "deny"
expect_used = "warn" # justified form: `.expect("why it can't fail")`
indexing_slicing = "deny" # `v[i]` can panic; use `.get(i)`
arithmetic_side_effects = "warn" # promote to "deny" in modrix-core
mem_forget = "deny"
undocumented_unsafe_blocks = "warn"
allow_attributes = "warn" # prefer `#[expect(..)]` over `#[allow(..)]`
allow_attributes_without_reason = "warn"
dbg_macro = "warn"
print_stdout = "warn" # frontends print via their own sink, not core
print_stderr = "warn"
[profile.release]
overflow-checks = true # Power of Ten: no silent integer wraparound
# Rune's patched windowing/text/GPU crates. Cargo does not inherit a
# dependency's patches, so they live here at the same rev as `rune` above.
# Re-check Rune's own Cargo.toml [patch.crates-io] list whenever the rev moves.
[patch.crates-io]
winit = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7" }
sctk-adwaita = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7" }
parley_engine = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7" }
wgpu-hal = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7" }
naga = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7" }
accesskit_windows = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7" }
accesskit_macos = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7" }
accesskit_atspi_common = { git = "https://github.com/anomalyco/rune", rev = "e6f70eb09762180b86dcef912fe169a315bc31b7" }