From f64fa0e674fee1d33e4b7ab2b4c0170252d0547e Mon Sep 17 00:00:00 2001 From: ssdfasd <2156608475@qq.com> Date: Fri, 20 Mar 2026 13:39:10 +0800 Subject: [PATCH] =?UTF-8?q?docs:=20=E6=B7=BB=E5=8A=A0=20README.md?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..891f588 --- /dev/null +++ b/README.md @@ -0,0 +1,72 @@ +# XCTerminal + +A headless Electron terminal application with a web-based UI. Run terminal sessions in the browser with a 3x2 grid layout. + +## Features + +- Multiple terminal panels in a grid layout (3 columns x 2 rows) +- Real-time terminal output with PowerShell support +- WebSocket and HTTP input support +- Automatic port selection +- Cross-platform (Windows, macOS, Linux) + +## Quick Start + +### Development + +```bash +npm install +npm run dev +``` + +### Build + +```bash +npm run electron:build +``` + +The built executable will be at `release/XCTerminal.exe`. + +### Usage + +```bash +# Run with default port (3002) +./release/XCTerminal.exe + +# Specify port +./release/XCTerminal.exe --port=8080 + +# Or use environment variable +PORT=8080 ./release/XCTerminal.exe +``` + +Then open `http://localhost:3002` (or your specified port) in your browser. + +## Project Structure + +``` +XCTerminal/ +├── electron/ # Electron main process +│ ├── main.js # Main entry point +│ └── preload.js # Preload script +├── src/ # React frontend +│ ├── App.tsx # Main app component +│ └── components/ # UI components +├── server/ # Standalone server (optional) +│ └── index.js # Server entry point +└── release/ # Built executables +``` + +## Tech Stack + +- Electron (headless mode) +- React 19 +- Vite +- Ghostty Web (terminal emulation) +- node-pty (PTY management) +- Express (HTTP server) +- WebSocket (real-time I/O) + +## License + +Private - All rights reserved.