Skip to content

About

A Simple Terminal based on Electron & NodeJS

Resources

Stars

5 stars

Watchers

1 watching

Forks

Latest commit

Β 

History

1,358 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

SimpleShell

A powerful cross-platform SSH terminal application built with Electron + React

δΈ­ζ–‡ | Download | Features | Development

Version License Platform

Overview

SimpleShell is a modern, feature-rich SSH terminal application that combines the power of Electron's desktop capabilities with React's intuitive development experience. Designed for developers and system administrators who need efficient remote server management.

Features

πŸ”Œ Connection Management

  • Multi-Protocol Support: SSH, Telnet, Serial (COM), Mosh, and local PowerShell terminals
  • SSH Compression: Optional per-connection zlib compression (zlib@openssh.com / zlib, falling back to none) for low-bandwidth links; Compression yes is picked up from imported OpenSSH configs
  • Connection Pooling: Intelligent connection reuse to minimize resource usage
  • OpenSSH Config Import: Parse ~/.ssh/config and batch-import hosts in one click (supports HostName/Port/User/IdentityFile/ForwardAgent, Host wildcard & negation patterns, and global defaults; hosts using ProxyJump/ProxyCommand are flagged for manual jump configuration)
  • SSH Agent Forwarding: Enable forwarding with password, private-key, or agent login. Password/private-key connections keep their login methods when forwarding is enabled; imported ForwardAgent yes applies to those connections too. The local agent path is configurable; reconnect after changing this setting.
  • Serial Console: Direct serial/COM connections with configurable baud rate, data bits, stop bits, parity, and flow control; each tab holds an exclusive session per port
  • Mosh Support: Weak-network/roaming-friendly sessions via a locally hosted mosh client (SSH bootstrap; interactive authentication happens in the terminal). On Windows, run through WSL or point to an MSYS2/Cygwin mosh binary; prediction mode (adaptive/always/never/experimental) and a custom mosh-server port are configurable.
  • Mosh Roaming Status: The connection indicator follows the focused pane and displays running, waiting for recovery, or exited. Waiting follows the stock Mosh client's network notice; keep the tab open during an outage or network change so the client can recover the existing session. This is a display hint, not a UDP latency measurement; SSH probes do not restart Mosh sessions.
  • Smart Tabs: Drag-drop tab reordering, merging, and split-screen support
  • Split Terminal: Drag a tab onto the middle of another tab (stack-merge) or into the terminal area to merge it into a split view (up to 2Γ—2 panes); right-click the merged tab β†’ "Unsplit & Restore Tabs" to restore panes back to standalone tabs β€” sessions and terminal content are preserved on both merge and unsplit; each pane an independent session that can connect to a different host; drag pane headers to swap, drag dividers to resize; panes compose with sync-input groups for batch ops (Ctrl+Shift+W closes the focused pane) Closing a pane ends only that session, including the root pane; closing other panes retains exactly the selected session. Split tabs must be restored to standalone tabs before they can be merged into another tab.
  • Group Synchronization: Execute commands across multiple connections simultaneously
  • Active Session Tools: Resource monitoring, file management, AI, and quick commands follow the focused pane. File navigation and AI conversations/drafts stay separate for each session; switching SSH panes keeps the file sidebar open.
  • Visual Server Map: Geographic visualization of server locations worldwide

πŸ“ Advanced File Management

  • Full SFTP Browser: Intuitive file browsing with drag-drop operations
  • Native SFTP Operations: Directory browsing, file reads/writes, and transfers run in the Rust service. Uploads have no file-count cap. Dragged upload conflict checks submit the complete path list and use eight concurrent metadata reads on one session; JavaScript owns task scheduling, retries, and resume manifests.
  • Follow Terminal Directory: A persistent global option in Settings β†’ General lets SFTP follow the focused SSH terminal, with directory state isolated per tab or split session. Enabled by default.
  • Bulk Transfers: Upload/download entire folders with progress tracking
  • Resumable SFTP Transfers: Pause, reconnect, or restart the app and resume retained files from the transfer panel; files of 128 MiB or larger resume by completed segments
  • Integrity Verification: Optional SHA-256 by default or MD5 per task, streamed over SFTP without shell access; a mismatch triggers exactly one full-file retransmission and reports both hashes if it fails again
  • Smart Caching: Multi-level cache for improved file access speed
  • File Preview: Built-in viewer for text, images, code, and PDFs

