Skip to content

Commit f632a4a

Browse files
build(Mountain): Update build configuration for development profile
Rename the binary, lib, and product to include the development environment profile identifier (DevelopmentNodeEnvironment_MicrosoftVSCodeDependency_22NodeVersion_Bundle_Clean_Debug_ElectronProfile_Mountain) in Cargo.toml and tauri.conf.json. This aligns with the development build pipeline requirements. Additionally: - Add Binary/node to externalBin in tauri.conf.json for the Node.js sidecar - Update posthog-rs 0.5 API: replace deprecated api_endpoint() with host() in PostHogPlugin.rs - Replace sha2 0.11's removed LowerHex impl with hex::encode() in ConfigurationBridge.rs for session ID generation The backup files (Cargo.toml.Backup, tauri.conf.json.Backup) are retained for recovery during this configuration migration.
1 parent 3bcce20 commit f632a4a

6 files changed

Lines changed: 361 additions & 12 deletions

File tree

Cargo.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[[bin]]
2-
name = "Mountain"
2+
name = "DevelopmentNodeEnvironment_MicrosoftVSCodeDependency_22NodeVersion_Bundle_Clean_Debug_ElectronProfile_Mountain"
33
path = "Source/Library.rs"
44

55
[build-dependencies]
@@ -148,7 +148,7 @@ TierOpenExternalLayer4 = []
148148
TierExtensionScanParallel = []
149149

150150
[lib]
151-
name = "Mountain"
151+
name = "DevelopmentNodeEnvironment_MicrosoftVSCodeDependency_22NodeVersion_Bundle_Clean_Debug_ElectronProfile_Mountain"
152152
path = "Source/Library.rs"
153153
crate-type = ["lib", "staticlib"]
154154

