Skip to main content

euv_cli/
lib.rs

1//! euv-cli
2//!
3//! Cross-platform command-line toolchain for euv providing native run, build,
4//! hot-reload dev server, dynamic WASM OTA hot-update server, Markdown
5//! documentation site builder, cross-target check, formatting, environment
6//! diagnostics, and project scaffolding across all seven platforms.
7
8mod args;
9mod command;
10mod fmt;
11mod hot;
12mod platform;
13
14#[cfg(test)]
15#[path = "../tests/mod.rs"]
16mod tests;
17
18pub use {args::*, command::*, fmt::*, hot::*, platform::*};
19
20use std::{
21    borrow::Cow,
22    cmp,
23    collections::{BTreeMap, btree_map},
24    env::{self, VarError},
25    ffi::{OsStr, OsString},
26    fs::{self, DirEntry, Metadata},
27    io::{self, BufRead, BufReader, Error, ErrorKind, Write},
28    iter::Peekable,
29    net::{SocketAddr, TcpListener, TcpStream},
30    num::NonZeroUsize,
31    path::{Path, PathBuf},
32    process::{Child, Command, Output, Stdio},
33    str::SplitWhitespace,
34    sync::{
35        Arc, Mutex, MutexGuard,
36        atomic::{AtomicBool, AtomicU64, Ordering},
37    },
38    thread::{self, JoinHandle, Scope, ScopedJoinHandle},
39    time::{Duration, SystemTime, UNIX_EPOCH},
40};
41
42use {
43    clap::{Args, Parser, Subcommand, ValueEnum},
44    crate_cli::{UnifiedFmtReport, execute_unified_fmt, format_workspace_text_files},
45    euv_core::{
46        GraphicsBackend, PlatformCapabilities, PlatformKind, RenderConfig, RenderMode, Renderer,
47        build_partial_widget_wasm, compute_wasm_checksum, compute_wasm_signature,
48    },
49    euv_docs::{DocsBuildOptions, GeneratedSiteReport, build_docs_bundle},
50    lombok_macros::{Data, Getter, New},
51    serde::{Deserialize, Serialize},
52    serde_json::to_string_pretty,
53    tokio::runtime::{Builder, Runtime},
54};