- Move the Terminal plugin into src/lib/features/terminal/ on the host Svelte runtime, with xterm 6.0.0 and addon-fit 0.11.0. - Buttons, shortcuts, Help rows, and the close guard follow the Terminal switch. The first use loads the module. - Add Settings → Terminal and the terminal settings section. The first start copies the old runestone.terminal key. - The 16 ANSI colors come from the --rs-ansi-* tokens. - Off asks first when a shell runs in any window (pty_running). - Rust: no pty-data or pty-exit events, an owner check for write, resize, and close, output joined up to 64 KiB or 8 ms, and the sessions of a reloaded page close. - Remove api.pty, the terminal contribution, TerminalSlot, and the plugin loader of the smoke harness. - Check only the tested switches in the Background smoke test. - Update the tests, the menu inventory, the docs, and UI-058.
5.9 KiB
Linux development
Development · Build Linux packages · Install on Linux
This guide gives the Linux-specific parts of source development and the native desktop checks for Linux. For the general source setup, use Run from source.
Prerequisites
- The tools in Run from source: Node.js 24, pnpm 10, and a stable Rust toolchain.
- The native libraries in Tauri's Linux prerequisites, including GTK and WebKitGTK 4.1.
- A graphical desktop session.
- A terminal with
node,pnpm, andcargoon itsPATH. If a command is missing, load the environment that its installer configured.
Do not copy node_modules, src-tauri/target, or src-tauri/browser-engine from a Windows checkout. They contain platform-specific binaries.
Record the environment
Run these commands in the Linux session that you use for native checks:
cat /etc/os-release
uname -m
printf 'Desktop: %s\nSession: %s\n' "$XDG_CURRENT_DESKTOP" "$XDG_SESSION_TYPE"
Record the distribution, version, processor architecture, desktop, and session type with the source commit and the test results. Test Wayland and X11 separately before you claim support for both. An x86_64 test does not prove ARM64 support.
Browser runtime on Linux
Use the general steps in Built-in browser runtime. On Linux, these differences apply:
- Package and stage the runtime on the same architecture as the host build.
npm --prefix browser-runtime run packageselects the current platform and architecture.package:linuxalways builds x86_64. Do not use it on ARM64. pnpm browser:stagestops when the packaged runtime does not match the current platform and architecture.- Staging makes sure that the
RuneStone-Browserfile is executable and sets the runtime folder to mode 755. - Staging replaces the full
src-tauri/browser-enginefolder, so no files from an older package stay. It moves the previous folder tooutput/browser-stage-backups/.
The Browser runtime always runs with the Electron sandbox. It stops when it receives --no-sandbox.
Run RuneStone as an ordinary desktop user, not as root.
Some distributions limit user namespaces, which the sandbox can need. Test the Browser on each target distribution.
The native host uses WebKitGTK and the Browser uses Electron. Test both.
Linux packages do not include the engine, and no Linux engine download exists yet. A package says that no engine is available for the platform. pnpm tauri dev starts the staged engine.
Checks
Run the source checks in Checks and the tests in Browser smoke tests.
Then run pnpm tauri dev in the graphical session for the desktop checks below.
The source checks do not prove desktop compatibility. Browser smoke tests use Chromium and simulated desktop calls. They do not test Linux file access or WebKitGTK.
Desktop checks
Use a disposable workspace outside the installation folder. Record each result, the source commit, and any error message. Voice typing is not part of the Linux checks.
| Area | Pass criteria |
|---|---|
| Launch and windows | Open from the desktop. Move, resize, minimize, maximize, and close. Unsaved edits start the close guard. |
| Files and paths | Create, save, open again, rename, copy, and delete files. Check spaces, Unicode, and distinct Note.md and note.md files. |
| External edits | Edit a file in a different editor. RuneStone finds the change and does not silently replace conflicting edits. |
| Built-in Browser | In pnpm tauri dev with the staged engine, open a web page, type, scroll, open and close tabs, download a file, and restart the app. In a package, a browser tab says that no engine is available. |
| Editors | Edit Markdown, source code, tables, images, and diagrams. Check undo, keyboard shortcuts, and both themes. |
| Clipboard and dialogs | Copy and paste text, tables, and images. Check folder selection, external links, and file reveal. |
| Plugins | Install plugin ZIPs through Settings, enable them, restart, disable them, and remove them. Check that plugin data stays. |
| Terminal | Open the terminal panel. Bash starts in the workspace, accepts Unicode, resizes, and exits when its session closes. |
| Settings | Change preferences, restart, and make sure that they stay. Check separate workspace windows. |
For the use of Terminal, see the Terminal guide.
Check terminal profiles after a desktop launch too. A desktop launcher can have a different PATH from an interactive shell.
Known Linux limits:
- RuneStone rejects some names that Linux permits, for example names with
:or\. Use portable filenames for baseline checks. Record a rejected name as a limit. - On Linux, RuneStone uses the polling watcher only for paths that start with
//. A share mounted at an ordinary path uses the native watcher, which can miss changes from other computers. Test network workspaces separately.
Package builds
Use Build Linux packages for Debian and AppImage builds, release files, and package checks. For an example of a Linux test record, see the Linux 0.1.44 validation.
Development help
| Problem | Action |
|---|---|
| Node.js, pnpm, or Cargo is missing | Load your toolchain environment. See Prerequisites. |
| The Browser runtime is missing | Package and stage it again. See Browser runtime on Linux. |
| Electron reports a sandbox or user-namespace error | Keep the sandbox on. Record the error and the distribution version. Run RuneStone as an ordinary desktop user. |
| A build stops | Record the first error, the command, the distribution version, and the free memory and disk space. |