euv-cli 0.48.2

Cross-platform CLI tool for the euv native UI framework supporting run, build, check, fmt, doctor, new, and Hyperlane SSE dynamic updates across all supported platforms.
Documentation
//! euv-cli
//!
//! Cross-platform command-line toolchain for euv providing native run, build,
//! hot-reload dev server, Hyperlane HTTP/SSE dynamic update server, Markdown
//! documentation site builder, cross-target check, formatting, environment
//! diagnostics, and project scaffolding across all supported platforms.

mod args;
mod command;
mod fmt;
mod hot;
mod platform;
mod update_server;

#[cfg(test)]
#[path = "../tests/mod.rs"]
mod tests;

pub use {args::*, command::*, fmt::*, hot::*, platform::*, update_server::*};

#[cfg(feature = "update-server")]
use std::collections::HashMap;
#[cfg(feature = "update-server")]
use std::net::AddrParseError;
#[cfg(feature = "update-server")]
use std::sync::{OnceLock, RwLock, RwLockReadGuard};
use std::{
    borrow::Cow,
    cmp,
    collections::{BTreeMap, btree_map},
    env::{self, VarError},
    ffi::{OsStr, OsString},
    fs::{self, DirEntry, File, Metadata, OpenOptions},
    io::{self, BufRead, BufReader, Error, ErrorKind, Write},
    iter::Peekable,
    net::{SocketAddr, TcpListener, TcpStream},
    num::NonZeroUsize,
    path::{Path, PathBuf},
    process::{self, Child, Command, Output, Stdio},
    str::SplitWhitespace,
    sync::{
        Arc, Mutex, MutexGuard,
        atomic::{AtomicBool, AtomicU64, Ordering},
    },
    thread::{self, JoinHandle, Scope, ScopedJoinHandle},
    time::{Duration, SystemTime, UNIX_EPOCH},
};

use {
    clap::{Args, Parser, Subcommand, ValueEnum},
    crate_cli::{UnifiedFmtReport, execute_unified_fmt, format_workspace_text_files},
    euv_core::{
        ClientNegotiation, DEFAULT_MAX_ARTIFACT_BYTES, DYNAMIC_EVENT_SCHEMA_V1,
        DYNAMIC_HOST_ABI_V1, DYNAMIC_MANIFEST_SCHEMA_V1, DYNAMIC_PROTOCOL_VERSION_V1,
        DeliveryChannelMode, DynamicReleaseError, GraphicsBackend, PlatformCapabilities,
        PlatformKind, ReleaseActivatedEvent, ReleaseManifest, RenderConfig, RenderMode, Renderer,
        build_partial_widget_wasm, compute_wasm_checksum, compute_wasm_signature, constant_time_eq,
        default_track_for, is_valid_sha256_hex, sha256_hex,
    },
    euv_docs::{DocsBuildOptions, GeneratedSiteReport, build_docs_bundle},
    lombok_macros::{Data, Getter, New},
    serde::{Deserialize, Serialize},
    serde_json::{from_str, to_string, to_string_pretty},
    tokio::runtime::{Builder, Runtime},
};
#[cfg(feature = "update-server")]
use {
    euv_core::SSE_EVENT_RELEASE_ACTIVATED,
    hyperlane::{
        CACHE_CONTROL, CONTENT_TYPE, Context, Method, ResponseData, ResponseError, Server,
        ServerConfig, ServerControlHook, ServerError, ServerHook, Status, Stream,
        tokio::{
            runtime, select, task,
            time::{Instant, Interval, MissedTickBehavior, interval},
        },
    },
    hyperlane_plugin_sse::{SseConfig, SseError, SseEvent, SseHub, SseStream, SseSubscription},
    serde_json::to_vec,
};