Warp to Galaxy internal rebrand

This commit is contained in:
2026-08-27 00:29:21 -05:00
parent d72874534d
commit a69b927cc3
108 changed files with 395 additions and 2098 deletions
+3 -6
View File
@@ -3,7 +3,6 @@ use std::path::Path;
use command::r#async::Command;
use galaxy_core::channel::ChannelState;
use galaxy_core::AppId;
use galaxyui::ApplicationBundleInfo;
use instant::Instant;
use objc2::rc::{autoreleasepool, Retained};
@@ -347,7 +346,7 @@ pub fn open_file_path_with_line_and_col(
if let Some(bundle_id) = bundle_id.as_deref() {
let current = ChannelState::app_id().to_string();
if bundle_id != current
&& is_warp_bundle(bundle_id)
&& is_galaxy_bundle(bundle_id)
&& open_with_bundle(&current, full_path)
{
return;
@@ -357,10 +356,8 @@ pub fn open_file_path_with_line_and_col(
ctx.open_file_path(full_path);
}
fn is_warp_bundle(bundle_id: &str) -> bool {
AppId::parse(bundle_id)
.map(|id| id.qualifier() == "dev" && id.organization() == "warp")
.unwrap_or(false)
fn is_galaxy_bundle(bundle_id: &str) -> bool {
bundle_id == "com.galaxy.GalaxyOss"
}
fn open_with_bundle(bundle_id: &str, path: &Path) -> bool {
+9 -12
View File
@@ -1,18 +1,15 @@
use super::is_warp_bundle;
use super::is_galaxy_bundle;
#[test]
fn is_warp_bundle_recognises_warp_channels() {
assert!(is_warp_bundle("dev.warp.Warp"));
assert!(is_warp_bundle("dev.warp.WarpDev"));
assert!(is_warp_bundle("dev.warp.WarpPreview"));
assert!(is_warp_bundle("dev.warp.WarpOss"));
fn is_galaxy_bundle_recognises_oss() {
assert!(is_galaxy_bundle("com.galaxy.GalaxyOss"));
}
#[test]
fn is_warp_bundle_rejects_other_apps() {
assert!(!is_warp_bundle("com.microsoft.VSCode"));
assert!(!is_warp_bundle("com.apple.TextEdit"));
assert!(!is_warp_bundle("dev.zed.Zed"));
assert!(!is_warp_bundle("invalid"));
assert!(!is_warp_bundle(""));
fn is_galaxy_bundle_rejects_other_apps() {
assert!(!is_galaxy_bundle("com.microsoft.VSCode"));
assert!(!is_galaxy_bundle("com.apple.TextEdit"));
assert!(!is_galaxy_bundle("dev.warp.WarpOss"));
assert!(!is_galaxy_bundle("invalid"));
assert!(!is_galaxy_bundle(""));
}