πŸ€– AI-Powered Assistant

  • Intelligent Command Helper: AI assistant for command suggestions and explanations
  • Multi-Model Support: Configurable AI providers and models
  • Streaming Responses: Real-time AI responses with context awareness
  • Worker Thread Processing: Non-blocking AI operations for smooth performance

🎨 User Experience

  • Modern UI: Material-UI v7 with smooth animations and transitions
  • Theme Support: Dark and light modes with system preference detection
  • Command History: Intelligent command suggestions and auto-completion
  • Multi-Language: Full internationalization (English and Chinese)
  • Shortcut Management: Custom command shortcuts and macros

πŸ“Š Monitoring & Tools

  • Resource Monitor: Real-time CPU, memory, and network statistics
  • Remote System Info: Monitor remote server performance via SSH
  • Network Diagnostics: IP address lookup with geolocation
  • Security Tools: Built-in password generator with customizable rules

⚑ Performance Optimizations

  • Lazy Loading: Components loaded on-demand for faster startup
  • Backpressure Control: Stable file transfers with flow control
  • Connection Health Monitoring: Automatic reconnection and failover

Installation

Linux One-line Install

curl -fsSL https://raw.githubusercontent.com/funkpopo/simpleshell/master/scripts/install-linux.sh | sh

Install a specific version:

curl -fsSL https://raw.githubusercontent.com/funkpopo/simpleshell/master/scripts/install-linux.sh | SIMPLESHELL_VERSION=0.4.39 sh

The script detects Debian/Ubuntu .deb and Fedora/RHEL/openSUSE .rpm systems, then downloads the matching latest package for the current CPU architecture from GitHub Releases.

Download Pre-built Binaries

Download the latest release for your platform from the Releases page.

  • Windows: .exe installer
  • Linux: .deb or .rpm package
  • macOS: no prebuilt package yet; build from source (npm run make -- --platform=darwin)

Build from Source

If you prefer to build from source, follow the development instructions below.

Development

Vitest suites under tests/unit cover contracts, architecture boundaries and application behavior. tests/integration covers Electron rendering, production bundles and real Rust services. All verification runs locally: npm run lint and npm test run lint and unit tests; npm run test:integration runs the native/Electron suites.

Prerequisites

  • Node.js 22.22.2+ (22 LTS) or 24.15.0+ and npm
  • Git
  • Rust stable toolchain with cargo (npm start / package / make build the simpleshell-core native host; there are no Node native addons, so Python/node-gyp is not needed)
  • Build tools for your platform (for the Rust linker):
    • Windows: Visual Studio Build Tools (MSVC, "Desktop development with C++")
    • macOS: Xcode Command Line Tools
    • Linux: build-essential package
  • Windows installer (npm run make): Built-in NSIS packaging via electron-builder (no external Inno Setup installation required)

Setup

# Clone the repository
git clone https://github.com/funkpopo/simpleshell.git
cd simpleshell

# Install dependencies
npm install

Development Mode

# Start development server with hot reload
npm run start

This will:

  • Start the Webpack dev server on port 3001
  • Launch Electron in development mode
  • Enable hot module replacement for React components

Available Scripts

npm start                 # Build/stage the native host if needed, then run Forge dev mode
npm run lint              # ESLint for the whole repository
npm run typecheck         # JSDoc type checking for src/preload and src/shared
npm test                  # Unit, contract and architecture tests (Vitest)
npm run check             # Full static + unit verification (lint + typecheck + test)
npm run test:integration  # Electron, native service and production bundle tests
npm run format            # Prettier write
npm run format:check      # Prettier verification
npm run package           # Package the app for the current platform
npm run make              # Build distributable installers

Integration tests need a compiled native host: cargo build --locked --manifest-path native-services/Cargo.toml.

