Rebrand to Galaxy, major improvements to Bedrock support, still needs some TLC though
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
use std::sync::Arc;
|
||||
|
||||
use remote_server::auth::RemoteServerAuthContext;
|
||||
use warpui::r#async::BoxFuture;
|
||||
use galaxyui::r#async::BoxFuture;
|
||||
|
||||
use crate::auth::auth_state::AuthState;
|
||||
use crate::server::server_api::auth::AuthClient;
|
||||
|
||||
@@ -3,7 +3,7 @@ use crate::server::server_api::{ServerApiEvent, ServerApiProvider};
|
||||
#[cfg(not(target_family = "wasm"))]
|
||||
use remote_server::manager::RemoteServerManager;
|
||||
#[cfg(not(target_family = "wasm"))]
|
||||
use warpui::SingletonEntity;
|
||||
use galaxyui::SingletonEntity;
|
||||
// Re-export everything from the `remote_server` crate so existing
|
||||
// `crate::remote_server::*` imports in `app` continue to work.
|
||||
pub use remote_server::*;
|
||||
@@ -54,16 +54,16 @@ pub fn run_daemon(_identity_key: String) -> anyhow::Result<()> {
|
||||
/// ```
|
||||
#[cfg(not(target_family = "wasm"))]
|
||||
pub(super) fn run_daemon_app(
|
||||
server_model_init: impl FnOnce(&mut warpui::ModelContext<server_model::ServerModel>) -> server_model::ServerModel
|
||||
server_model_init: impl FnOnce(&mut galaxyui::ModelContext<server_model::ServerModel>) -> server_model::ServerModel
|
||||
+ 'static,
|
||||
) -> anyhow::Result<()> {
|
||||
use warpui::platform::app::AppCallbacks;
|
||||
use warpui::platform::AppBuilder;
|
||||
use galaxyui::platform::app::AppCallbacks;
|
||||
use galaxyui::platform::AppBuilder;
|
||||
|
||||
AppBuilder::new_headless(AppCallbacks::default(), Box::new(()), None).run(|ctx| {
|
||||
// Rotate log files from the previous daemon invocation in the background.
|
||||
ctx.background_executor()
|
||||
.spawn(warp_logging::rotate_log_files())
|
||||
.spawn(galaxy_logging::rotate_log_files())
|
||||
.detach();
|
||||
|
||||
use crate::server::telemetry::context_provider::NoopTelemetryContextProvider;
|
||||
@@ -82,7 +82,7 @@ pub(super) fn run_daemon_app(
|
||||
ctx.add_singleton_model(DirectoryWatcher::new);
|
||||
ctx.add_singleton_model(|_ctx| DetectedRepositories::default());
|
||||
ctx.add_singleton_model(RepoMetadataModel::new_with_incremental_updates);
|
||||
ctx.add_singleton_model(warp_files::FileModel::new);
|
||||
ctx.add_singleton_model(galaxy_files::FileModel::new);
|
||||
ctx.add_singleton_model(server_model_init);
|
||||
})?;
|
||||
Ok(())
|
||||
@@ -90,7 +90,7 @@ pub(super) fn run_daemon_app(
|
||||
|
||||
/// Forwards app auth-token rotation events to the remote-server manager.
|
||||
#[cfg(not(target_family = "wasm"))]
|
||||
pub fn wire_auth_token_rotation(ctx: &mut warpui::AppContext) {
|
||||
pub fn wire_auth_token_rotation(ctx: &mut galaxyui::AppContext) {
|
||||
let server_api = ServerApiProvider::handle(ctx);
|
||||
let manager = RemoteServerManager::handle(ctx);
|
||||
ctx.subscribe_to_model(&server_api, move |_, event, ctx| {
|
||||
|
||||
@@ -5,16 +5,16 @@ use std::collections::{HashMap, HashSet};
|
||||
use std::future::Future;
|
||||
use std::path::{Path, PathBuf};
|
||||
use std::sync::Arc;
|
||||
use warp_core::channel::ChannelState;
|
||||
use warp_core::SessionId;
|
||||
use warp_util::standardized_path::StandardizedPath;
|
||||
use warpui::platform::TerminationMode;
|
||||
use warpui::r#async::{Spawnable, SpawnableOutput, SpawnedFutureHandle};
|
||||
use warpui::{Entity, ModelContext, SingletonEntity};
|
||||
use galaxy_core::channel::ChannelState;
|
||||
use galaxy_core::SessionId;
|
||||
use galaxy_util::standardized_path::StandardizedPath;
|
||||
use galaxyui::platform::TerminationMode;
|
||||
use galaxyui::r#async::{Spawnable, SpawnableOutput, SpawnedFutureHandle};
|
||||
use galaxyui::{Entity, ModelContext, SingletonEntity};
|
||||
|
||||
use warp_files::{FileModel, FileModelEvent};
|
||||
use warp_util::content_version::ContentVersion;
|
||||
use warp_util::file::FileId;
|
||||
use galaxy_files::{FileModel, FileModelEvent};
|
||||
use galaxy_util::content_version::ContentVersion;
|
||||
use galaxy_util::file::FileId;
|
||||
|
||||
use super::proto::{
|
||||
client_message, delete_file_response, run_command_response, server_message,
|
||||
|
||||
@@ -11,7 +11,7 @@ use std::process::Stdio;
|
||||
use std::sync::Arc;
|
||||
|
||||
use anyhow::Result;
|
||||
use warpui::r#async::executor;
|
||||
use galaxyui::r#async::executor;
|
||||
|
||||
use remote_server::auth::RemoteServerAuthContext;
|
||||
use remote_server::client::RemoteServerClient;
|
||||
@@ -188,7 +188,7 @@ impl RemoteTransport for SshTransport {
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
use warpui::r#async::BoxFuture;
|
||||
use galaxyui::r#async::BoxFuture;
|
||||
fn static_auth_context() -> Arc<RemoteServerAuthContext> {
|
||||
Arc::new(RemoteServerAuthContext::new(
|
||||
|| -> BoxFuture<'static, Option<String>> { Box::pin(async { None }) },
|
||||
|
||||
@@ -16,7 +16,7 @@ mod proxy;
|
||||
use super::server_model::{ConnectionId, ServerModel};
|
||||
use std::fs::Permissions;
|
||||
use std::os::unix::fs::PermissionsExt;
|
||||
use warpui::r#async::executor;
|
||||
use galaxyui::r#async::executor;
|
||||
|
||||
/// Run the `remote-server-proxy` subcommand.
|
||||
///
|
||||
@@ -40,9 +40,9 @@ pub fn run_daemon(identity_key: String) -> anyhow::Result<()> {
|
||||
// The file is written to the same directory as client logs (~/Library/Logs
|
||||
// on macOS, ~/.local/share/warp-terminal on Linux). Since the daemon runs
|
||||
// on the remote host, there is no conflict with client-side log files.
|
||||
warp_logging::init(warp_logging::LogConfig {
|
||||
galaxy_logging::init(galaxy_logging::LogConfig {
|
||||
is_cli: true,
|
||||
log_destination: Some(warp_logging::LogDestination::File),
|
||||
log_destination: Some(galaxy_logging::LogDestination::File),
|
||||
})?;
|
||||
|
||||
// socket_path: ~/.warp[-channel]/remote-server/{identity_key}/server.sock
|
||||
@@ -137,7 +137,7 @@ pub fn run_daemon(identity_key: String) -> anyhow::Result<()> {
|
||||
pub(super) async fn handle_daemon_connection(
|
||||
conn_id: ConnectionId,
|
||||
stream: async_io::Async<std::os::unix::net::UnixStream>,
|
||||
spawner: warpui::ModelSpawner<ServerModel>,
|
||||
spawner: galaxyui::ModelSpawner<ServerModel>,
|
||||
exec: std::sync::Arc<executor::Background>,
|
||||
) {
|
||||
use futures::io::{AsyncWriteExt, BufReader, BufWriter};
|
||||
|
||||
Reference in New Issue
Block a user