@smbcloud / cli / commits / 8d7a2a3

Refactor Runner::git_host to use dynamic subdomain

Seto Elkahfi committed Jun 28, 2025 at 17:18 UTC 8d7a2a3ec2cefe8093a46db007d3b84b5ac45440
1 file changed +7 -3
crates/cli/src/project/runner.rs
+7 -3
@@ -10,10 +10,14 @@ pub(crate) enum Runner {
10 }
11
12 impl Runner {
13 - pub fn git_host(&self) -> &str {
13 + pub fn git_host(&self) -> String {
14 + format!("git@{}.smbcloud.xyz", self.api())
15 + }
16 +
17 + fn api(&self) -> &str {
18 match self {
15 - Runner::Swift => "git@api.musik88.com",
16 - _ => "git@api.smbcloud.xyz",
19 + Runner::NodeJs => "api",
20 + Runner::Ruby | Runner::Swift => "api-1",
21 }
22 }
23 }