Preload contracts use JSDoc and shared declarations in src/shared/contracts/preload.d.ts. npm run typecheck (also exercised by npm run check and npm test) checks all src/preload/**/*.js and src/shared/**/*.js modules using tsconfig.preload.json. Every ipcRenderer.invoke / send in the preload is checked against the per-domain channel schemas in src/shared/contracts/ipc/domains/, the same schemas main validates at runtime, with full strict checking enabled (including noImplicitAny and strictFunctionTypes). The editor-discoverable src/preload/tsconfig.json inherits the same configuration. Raw IPC responses that have no detailed contract remain unknown and must be narrowed by callers; this check does not type-check the renderer or main-process handlers.

Build for Production

# Build for current platform
npm run make

# Build for specific platform
npm run make -- --platform=win32
npm run make -- --platform=darwin
npm run make -- --platform=linux

On Windows, npm run make builds/stages simpleshell-core, packages the Electron app, and invokes the custom NSIS Forge maker (scripts/makers/maker-nsis.js via electron-builder) to produce installer/SimpleShell-v<version>-Setup-<arch>.exe directly with no external Inno Setup dependency.

Project Structure

simpleshell/
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ main/                # Electron lifecycle, IPC, sessions, storage, native clients
β”‚   β”œβ”€β”€ preload/             # contextBridge API and subscriptions
β”‚   β”œβ”€β”€ renderer/            # React UI, terminal views and browser helpers
β”‚   └── shared/              # Contracts, pure cross-runtime logic and locales
β”œβ”€β”€ native-services/         # Rust workspace for simpleshell-core
β”œβ”€β”€ installer/               # Generated Windows NSIS installer output directory
β”œβ”€β”€ tests/                   # Unit, contract and integration suites, helpers and fixtures
β”œβ”€β”€ scripts/                 # Native host staging, Forge makers and postinstall helpers
β”œβ”€β”€ forge.config.js
└── webpack.*.config.js

Source is organized by runtime. Area-specific conventions live in README files next to the code (for example src/main/file-transfer/ and src/renderer/features/).

Tech Stack

Core Technologies

  • Electron 40.4.1 - Cross-platform desktop framework
  • React 19.2.8 - UI library (React 19)
  • Material UI 9.2.0 - Component library
  • Electron Forge + Webpack + ESLint/Prettier - Build and code quality toolchain
  • JavaScript/JSX + Babel toolchain (no TypeScript build in this repo)

Terminal & SSH

  • xterm.js 6.1.0-beta.167 - Terminal emulator + add-ons
    • @xterm/addon-fit, @xterm/addon-webgl
  • ssh2 1.17.0 - dev dependency only: loopback SSH servers in tests (the app's SSH client runs in the Rust core)

Native Services Host

  • Rust core (native-services/) - resident simpleshell-core process hosting SSH terminals, the terminal output pipeline, SFTP, transfers, port forwarding, ZMODEM, local pseudo terminals (ConPTY / portable-pty), serial ports, Telnet, system metrics and network services as multiplexed streams (see native-services/README.md). The app ships no Node native addons.

Editing, Preview & Rendering

  • CodeMirror 6 (@codemirror/*, @uiw/react-codemirror) - Syntax highlighting and editors
  • react-markdown + remark-gfm - Markdown rendering
  • react-pdf - PDF preview
  • DND kit (@dnd-kit/*) - Drag-and-drop interactions

Internationalization, UI & Utilities

  • i18next + react-i18next - Internationalization
  • react-simple-maps - World map visualization
  • Proxy support: http-proxy-agent, https-proxy-agent, socks-proxy-agent
  • Performance helpers: react-window

Connection Architecture

src/main/connection/ owns protocol pools, reconnection and connection orchestration; connectionManager.js composes the pools. Terminal sessions live in src/main/terminal/, SFTP task orchestration in src/main/file-transfer/, and Rust clients in src/main/native/.

Renderer accesses these capabilities through preload. IPC definitions and terminal protocols live in src/shared/contracts/; neither runtime imports the other runtime implementation.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

Support

If you encounter any issues or have questions:

  • Open an issue on GitHub Issues
  • Check existing issues for solutions
  • Provide detailed information about your environment and the problem

License

Distributed under the Apache License 2.0. See LICENSE for more information.

Author

funkpopo - funkpopoisme@gmail.com

About

A Simple Terminal based on Electron & NodeJS

Resources

Stars

5 stars

Watchers

1 watching

Forks

Releases

Used by

Contributors

Languages