Rewrite the documentation and the agent instructions
Move the agent instructions from AGENTS.md to CLAUDE.md. AGENTS.md now points to CLAUDE.md. The UI rules move to docs/ui-design.md. The version and release policy moves to the new docs/releases.md. Rewrite the README, the user guides, and the developer references. Check each claim against the code. Remove old version history and repeated warnings. Link to Gitea at git.knottywyvern.com instead of the LAN address. Move the October 13 menu audit to the archive.
This commit is contained in:
+49
-94
@@ -1,25 +1,22 @@
|
||||
# Linux development
|
||||
|
||||
[Development guide](development.md) · [Linux installation and updates](installation.md#install-on-linux) · [Build Linux packages](builds.md#build-linux-packages)
|
||||
[Development](development.md) · [Build Linux packages](builds.md#build-linux-packages) · [Install on Linux](installation.md#install-on-linux)
|
||||
|
||||
This guide covers Linux source development, Browser preparation, and native desktop checks.
|
||||
To install a supplied RuneStone package, use [Installation and updates](installation.md#install-on-linux).
|
||||
Past build and test results are in the [Linux validation reference](archive/linux-validation-2026-10.md).
|
||||
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](development.md#run-from-source).
|
||||
|
||||
## Development prerequisites
|
||||
## Prerequisites
|
||||
|
||||
Use a Linux source checkout with Node.js 24, pnpm 10, and a stable Rust toolchain.
|
||||
See the [shared development requirements](development.md#requirements) for repository setup.
|
||||
Use [Tauri's Linux prerequisites](https://v2.tauri.app/start/prerequisites/#linux) for native libraries, including GTK and WebKitGTK 4.1.
|
||||
The first build needs internet access for dependencies.
|
||||
- The tools in [Run from source](development.md#run-from-source): Node.js 24, pnpm 10, and a stable Rust toolchain.
|
||||
- The native libraries in [Tauri's Linux prerequisites](https://v2.tauri.app/start/prerequisites/#linux), including GTK and WebKitGTK 4.1.
|
||||
- A graphical desktop session.
|
||||
- A terminal with `node`, `pnpm`, and `cargo` on its `PATH`. If a command is missing, load the environment that its installer configured.
|
||||
|
||||
Open a terminal with Node.js, pnpm, and Cargo available on its PATH.
|
||||
If a command is missing, load the environment configured by its installer before you continue.
|
||||
Do not copy Windows `node_modules`, `src-tauri/target`, or `browser-engine` folders into Linux.
|
||||
Do not copy `node_modules`, `src-tauri/target`, or `src-tauri/browser-engine` from a Windows checkout. They contain platform-specific binaries.
|
||||
|
||||
## Record the development environment
|
||||
## Record the environment
|
||||
|
||||
Run these commands in the Linux session used for native checks:
|
||||
Run these commands in the Linux session that you use for native checks:
|
||||
|
||||
```sh
|
||||
cat /etc/os-release
|
||||
@@ -27,113 +24,71 @@ 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 test results.
|
||||
Test the session you use first. Test both Wayland and X11 before claiming support for both.
|
||||
An Intel/AMD build does not establish ARM support.
|
||||
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.
|
||||
|
||||
## Build and run from source
|
||||
## Browser runtime on Linux
|
||||
|
||||
Run the commands below from the RuneStone repository root in a graphical Linux session.
|
||||
Commands come from [package.json](../package.json) and [browser-runtime/package.json](../browser-runtime/package.json).
|
||||
Use the general steps in [Built-in browser runtime](development.md#built-in-browser-runtime). On Linux, these differences apply:
|
||||
|
||||
From the Linux checkout, install the project dependencies:
|
||||
- Package and stage the runtime on the same architecture as the host build.
|
||||
`npm --prefix browser-runtime run package` selects the current platform and architecture.
|
||||
`package:linux` always builds x86_64. Do not use it on ARM64.
|
||||
- `pnpm browser:stage` stops when the packaged runtime does not match the current platform and architecture.
|
||||
- Staging makes sure that the `RuneStone-Browser` file is executable and sets the runtime folder to mode 755.
|
||||
- Staging replaces the full `src-tauri/browser-engine` folder, so no files from an older package stay.
|
||||
It moves the previous folder to `output/browser-stage-backups/`.
|
||||
|
||||
```sh
|
||||
pnpm install --frozen-lockfile
|
||||
npm ci --prefix browser-runtime
|
||||
```
|
||||
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 built-in Browser is a separate Electron executable. A fresh checkout does not
|
||||
contain `src-tauri/browser-engine`; prepare it on the same Linux architecture before
|
||||
building or launching the native host:
|
||||
The native host uses WebKitGTK and the Browser uses Electron. Test both.
|
||||
|
||||
```sh
|
||||
pnpm browser:check
|
||||
pnpm browser:test
|
||||
npm --prefix browser-runtime run package
|
||||
pnpm browser:stage
|
||||
```
|
||||
## Checks
|
||||
|
||||
Use the native `package` command on ARM64 too; `package:linux` explicitly selects
|
||||
x86_64. Staging verifies the executable permission and replaces the whole runtime
|
||||
tree, so files from an older Windows or Linux package cannot leak into the new one.
|
||||
An existing staged runtime is retained under `output/browser-stage-backups/` for
|
||||
recovery. Do not copy Windows `browser-engine` output into a Linux build.
|
||||
Run the source checks in [Checks](development.md#checks) and the tests in [Browser smoke tests](development.md#browser-smoke-tests).
|
||||
Then run `pnpm tauri dev` in the graphical session for the desktop checks below.
|
||||
|
||||
Electron must run as an ordinary desktop user with its sandbox enabled. Do not
|
||||
work around sandbox failures with `--no-sandbox` or by running RuneStone as root.
|
||||
Test the Browser on the intended distro, including its user-namespace policy.
|
||||
The native host uses WebKitGTK and the Browser uses Electron; both need testing.
|
||||
|
||||
### Source checks
|
||||
|
||||
The full test suite needs the Table Formulas package.
|
||||
Clone `RuneStone_Table_Formulas` beside RuneStone.
|
||||
Install its dependencies as described in the [Table Formulas build example](plugin-development.md#example-table-formulas).
|
||||
|
||||
`pnpm build:plugins` builds only Table Formulas. Run these checks from the RuneStone repository root:
|
||||
|
||||
```sh
|
||||
pnpm build:plugins
|
||||
pnpm check
|
||||
pnpm test
|
||||
pnpm build
|
||||
cargo test --manifest-path src-tauri/Cargo.toml --lib --locked
|
||||
```
|
||||
|
||||
### Development session
|
||||
|
||||
Run the desktop app in your graphical Linux session:
|
||||
|
||||
```sh
|
||||
pnpm tauri dev
|
||||
```
|
||||
|
||||
This command starts Vite and opens the native desktop app. Keep the terminal open during development.
|
||||
Save your work and press Ctrl+C in that terminal to stop the session.
|
||||
See the [daily workflow](development.md#daily-workflow) for source edits and rebuild behavior.
|
||||
|
||||
A successful build does not establish desktop compatibility.
|
||||
Browser tests use mocked desktop calls and Chromium. They do not test Linux file access or WebKitGTK behavior.
|
||||
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.
|
||||
Use this checklist for native behavior after source changes. Voice typing is outside the Linux acceptance criteria.
|
||||
Keep each result separate from the [historical validation records](archive/linux-validation-2026-10.md).
|
||||
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 trigger the close guard. |
|
||||
| Files and paths | Create, save, reopen, rename, copy, and delete files. Check spaces, Unicode, and distinct `Note.md` and `note.md` files. |
|
||||
| External edits | Edit a file in another editor. RuneStone detects the change and prevents silent replacement of conflicting edits. |
|
||||
| Built-in Browser | Open a web page, type and scroll, open/close tabs, download a file, and restart the app. Check the packaged runtime too. |
|
||||
| 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 | Open a web page, type, scroll, open and close tabs, download a file, and restart the app. Check the packaged runtime too. |
|
||||
| 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 plugin data persistence. |
|
||||
| Plugins | Install plugin ZIPs through Settings, enable them, restart, disable them, and remove them. Check that plugin data stays. |
|
||||
| Terminal plugin | Install the Terminal ZIP. Bash starts in the workspace, accepts Unicode, resizes, and exits when its session closes. |
|
||||
| Settings | Change preferences, restart, and confirm persistence. Check separate workspace windows. |
|
||||
| Settings | Change preferences, restart, and make sure that they stay. Check separate workspace windows. |
|
||||
|
||||
Build Terminal with the [Terminal example](plugin-development.md#example-terminal), then [install its ZIP](plugins.md#install-a-plugin).
|
||||
For the Terminal ZIP, see [Build examples](plugin-development.md#build-examples) and the [plugin installation guide](plugins.md).
|
||||
Check terminal profiles after a desktop launch too. A desktop launcher can have a different `PATH` from an interactive shell.
|
||||
|
||||
Current filename rules reject some names that Linux permits, including colons and backslashes.
|
||||
Use ordinary portable filenames for baseline checks. Record unsupported names as a limitation.
|
||||
Mounted network shares need separate tests because Linux mount paths do not reliably select the current polling fallback.
|
||||
Do not claim network workspace support from a local-disk test.
|
||||
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](builds.md#build-linux-packages) for Debian and AppImage commands, release handling, and package checks.
|
||||
Use [Build Linux packages](builds.md#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](archive/linux-validation-0.1.44.md).
|
||||
|
||||
## Development help
|
||||
|
||||
| Problem | Action |
|
||||
| --- | --- |
|
||||
| Node.js, pnpm, or Cargo is missing | Load your toolchain environment and check the [development prerequisites](#development-prerequisites). |
|
||||
| The Browser runtime is missing | From the repository root, repeat the Browser dependency, package, and staging commands in [Build and run from source](#build-and-run-from-source). |
|
||||
| Electron reports a sandbox or user-namespace error | Keep the sandbox enabled. Record the error and distribution version. Run RuneStone as an ordinary desktop user. |
|
||||
| A build stops | Record the first error, failed command, distribution version, and available memory and disk space. |
|
||||
|
||||
See [development help](development.md#development-help) for port conflicts, stale windows, and offline Cargo errors.
|
||||
| Node.js, pnpm, or Cargo is missing | Load your toolchain environment. See [Prerequisites](#prerequisites). |
|
||||
| The Browser runtime is missing | Package and stage it again. See [Browser runtime on Linux](#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. |
|
||||
|
||||
Reference in New Issue
Block a user