mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-04 01:44:13 +00:00
docs(wiki): bring the wiki in line with 4.0.0 (#2034)
* docs(wiki): correct the install and operations pages for 4.0.0 Quick Start passed docker an empty ENCRYPTION_KEY: an assignment prefix is not expanded on the same command line, so the server silently generated its own key instead of taking the one the page told you to set. The tag examples pinned to the 3.x line, the documented tmpfs size did not match the shipped compose file, and several .env values were described as reaching the container when compose never interpolates them. * docs(wiki): match the MCP reference to the registered surface The scope table was missing the whole Collections group and the totals said 27 scopes across 13 groups where the code registers 29 across 14. The Cloudflare link on the setup page pointed at an anchor on its own page instead of the heading on Troubleshooting. * docs(wiki): correct the plugin and admin pages Three links to Plugin-Development carried a .md suffix, which does not resolve on the wiki. The admin pages described tabs, permissions and storage behaviour that had moved on. * docs(wiki): bring the feature pages back in line with the app Costs still documented the old panel, where categories could be added, renamed, reordered and deleted; they are fixed now and the panel is a day-grouped ledger with settlements. Trip sharing, journeys, maps, packing, reservations and the account pages had all drifted in the same way. * docs(wiki): cover the pages the first pass did not reach The MCP catalog listed 168 of the 201 registered tools; the settlement tools and rate_place were missing here and the Collections family from the addon page. Several resource rows claimed a trips:* scope where the handler asks for trips:read. * docs(wiki): tighten the corrections a review picked apart The audit-log resource is the row id, not the credential id; an admin password reset does not bump password_version the way the page implied; and a few of the new paragraphs described behaviour more confidently than the code supports. * docs(wiki): fix what a last read-through caught Costs shows every figure in your display currency, not the trip's, and an expense with no payer still counts against the members it is split between. Studio's cutoff is a 1024px viewport rather than phones alone, and the Integrations tab is gated on the providers an admin has configured. * docs(wiki): the last few the review caught A passkey satisfies the MFA policy everywhere except the WebSocket handshake, which still asks for TOTP, so a passkey-only account under that policy gets no live updates. Mobile optimizes a day from two places, not three. The ctx.db row carried an unescaped pipe that split the table, and the Backups table linked with a wiki link whose pipe did the same.
This commit is contained in:
@@ -71,12 +71,18 @@ Branch naming conventions:
|
||||
|
||||
## 5. Install Dependencies
|
||||
|
||||
The repo is an npm workspace monorepo. One command at the root installs everything:
|
||||
The repo is an npm workspace monorepo with three workspaces — `shared`, `server`, and `client`. One command at the root installs all three:
|
||||
|
||||
```bash
|
||||
npm ci
|
||||
```
|
||||
|
||||
`plugin-sdk/` is **not** a root workspace: it has its own lockfile and is published to npm independently, so a root `npm ci` never touches it. If you are working on the SDK, install and run its commands from that directory:
|
||||
|
||||
```bash
|
||||
cd plugin-sdk && npm ci
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 6. Optional: KItinerary (Booking Import)
|
||||
@@ -94,17 +100,17 @@ sudo apt-get install -y libkitinerary-bin
|
||||
Add these to your local `.env` (or export them before starting the server):
|
||||
|
||||
```bash
|
||||
# Required: path to the extractor binary
|
||||
KITINERARY_EXTRACTOR_PATH=/usr/local/bin/kitinerary-extractor
|
||||
|
||||
# Prevent Qt from probing for a display in headless/server environments
|
||||
QT_QPA_PLATFORM=offscreen
|
||||
|
||||
# KDE cache directory (avoids writing to $HOME)
|
||||
XDG_CACHE_HOME=/tmp/kf6-cache
|
||||
|
||||
# Optional: only needed when the binary is not found on its own
|
||||
# KITINERARY_EXTRACTOR_PATH=/usr/lib/x86_64-linux-gnu/libexec/kf6/kitinerary-extractor
|
||||
```
|
||||
|
||||
You can override `KITINERARY_EXTRACTOR_PATH` if you installed the binary to a different location.
|
||||
`KITINERARY_EXTRACTOR_PATH` is optional. Left unset, the server looks for the Debian/Ubuntu location `/usr/lib/<triplet>/libexec/kf6/kitinerary-extractor` and then for `kitinerary-extractor` on `PATH` — one of which is what `libkitinerary-bin` gives you. Set it only if the binary ended up somewhere neither lookup reaches, and make sure the path exists: a value that does not resolve logs a warning and stops the lookup instead of falling back, which turns the import feature off. The Docker image sets it to `/usr/local/bin/kitinerary-extractor`, a symlink created at image build; that path does not exist on a plain apt install.
|
||||
|
||||
---
|
||||
|
||||
@@ -119,7 +125,7 @@ These commands run across all workspaces at once and are the recommended way to
|
||||
| `npm run dev` | Build shared, then start shared (watch), server, and client together via `concurrently` |
|
||||
| `npm run build` | Build shared → server → client in order |
|
||||
| `npm test` | Run tests in shared, server, and client |
|
||||
| `npm run test:cov` | Run coverage for server and client |
|
||||
| `npm run test:cov` | Run coverage for shared, server, client and plugin-sdk |
|
||||
| `npm run test:e2e` | Run end-to-end tests (server) |
|
||||
| `npm run lint` | Lint shared, server, and client |
|
||||
| `npm run format` | Format shared, server, and client |
|
||||
@@ -133,7 +139,7 @@ The `@trek/shared` package is the single source of truth for code shared between
|
||||
|
||||
| Command | Description |
|
||||
|-----------------------------|--------------------------------------|
|
||||
| `npm run build` | Compile shared package (tsup) |
|
||||
| `npm run build` | Compile shared package (tsdown) |
|
||||
| `npm run build:watch` | Compile in watch mode |
|
||||
| `npm test` | Run tests |
|
||||
| `npm run test:watch` | Run tests in watch mode |
|
||||
@@ -146,21 +152,26 @@ The `@trek/shared` package is the single source of truth for code shared between
|
||||
|
||||
### Server (`/server`)
|
||||
|
||||
| Command | Description |
|
||||
|----------------------------|------------------------------------------|
|
||||
| `npm start` | Start the server (production) |
|
||||
| `npm run dev` | Start the server in watch mode |
|
||||
| `npm run build` | Compile server |
|
||||
| `npm run typecheck` | Type-check without emitting |
|
||||
| `npm test` | Run all tests |
|
||||
| `npm run test:unit` | Run unit tests only |
|
||||
| `npm run test:integration` | Run integration tests |
|
||||
| `npm run test:ws` | Run WebSocket tests |
|
||||
| `npm run test:e2e` | Run end-to-end tests |
|
||||
| `npm run test:watch` | Run tests in watch mode |
|
||||
| `npm run test:coverage` | Run tests with coverage report |
|
||||
| `npm run lint` | Lint source |
|
||||
| `npm run format` | Format source |
|
||||
> **Tip:** `tests/` sits outside the build `tsconfig.json`, so `npm run typecheck` skips it — `npm run typecheck:tests` is the only step that catches a broken test call site. CI runs both.
|
||||
|
||||
| Command | Description |
|
||||
|------------------------------|------------------------------------------|
|
||||
| `npm start` | Start the server (production) |
|
||||
| `npm run dev` | Start the server in watch mode |
|
||||
| `npm run build` | Compile server |
|
||||
| `npm run typecheck` | Type-check without emitting |
|
||||
| `npm run typecheck:tests` | Type-check `tests/` too (CI gate) |
|
||||
| `npm test` | Run all tests |
|
||||
| `npm run test:unit` | Run unit tests only |
|
||||
| `npm run test:integration` | Run integration tests |
|
||||
| `npm run test:ws` | Run WebSocket tests |
|
||||
| `npm run test:e2e` | Run end-to-end tests |
|
||||
| `npm run test:watch` | Run tests in watch mode |
|
||||
| `npm run test:coverage` | Run tests with coverage report |
|
||||
| `npm run lint` | Lint source |
|
||||
| `npm run lint:check` | Lint everything, no `--fix` (CI gate) |
|
||||
| `npm run check:plugin-facts` | Verify generated plugin facts (CI gate) |
|
||||
| `npm run format` | Format source |
|
||||
|
||||
### Client (`/client`)
|
||||
|
||||
@@ -169,12 +180,16 @@ The `@trek/shared` package is the single source of truth for code shared between
|
||||
| `npm run dev` | Start the Vite dev server |
|
||||
| `npm run build` | Build for production (runs icon generation first) |
|
||||
| `npm run preview` | Preview the production build locally |
|
||||
| `npm run typecheck` | Type-check without emitting (CI gate) |
|
||||
| `npm test` | Run all tests |
|
||||
| `npm run test:unit` | Run unit tests only |
|
||||
| `npm run test:integration` | Run integration tests |
|
||||
| `npm run test:watch` | Run tests in watch mode |
|
||||
| `npm run test:coverage` | Run tests with coverage report |
|
||||
| `npm run lint` | Lint source |
|
||||
| `npm run lint:check` | Same command as `npm run lint` — the name CI uses |
|
||||
| `npm run lint:pages` | Enforce the Page pattern (CI gate) |
|
||||
| `npm run theme:lint` | Flag styling that bypasses the appearance tokens |
|
||||
| `npm run format` | Format source |
|
||||
|
||||
---
|
||||
@@ -199,5 +214,5 @@ Then open a Pull Request from your fork to `liketrek/TREK` targeting the `dev` b
|
||||
## Tips
|
||||
|
||||
- Always branch off from an up-to-date `dev` — run `git fetch upstream && git rebase upstream/dev` before starting new work.
|
||||
- Run tests before pushing: `npm test` at the repo root runs all workspaces.
|
||||
- Run tests before pushing: `npm test` at the repo root runs all workspaces. That alone is not the full CI gate — also run `npm run typecheck && npm run typecheck:tests && npm run lint:check && npm run check:plugin-facts` in `server/`, `npm run typecheck && npm run lint:check && npm run lint:pages` in `client/`, and `npm run i18n:parity:strict --workspace=shared` at the root if you touched translations.
|
||||
- Follow the commit message conventions described in the [[Contributing]] guidelines.
|
||||
|
||||
Reference in New Issue
Block a user