Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions .github/workflows/wiki.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Publish wiki
on:
push:
branches: [main]
paths:
- "docs/wiki/**"
- ".github/workflows/wiki.yml"
workflow_dispatch:
permissions:
contents: read
concurrency:
group: wiki
cancel-in-progress: false
jobs:
# docs/wiki/ is the source of truth for the GitHub wiki. Pages are copied over and
# committed; pages that exist only in the wiki are left alone.
publish:
runs-on: ubuntu-24.04
timeout-minutes: 10
permissions:
contents: write
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Push pages to the wiki
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPOSITORY: ${{ github.repository }}
SHA: ${{ github.sha }}
run: |
git clone --depth 1 "https://x-access-token:${GITHUB_TOKEN}@github.com/${REPOSITORY}.wiki.git" wiki
cp docs/wiki/*.md wiki/
cd wiki
git add -A
if git diff --cached --quiet; then
echo "Wiki is already up to date."
exit 0
fi
git -c user.name="github-actions[bot]" \
-c user.email="41898282+github-actions[bot]@users.noreply.github.com" \
commit -m "Sync wiki from ${REPOSITORY}@${SHA::7}"
git push
4 changes: 4 additions & 0 deletions docs/development.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@ Tauri writes `.deb` and `.rpm` packages under `src-tauri/target/release/bundle/`

Release packages come from CI, which builds on Ubuntu 22.04 and declares a glibc 2.35 floor. A local `desktop:package` build on a newer distribution links against its newer glibc, so `scripts/verify-packages.py` correctly rejects it as a release candidate. See [Releases](releases.md#package-validation-and-distribution-ci).

## Wiki

The [GitHub wiki](https://github.com/Commanderx-code/command-center/wiki) is published from `docs/wiki/`. Edit the pages there and open a pull request; after it merges, the `Publish wiki` workflow copies them to the wiki. Edits made directly in the wiki are overwritten the next time that page changes here. Page links use wiki names such as `[Settings](Settings)`, so they only resolve on the wiki itself. `Home.md`, `_Sidebar.md`, and `_Footer.md` are the landing page, sidebar, and footer.

## Documentation screenshots

The README screenshot is captured from the actual browser preview with sample data. Keep the preview notice visible and avoid publishing personal repository contents, credentials, or terminal transcripts. Refresh `docs/images/dashboard.jpg` when the dashboard changes materially.
45 changes: 45 additions & 0 deletions docs/wiki/Activity-and-Change-Timeline.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# 🕒 Activity & Change Timeline

> _What ran, what it printed, and what changed._

## Activity

**Activity** is the history of every command Command Center has run: the last **100 jobs**, kept across restarts. The sidebar badge shows how many are running right now.

Select a job to see:

- its title, **status** (running, succeeded, failed, cancelled, timed out or interrupted), start and finish times, and **exit code**,
- the exact **command** and folder it ran in,
- its **output** (for background jobs, up to 2 MB per job; anything cut off is marked clearly).

Actions on a job:

| Button | When |
|---|---|
| **Stop job** | A background or embedded-terminal job is running. It stops the command and everything it started |
| **Terminal closed? Stop monitoring** | An external-terminal job whose terminal you've closed. Use it only once you're sure the command has ended |
| **Mark reviewed** | A failed job you've dealt with. It then leaves [Needs attention](Dashboard-and-Needs-Attention#needs-attention) |

Interactive sessions (installers in the Terminal) record their result here, but not what was typed or shown. That stays in the terminal. See [How Commands Run](How-Commands-Run) for how jobs run, run side by side, and stop.

If the app crashes or the computer shuts down during a job, that job is marked **interrupted** on the next start. Check what the command did before running it again.

## Change timeline

**Change timeline** answers *"what changed before this stopped working?"* It merges:

- jobs from Activity: package updates, Git operations, backups, service actions, workflow and profile steps, and so on,
- configuration saves from the [Configuration](Configuration) page (each save keeps a backup of the previous file).

**Search timeline** by title, result, category or folder, and filter with **All categories** or one category. **Refresh timeline** reloads it.

A configuration entry means the file was saved (and the old one backed up). It doesn't mean the change was activated. For Home Manager-managed files, that happens when you apply Home Manager.

> [!NOTE]
> The timeline only knows about changes made **through Command Center**. Changes from other apps or the command line don't appear.

---

| | |
|:--|--:|
| [← 🩺 Health, Services & Inventory](Health-Services-and-Inventory) | [⚙️ Settings →](Settings) |
108 changes: 108 additions & 0 deletions docs/wiki/Backup-and-Restore.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
# 🗄️ Backup & Restore

> _Backups, snapshots, file history, restores, schedules and recovery tests._

**Backup & Restore** works with the backup setup you already have: your own backup scripts plus a [Restic](https://restic.net) repository. It runs your scripts, lets you browse and restore from snapshots, finds every saved version of a file, schedules backups, and can prove a restore actually works.

Before you start, connect your helpers and repository in **Settings → System integrations** (see [Getting Started](Getting-Started#2-finish-connecting-your-setup)).

## Backup overview and readiness

The top of the page shows:

- **Where backups go** and whether the drive is connected, as reported by your **backup health helper**. If there's no report, the status shows as **unknown**, which doesn't mean disconnected.
- **When the last successful backup finished**, and whether it's overdue (the limit is set in Settings as *Backup freshness*).
- **Backup readiness**: whether your helpers exist and are executable, whether Restic is installed, and where credentials come from (KWallet, a password file or the environment). "Configured" isn't the same as "works". Use **Test repository access** to confirm that.

Click **Refresh health** after plugging in a backup drive.

## Running a backup

- **Personal backup** runs your personal backup helper in the background. Output goes to Activity.
- **Full recovery backup** runs your full backup helper in a **terminal**, so it can ask for encryption passwords.

Both buttons are disabled if the helper isn't set up, or if the health helper reports your backup drive disconnected. The app checks again when the job starts, and your scripts keep their own checks.

## Checking the repository

- **Test repository access** unlocks the repository with your configured credentials (this may prompt KWallet) and reads its configuration. Success means access works right now.
- **Check repository** runs Restic's integrity check on the repository's metadata.

> [!TIP]
> Neither one proves that every file can be restored. For that, use [Recovery verification](#recovery-verification).

## Browsing snapshots

1. Click **Load snapshots** to list the latest 30.
2. Pick one and **Browse** its folders in the **Snapshot browser**.

## Restoring files

1. Choose the **Selected snapshot**.
2. Optionally set **Include path or pattern** to restore only some files, for example `/home/you/Documents/taxes`. Leave it blank to restore the whole snapshot.
3. Enter a **New destination folder** inside your home folder. It must not exist yet; its parent must.
4. Click **Review restore** and confirm.

> [!NOTE]
> Restores **never overwrite** anything: files go into the new folder and are verified as they're written. Copy what you need back into place yourself. This recovers files; it isn't a full system or disk-image restore.

## File history

> [!NOTE]
> **New in 0.7.0**

Deleted a file, or need yesterday's version? **File history** searches **every** snapshot for it:

1. Type what you're looking for:
- a **name** such as `notes.md`, which matches it in any folder,
- an **exact path** such as `~/Documents/report.odt`, or
- a **pattern** with `*` and `?`, such as `*.kdbx`.
2. Tick **Ignore case** if you're not sure of the capitalization, then click **Search backups**. The review shows the exact Restic commands. The search only reads, but it goes through every snapshot, so large repositories can take a while.
3. Results are grouped by file path, newest first. Each saved copy shows:
- when it was backed up, with the snapshot ID and computer,
- the file's **modified** time and **size**,
- **First saved**, **Changed** (different size or modified time from the copy before) or **Same as previous**.

**Show only versions that changed** (on by default) hides the identical copies, so you see just the real versions.
4. Click **Restore this version** on the one you want. The restore form below fills in that snapshot and the file's exact path. Enter a **New destination folder** and click **Review restore**.

If a file is missing from newer backups of the same computer and folder, you'll see *"Not in the N newer snapshots… It may have been deleted or moved"*. The last row shows the final saved copy, ready to restore.

Good to know:

- "Changed" compares size and modified time, not the file contents.
- If a search matches thousands of files, it can't be shown. Search a more specific path.
- Restic reads `*`, `?` and `[` as pattern characters, so for a file whose name contains them, check the **Include path or pattern** before restoring.

## Backup schedules & user timers

This section lists your user **timers** (up to 100) with their next and last run, whether they're enabled, and the result of the service each one starts. **Enable** / **Disable** turn a timer on or off. **Service logs** shows the output of its last runs.

### Scheduling automatic backups

Under **Create or edit Command Center's backup schedule**, choose **hourly**, **daily** or **weekly (Sunday)** and a time, then **Review & save schedule**. The review shows the exact systemd timer and service files before anything is written.

- It runs your **personal** backup helper, which must work unattended (no password prompts).
- Missed runs, for example while the computer was off, happen the next time your session starts.
- The app only writes its own two files (`command-center-backup.service` and `.timer`) and refuses to touch anything else. It keeps a `.bak` copy when changing its own schedule.
- If you already have another backup timer, disable one so backups don't run twice.
- Timers run while you're logged in. They don't wake a sleeping or powered-off computer.

## Recovery verification

A backup you've never restored from is a guess. Recovery verification proves one file comes back intact:

1. Pick a small file (up to 100 MB) in your home folder that doesn't change often. In **Recovery verification**, choose it as the **Recorded file** and click **Record checksum**.
2. Run your normal backup so that exact version is in a snapshot.
3. **Load snapshots** and copy the new snapshot's ID into **Snapshot ID**.
4. Select the recorded baseline and click **Review recovery test**.

The app restores just that file into a temporary folder, compares its checksum with the recorded one, and deletes the temporary copy. Your original file is never touched. The result shows under recent recovery results and in Activity.

A pass proves that file can be recovered from that snapshot with your current credentials. It doesn't certify every file or every snapshot. If you edit the file later, record a new checksum.

---

| | |
|:--|--:|
| [← 🔁 Workflows & Machine Profiles](Workflows-and-Machine-Profiles) | [🔄 System Sync →](System-Sync) |
44 changes: 44 additions & 0 deletions docs/wiki/Configuration.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# 🎛️ Configuration

> _Ghostty and Fastfetch editors with preview, validation and history._

**Configuration** edits your **Ghostty** terminal and **Fastfetch** settings with visual controls, a live preview, validation and a full history. Pick the app from the **Application** dropdown.

The editor always works on your editable **source** file (set in **Settings → System integrations**). It never edits generated files in `/nix/store`. If Home Manager owns the live file, the page says so. Save your edits here, then use [System Sync](System-Sync) → **Apply Home Manager** to activate them.

## Editing

You can edit in two ways, and they stay in sync:

- **Controls:** form fields for common settings.
- *Ghostty:* font family and size, theme, window padding, background opacity, cursor style. Click **Apply controls to draft**.
- *Fastfetch:* logo source and type and the separator (**Apply logo & separator**), plus the **module** list: move modules up or down, remove them, or **Add module**.
- **Source configuration:** the raw file in a text editor, for anything the controls don't cover.

Changes stay in a **draft** until you save. **Preview** shows roughly how the result will look: font, padding and opacity for Ghostty, the module list for Fastfetch. It's an illustration, not a real terminal. Fastfetch `command` modules are never run in the preview.

## Saving

1. **Validate** checks the draft. Ghostty uses its own `ghostty +validate-config`; Fastfetch checks the JSONC syntax and module structure.
2. **Review & save** shows the current and new content side by side.
3. On confirm, the app saves a backup of the current file, then writes the new one in a single step.

> [!NOTE]
> If the file changed on disk after you loaded it (say, you edited it in another editor), saving stops and asks you to reload rather than overwrite that change. **Reload file** discards your draft and loads the file from disk again.

Your edits keep everything else in the file: Ghostty keeps unrelated lines, and Fastfetch keeps comments and custom module options.

## Configuration history

**Configuration history** lists the last 100 saved versions for the selected app.

- Select a version and click **Compare** to see it next to your current draft.
- **Review restore to draft** loads that version into the editor as a draft. Nothing is written until you **Review & save**.

Every save also appears in the [Change timeline](Activity-and-Change-Timeline).

---

| | |
|:--|--:|
| [← 🔄 System Sync](System-Sync) | [🩺 Health, Services & Inventory →](Health-Services-and-Inventory) |
51 changes: 51 additions & 0 deletions docs/wiki/Dashboard-and-Needs-Attention.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# 📊 Dashboard & Needs Attention

> _Your home screen, quick actions, and everything waiting for you._

## Dashboard

The dashboard is your home screen (you can choose a different start page in **Settings → General**). It shows:

- **Status cards** for repositories, configuration, backups and system health, so you can see what's clean, what's changed, and what's overdue.
- **Quick actions** launchpad: **Refresh repos** re-reads every repository's status; **Run backup**, **Home Manager** and **Edit configs** open Backup & Restore, System Sync and Configuration.
- **Your quick actions:** your own buttons for commands you use often, such as `full-upgrade`, a backup or a build script. Each click still shows the command for review first.
- A **Make this machine yours** prompt until you've finished the setup wizard.
- Notices about setup imports, including an interrupted import that was rolled back (see [Moving to a New Machine](Moving-to-a-New-Machine)).

### Adding quick actions

Go to **Settings → Custom quick actions → Add action** (up to 20):

| Field | Meaning |
|---|---|
| Name | The button label |
| Command | What to run |
| Working folder | Where it runs, for example `~` |
| Shell | **Direct** runs the program with its arguments and no shell tricks. **Fish** or **Bash** load your interactive shell setup, so your functions and aliases work. |
| Mode | **Background** (output in Activity, no input), **Embedded** (built-in terminal, can answer prompts) or **External** (your terminal app) |

Example: a Fish action with command `full-upgrade`, working folder `~` and mode **Embedded** runs your upgrade function in the built-in terminal, where you can type your password.

> [!WARNING]
> Commands are saved and shown in Activity as written, so don't put passwords in them.

## Needs attention

**Needs attention** gathers everything that wants action into one list:

- Repositories with **uncommitted changes**, **unpushed commits**, or that are **behind** their remote
- **Failed jobs** you haven't reviewed yet (open them in Activity and click **Mark reviewed** once handled)
- **Backups** that are overdue or whose status is unavailable
- **Disks** at least 90% full
- **Failed services**

Each item links to the page where you can deal with it. The sidebar badge shows how many items there are.

> [!TIP]
> "Behind" and "ahead" counts come from your last **fetch**. Fetch a repository to refresh them.

---

| | |
|:--|--:|
| [← 🔍 How Commands Run](How-Commands-Run) | [📂 Repositories →](Repositories) |
Loading
Loading