@@ -158,11 +158,11 @@ autobenches = false
158158
autobins = false
159159
autoexamples = false
160160
autotests = false
161-
default-run = "Mountain"
161+
default-run = "DevelopmentNodeEnvironment_MicrosoftVSCodeDependency_22NodeVersion_Bundle_Clean_Debug_ElectronProfile_Mountain"
162162
description = "Mountain ⛰️"
163163
edition = "2021"
164164
license-file = "LICENSE"
165-
name = "Mountain"
165+
name = "DevelopmentNodeEnvironment_MicrosoftVSCodeDependency_22NodeVersion_Bundle_Clean_Debug_ElectronProfile_Mountain"
166166
publish = false
167167
include = [
168168
"build.rs",

Cargo.toml.Backup

Lines changed: 192 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,192 @@
1+
[[bin]]
2+
name = "Mountain"
3+
path = "Source/Library.rs"
4+
5+
[build-dependencies]
6+
json5 = { workspace = true }
7+
toml_edit = { workspace = true }
8+
serde = { workspace = true, features = ["derive"] }
9+
serde_json = { workspace = true }
10+
tauri-build = { workspace = true, features = [] }
11+
toml = { workspace = true }
12+
tonic-build = { workspace = true, features = ["transport"] }
13+
tonic-prost-build = { workspace = true }
14+
15+
[dev-dependencies]
16+
tokio-test = { workspace = true }
17+
futures = { workspace = true }
18+
19+
[dependencies]
20+
tauri = { workspace = true, features = [
21+
"compression",
22+
"devtools",
23+
"image-png",
24+
"rustls-tls",
25+
"tray-icon",
26+
"wry",
27+
], default-features = false }
28+
29+
tauri-plugin-dialog = { workspace = true }
30+
tauri-plugin-fs = { workspace = true }
31+
tauri-plugin-localhost = { workspace = true }
32+
tauri-plugin-log = { workspace = true }
33+
34+
async-trait = { workspace = true }
35+
anyhow = { workspace = true } # TODO: Added for error handling in CertificateManager
36+
arboard = { workspace = true }
37+
base64 = { workspace = true }
38+
chrono = { workspace = true, features = ["serde"] }
39+
colored = { workspace = true }
40+
Common = { workspace = true }
41+
dirs = { workspace = true }
42+
Echo = { workspace = true }
43+
Air = { workspace = true, optional = true }
44+
Mist = { workspace = true }
45+
env_logger = { workspace = true }
46+
futures-util = { workspace = true, features = ["sink", "std"] }
47+
globset = { workspace = true }
48+
grep-regex = { workspace = true }
49+
grep-searcher = { workspace = true }
50+
http = { workspace = true }
51+
ignore = { workspace = true }
52+
keyring = { workspace = true }
53+
lazy_static = { workspace = true }
54+
log = { workspace = true }
55+
md5 = { workspace = true }
56+
notify = { workspace = true }
57+
num_cpus = { workspace = true }
58+
once_cell = { workspace = true }
59+
open = { workspace = true }
60+
parking_lot = { workspace = true }
61+
portable-pty = { workspace = true }
62+
portpicker = { workspace = true }
63+
prost = { workspace = true }
64+
rand = { workspace = true }
65+
regex = { workspace = true }
66+
serde = { workspace = true }
67+
serde_json = { workspace = true }
68+
sha2 = { workspace = true }
69+
sysinfo = { workspace = true }
70+
hostname = { workspace = true }
71+
thiserror = { workspace = true }
72+
tokio = { workspace = true, features = ["full"] }
73+
tokio-tungstenite = { workspace = true, features = ["rustls-tls-native-roots"] }
74+
tokio-util = { workspace = true, features = ["full"] }
75+
pem = { workspace = true }
76+
rcgen = { workspace = true }
77+
p256 = { workspace = true }
78+
x509-parser = { workspace = true }
79+
rustls-pki-types = { workspace = true }
80+
rustls = { workspace = true } # TODO: Added for TLS configuration in CertificateManager
81+
toml = { workspace = true }
82+
tonic = { workspace = true }
83+
tonic-prost = { workspace = true }
84+
url = { workspace = true, features = ["serde"] }
85+
uuid = { workspace = true, features = ["v4", "serde"] }
86+
flate2 = { workspace = true }
87+
ring = { workspace = true }
88+
bincode = { workspace = true }
89+
brotli = { workspace = true }
90+
hex = { workspace = true }
91+
opentelemetry = { workspace = true, features = ["trace"] }
92+
posthog-rs = { workspace = true }
93+
zip = { workspace = true }
94+
95+
[features]
96+
default = ["ExtensionHostCocoon", "MistNative", "AirIntegration"]
97+
98+
ExtensionHostCocoon = []
99+
100+
MistNative = []
101+
102+
Debug = []
103+
104+
AirIntegration = ["Air"]
105+
106+
# Feature flags for conditional compilation
107+
grove = []
108+
cocoon = []
109+
terminals = []
110+
debug-protocol = []
111+
scm-support = []
112+
child-processes = []
113+
Telemetry = []
114+
Development = []
115+
Test = []
116+
117+
# ===========================================================================
118+
# Tier-gating (Plan A §Rust feature flags). Every name here is mirrored by
119+
# `build.rs::IsDeclaredTierFeature`. Adding a new tier requires editing
120+
# BOTH places so typos in `.env.Land` fail loud.
121+
# ===========================================================================
122+
123+
# Tier:RemoteProcedureCall:SharedMemory 🟣 Experimental
124+
TierRemoteProcedureCallSharedMemory = []
125+
# Tier:HTTPProxy:Hyper 🟣 Experimental
126+
TierHTTPProxyHyper = []
127+
# Tier:Logger:Ring 🟣 Experimental
128+
TierLoggerRing = []
129+
# Tier:FileSystem:Layer4 🟣 Experimental
130+
TierFileSystemLayer4 = []
131+
# Tier:FindFiles:Layer4 🟣 Experimental
132+
TierFindFilesLayer4 = []
133+
# Tier:Glob:Native 🟣 Experimental - globset-compiled patterns
134+
TierGlobNative = []
135+
# Tier:FileWatcher:Layer4 🟣 Experimental - notify-rs FS events (dep is already on the crate)
136+
TierFileWatcherLayer4 = []
137+
# Tier:SchemeAssets:Hybrid 🟣 Experimental
138+
TierSchemeAssetsHybrid = []
139+
# Tier:Configuration:Eager 🟣 Experimental
140+
TierConfigurationEager = []
141+
# Tier:Diagnostics:Delta 🟣 Experimental
142+
TierDiagnosticsDelta = []
143+
# Tier:Clipboard:Layer4 🟣 Experimental - arboard crate is on the crate unconditionally
144+
TierClipboardLayer4 = []
145+
# Tier:OpenExternal:Layer4 🟣 Experimental - `open` crate is on the crate unconditionally
146+
TierOpenExternalLayer4 = []
147+
# Tier:ExtensionScan:Parallel 🟣 Experimental
148+
TierExtensionScanParallel = []
149+
150+
[lib]
151+
name = "Mountain"
152+
path = "Source/Library.rs"
153+
crate-type = ["lib", "staticlib"]
154+
155+
[package]
156+
authors = ["Source 🖋️ Open 👐🏻 <Source/Open@Editor.Land>"]
157+
autobenches = false
158+
autobins = false
159+
autoexamples = false
160+
autotests = false
161+
default-run = "Mountain"
162+
description = "Mountain ⛰️"
163+
edition = "2021"
164+
license-file = "LICENSE"
165+
name = "Mountain"
166+
publish = false
167+
include = [
168+
"build.rs",
169+
"capabilities/**/*",
170+
"Cargo.toml",
171+
"CHANGELOG.md",
172+
"gen/**/*",
173+
"icons/**/*",
174+
"LICENSE",
175+
"Mountain.key.pub",
176+
"Proto/**/*",
177+
"README.md",
178+
"Source/**/*",
179+
"tauri.conf.json",
180+
"Test/**/*",
181+
]
182+
version = "0.0.1"
183+
184+
[package.metadata.docs.rs]
185+
cargo-args = ["-Zunstable-options", "-Zrustdoc-scrape-examples"]
186+
all-features = true
187+
default-target = "x86_64-unknown-linux-gnu"
188+
targets = [
189+
"x86_64-unknown-linux-gnu",
190+
"x86_64-apple-darwin",
191+
"aarch64-apple-darwin",
192+
]

Source/Binary/Build/PostHogPlugin.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,14 @@ pub async fn Initialize() {
5757
return;
5858
}
5959

60+
// posthog-rs 0.5 renamed `api_endpoint` → `host` on `ClientOptionsBuilder`
61+
// to match the JS/Python SDK vocabulary. Behaviour unchanged: the value is
62+
// the base URL the ingestion client POSTs to. Pass `String`-typed so the
63+
// `#[builder(setter(into, strip_option))]` attribute on `host` wraps it in
64+
// `Some(...)` without another hop.
6065
let Options = posthog_rs::ClientOptionsBuilder::default()
6166
.api_key(POSTHOG_API_KEY.to_string())
62-
.api_endpoint(POSTHOG_HOST.to_string())
67+
.host(POSTHOG_HOST.to_string())
6368
.build()
6469
.expect("PostHog client options");
6570

Source/IPC/ConfigurationBridge.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -594,8 +594,11 @@ impl ConfigurationBridge {
594594
hasher.update(session_data.as_bytes());
595595
let result = hasher.finalize();
596596

597-
// Convert to hex string and take first 16 characters
598-
let hex_string = format!("{:x}", result);
597+
// Convert to hex string and take first 16 characters. sha2 0.11
598+
// dropped the `LowerHex` impl from `Digest::finalize()`'s output
599+
// (now `hybrid_array::Array`); `hex::encode` produces the same
600+
// lowercase-hex string the old `format!("{:x}", …)` emitted.
601+
let hex_string = hex::encode(result);
599602
let session_id = hex_string.chars().take(16).collect::<String>();
600603

601604
dev_log!("config", "[ConfigurationBridge] Generated session ID: {}", session_id);

tauri.conf.json

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,9 @@
6969
"category": "DeveloperTool",
7070
"copyright": "PlayForm",
7171
"createUpdaterArtifacts": false,
72-
"externalBin": [],
72+
"externalBin": [
73+
"Binary/node"
74+
],
7375
"fileAssociations": [],
7476
"homepage": "https://Editor.Land",
7577
"iOS": {
@@ -125,7 +127,9 @@
125127
"publisher": "PlayForm",
126128
"resources": null,
127129
"shortDescription": "",
128-
"targets": ["app"],
130+
"targets": [
131+
"app"
132+
],
129133
"windows": {
130134
"allowDowngrades": true,
131135
"certificateThumbprint": null,
@@ -139,7 +143,7 @@
139143
}
140144
}
141145
},
142-
"identifier": "land.editor.binary",
143-
"productName": "Mountain",
146+
"identifier": "land.editor.binary.development.node.environment.microsoft.vscode.dependency.node.22.bundle.clean.debug.electron.profile.mountain",
147+
"productName": "DevelopmentNodeEnvironment_MicrosoftVSCodeDependency_22NodeVersion_Bundle_Clean_Debug_ElectronProfile_Mountain",
144148
"version": "0.0.1"
145-
}
149+
}

0 commit comments

Comments
 (0)