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
20 changes: 10 additions & 10 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,16 +103,16 @@ libgtk-3-dev libxdo-dev libdbus-1-dev pkg-config

See [docs/architecture.md](docs/architecture.md) for the full layout. Short version:

- `src/main.rs` — entry, Elm-architecture `update()` / `view()`.
- `src/update.rs` — `Message` handlers.
- `src/github.rs` — GitHub API layer: manifest fetching, release asset resolution, update checks.
- `src/download.rs` — release/asset downloads, archive extraction, launcher self-update.
- `src/signing.rs` — ed25519 verification of signed launcher updates (see [docs/release-signing.md](docs/release-signing.md)).
- `src/persistence.rs` — data directories, install state, on-disk caches, favorites.
- `src/config.rs` — locating external config files (`categories.json`, `colony.toml`).
- `src/scan.rs` — system app detection (Linux `.desktop`, Windows Start Menu, macOS `.app`).
- `src/sections.rs` — categories + filter logic.
- `src/ui/` — widgets and panels (sidebar, app grid, detail view, settings).
- `src/main.rs` - entry point: CLI flags, startup order, the iced launch.
- `src/app.rs` - Elm-architecture `view()`, `subscription()` and `theme()`; `src/update/` - `Message` handlers.
- `src/github/` - GitHub API layer: manifest fetching, release asset resolution, update checks.
- `src/download/` - release/asset downloads, archive extraction, launcher self-update.
- `src/signing.rs` - ed25519 verification of signed launcher updates (see [docs/release-signing.md](docs/release-signing.md)).
- `src/persistence.rs` - data directories, preferences, install state, on-disk caches, favorites.
- `src/config.rs` - locating external config files (`categories.json`, `colony.toml`).
- `src/scan.rs` - system app detection (Linux `.desktop`, Windows Start Menu, macOS `.app`).
- `src/sections.rs` - categories + filter logic.
- `src/ui/` - widgets and panels (sidebar, app grid, detail view, Preferences), on colony-ui's kit.
- `src/ui/theme.rs` — a re-export of [colony-ui](https://crates.io/crates/colony-ui)
plus Colony's own button styling. The 26 theme families and 59 palettes live
in that crate, generated from the design tokens in
Expand Down
5 changes: 3 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ resolver = "3"
anyhow = "1.0.104"
# The shared theme, palettes, accents, labels and widgets, generated from the
# design tokens in Project-Colony-Resources.
colony-ui = "0.1.5"
colony-ui = "0.1.6"
iced = { version = "0.14.0", features = ["tokio", "markdown", "advanced", "image-without-codecs"] }
shell-words = "1.1.1"
serde = { version = "1.0.229", features = ["derive"] }
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,4 +171,4 @@ Requests carry a `Colony-Launcher` user agent. Beyond that, they tell GitHub onl

Colony is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

The bundled fonts keep their own license, the SIL Open Font License 1.1, with the full text next to each font in `src/ui/assets/fonts/`: [JetBrains Mono Nerd Font](src/ui/assets/fonts/JetBrainsMonoNerdFont/OFL.txt), [Font Awesome Free](src/ui/assets/fonts/FontAwesome/OFL.txt) and [OpenDyslexic](src/ui/assets/fonts/OpenDyslexic/OFL.txt).
The fonts Colony embeds come from the [colony-ui](https://crates.io/crates/colony-ui) crate and keep their own license, the SIL Open Font License 1.1, with the full text next to each font in colony-ui: [JetBrains Mono Nerd Font](https://github.com/Project-Colony/Project-Colony-Resources/blob/main/crates/colony-ui/assets/fonts/JetBrainsMonoNerdFont/OFL.txt), [Font Awesome Free](https://github.com/Project-Colony/Project-Colony-Resources/blob/main/crates/colony-ui/assets/fonts/FontAwesome/OFL.txt) and [OpenDyslexic](https://github.com/Project-Colony/Project-Colony-Resources/blob/main/crates/colony-ui/assets/fonts/OpenDyslexic/OFL.txt).
28 changes: 14 additions & 14 deletions config/categories.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
[
{
"name": "All",
"icon": "",
"icon": "\uf00a",
"origin": "colony",
"category": "all"
},
{
"name": "Windows",
"icon": "",
"icon": "\uf17a",
"origin": "windows",
"category": "all",
"platforms": [
Expand All @@ -16,7 +16,7 @@
},
{
"name": "Linux",
"icon": "",
"icon": "\uf17c",
"origin": "external",
"category": "all",
"platforms": [
Expand All @@ -25,7 +25,7 @@
},
{
"name": "macOS",
"icon": "",
"icon": "\uf179",
"origin": "external",
"category": "all",
"platforms": [
Expand All @@ -35,61 +35,61 @@
},
{
"name": "Development",
"icon": "",
"icon": "\uf121",
"origin": "colony",
"category": "development"
},
{
"name": "Graphics",
"icon": "",
"icon": "\uf1fc",
"origin": "colony",
"category": "graphics"
},
{
"name": "Network",
"icon": "",
"icon": "\uf0ac",
"origin": "colony",
"category": "network"
},
{
"name": "Office",
"icon": "",
"icon": "\uf0f6",
"origin": "colony",
"category": "office"
},
{
"name": "Multimedia",
"icon": "",
"icon": "\uf008",
"origin": "colony",
"category": "multimedia"
},
{
"name": "System",
"icon": "",
"icon": "\uf085",
"origin": "colony",
"category": "system"
},
{
"name": "Utilities",
"icon": "",
"icon": "\uf0ad",
"origin": "colony",
"category": "utility"
},
{
"name": "Security",
"icon": "",
"icon": "\uf132",
"origin": "colony",
"category": "Security"
},
{
"name": "Games",
"icon": "",
"icon": "\uf11b",
"origin": "colony",
"category": "game"
},
{
"name": "Other",
"icon": "",
"icon": "\uf128",
"origin": "colony",
"category": "other"
}
Expand Down
17 changes: 17 additions & 0 deletions config/shields-colors.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"brightgreen": "#4cc140",
"green": "#97ca00",
"yellowgreen": "#a4a61d",
"yellow": "#dfb317",
"orange": "#fe7d37",
"red": "#e05d44",
"blue": "#007ec6",
"lightgrey": "#9f9f9f",
"lightgray": "#9f9f9f",
"grey": "#555555",
"gray": "#555555",
"purple": "#943aa0",
"pink": "#e730a8",
"black": "#1f1f1f",
"white": "#eeeeee"
}
91 changes: 57 additions & 34 deletions docs/architecture.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Colony is an application launcher written in Rust with Iced 0.14 (Elm architectu
|-----------|-----------|
| Language | Rust (edition 2021) |
| UI | Iced 0.14 (Elm architecture) |
| Shared UI | colony-ui: theme palettes, fonts, text sizing, motion, the Preferences kit |
| Async | Tokio (integrated via Iced runtime) |
| HTTP | reqwest (async + streaming), rustls checking certificates against the OS trust store (no OpenSSL) |
| Auth | GitHub Device Flow OAuth |
Expand All @@ -24,41 +25,60 @@ Colony is an application launcher written in Rust with Iced 0.14 (Elm architectu

```
src/
├── main.rs — Crate root: modules, CLI flags, logging, entry point
├── state.rs — App struct (global state), GitHubState, UI fields
├── message.rs — Message enum (all events)
├── app.rs — impl App: boot(), view(), subscription(), theme()
├── update/ — Message dispatch table (mod.rs) + handlers
│ ├── store.rs — install / update / uninstall / notes / favorites
│ ├── github_auth.rs — device flow, catalog refresh
│ ├── launcher.rs — self-update state machine
├── main.rs - Entry point: CLI flags (--version, --help,
│ validate-manifest), startup order, iced launch
├── manifest.rs - `colony validate-manifest`: checks an app's colony.json
├── logging.rs - Log file + stderr, with the startup migration's lines
├── state.rs - App struct (global state), GitHubState, UI fields
├── message.rs - Message enum (all events)
├── app.rs - impl App: boot(), view(), subscription(), theme()
├── update/ - Message dispatch table (mod.rs) + handlers
│ ├── store.rs - install / update / uninstall / notes / favorites
│ ├── github_auth.rs - device flow, catalog refresh
│ ├── launcher.rs - self-update state machine
│ ├── preferences.rs, keyboard.rs, onboarding.rs
├── github/ — split by layer, mod.rs re-exports everything
│ ├── http.rs — client, conditional-request cache, typed statuses
│ ├── types.rs — colony.json / API wire shapes
│ ├── catalog.rs — store listing
│ └── releases.rs — tags, assets, platform auto-detection
├── download.rs — Asset/archive downloads, extraction, app-signature
│ verification, self-update
├── signing.rs — ed25519 verification (launcher AND app releases)
├── icons.rs — PNG decoding for per-app grid icons
├── persistence.rs — Data dirs, install state, on-disk caches, favorites,
│ desktop entries (Linux)
├── config.rs — Locating external config (categories.json, colony.toml)
├── oauth.rs — Device Flow OAuth (login, token, keychain)
├── scan.rs — System application scanning (Linux/Windows/macOS)
├── sections.rs — Categories, origin/category filters, JSON config
├── i18n/ — fr.rs, en.rs, and the Locale lookup (mod.rs)
├── github/ - split by layer, mod.rs re-exports everything
│ ├── http.rs - client, conditional-request cache, typed statuses
│ ├── types.rs - colony.json / API wire shapes
│ ├── catalog.rs - store listing
│ └── releases.rs - tags, assets, platform auto-detection
├── download/ - split by concern, mod.rs re-exports the public API
│ ├── http.rs - download client, resumable transfers, bounded sidecar
│ │ reads, safe URL building
│ ├── files.rs - path-component checks, no-follow creates, replacing a
│ │ running binary, zip / tar.gz extraction
│ ├── verify.rs - SHA-256, signed .meta bindings, downgrade rules
│ ├── install.rs - app install: download, verify, extract, promote
│ └── launcher.rs - self-update: staging, apply with rollback
├── signing.rs - ed25519 verification (launcher AND app releases)
├── icons.rs - PNG decoding for per-app grid icons
├── persistence.rs - Data dirs, preferences (with colony-ui's
│ StandardPreferences), install state, on-disk caches,
│ favorites, desktop entries (Linux)
├── config.rs - Locating external config (categories.json, colony.toml)
├── oauth.rs - Device Flow OAuth (login, token, keychain)
├── scan.rs - System application scanning (Linux/Windows/macOS)
├── sections.rs - Categories, origin/category filters, JSON config
├── i18n/ - fr.rs, en.rs, and the Locale lookup (mod.rs); the
│ shared Preferences labels come from colony-ui
└── ui/
├── mod.rs — UI module declarations
├── theme.rs — 26 theme families, 59 palettes, semantic tokens
├── sidebar.rs — Sidebar (sections, GitHub, rescan, update badge)
├── app_grid.rs — Application card grid with search
├── detail.rs — Detail view (README, changelog, license, actions)
├── settings.rs — Settings panel (theme, language, about, updates)
├── github_panel.rs — GitHub connect/disconnect, Device Flow UI
├── markdown_blocks.rs — Cached-block Markdown rendering
└── tutorial.rs — First-launch guided tour (spotlight overlay)
├── mod.rs - UI module declarations, the glyph + label helper
├── theme.rs - colony-ui's 26 theme families and 59 palettes, Colony's
│ button styles
├── sidebar.rs - Sidebar (the Colony name into Preferences, sections,
│ GitHub, rescan, update badge)
├── app_grid.rs - Application card grid with search
├── detail.rs - Detail view (README, changelog, license, actions)
├── settings.rs - Preferences page on colony-ui's kit (General,
│ Appearance, Accessibility, Storage, Shortcuts, About)
├── github_panel.rs - GitHub connect/disconnect, Device Flow UI
├── markdown_blocks.rs - Cached-block Markdown rendering
└── tutorial.rs - First-launch guided tour (spotlight overlay)

config/
├── categories.json - Sidebar sections (embedded; can be overridden)
├── colony.toml - Scan directories
└── shields-colors.json - shields.io colour names for README badges (embedded)
```

## Data flow (Elm architecture)
Expand Down Expand Up @@ -129,7 +149,10 @@ Unit tests (`cargo test`) cover:
- Application categorization
- Section filters
- Localization (EN/FR, key parity between languages)
- Preferences serialization
- Preferences serialization, and the migration of a file an older Colony wrote
- Preferences category order
- `validate-manifest` exit codes (0 clean, 1 invalid, 2 unreadable)
- Escaped Nerd Font glyphs in categories.json, shields colour names
- Update-loop state transitions (catalog refresh, update queue, badges,
launcher-check outcomes, cancel semantics) via a hermetic test App
- filePattern globs with exclusions, signature parsing (strict ed25519),
Expand Down
2 changes: 1 addition & 1 deletion docs/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ Yes. Edit `~/.config/Colony/Colony/preferences/preferences.json` and add custom

### I changed a theme and don't see it — why?

Themes apply immediately, no restart. If a palette looks off, verify Settings → Theme has the expected family + palette selected. All 59 palettes are compiled into the binary, so if it's missing you're on an old version — update.
Themes apply immediately, no restart. If a palette looks off, verify Preferences → Appearance → Theme has the expected family + palette selected. All 59 palettes are compiled into the binary, so if it's missing you're on an old version: update.

---

Expand Down
2 changes: 1 addition & 1 deletion docs/release-signing.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ so the shipped binary needs no OpenSSL.
`"signed": true`. Once an install of an app has verified a signature, that
app is pinned: a later release that stops publishing `.sig` is refused,
whatever the manifest now says. The same applies to the `.meta` sidecar
([`src/download.rs`](../src/download.rs), `download_release_asset`). The
([`src/download/install.rs`](../src/download/install.rs), `download_release_asset`). The
optional `sha256` field in `colony.json` is checked on top of that.

The organisation signs every program with one key, so the keys embedded here
Expand Down
18 changes: 10 additions & 8 deletions docs/tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,16 +79,17 @@ When you open Colony for the first time you'll see three zones:
└───────────┴──────────────────────────────────────────┘
```

- **Sidebar** — Categories. The top group (`All` / `Windows` / `Linux`) is
- **Sidebar**: Categories. The top group (`All` / `Windows` / `Linux`) is
the *origin* filter: Colony apps, apps already installed on your system, or
both. The middle group is Colony categories (`Development`, `Graphics`,
`Network`, `Office`, `Multimedia`, `System`, `Utilities`, `Security`, `Games`,
`Other`).
- **App grid** — Cards for every app matching the current filters. Click a
- **App grid**: Cards for every app matching the current filters. Click a
card to open its detail view.
- **Search** — A search bar above the grid filters by app name.
- **Settings gear** — Bottom of the sidebar opens preferences (theme,
language, scan directories, about).
- **Search**: A search bar above the grid filters by app name.
- **Colony**: The name at the top of the sidebar opens Preferences: General,
Appearance, Accessibility, Storage, Shortcuts and About. Click it again, or
Close, to go back.

## 3. Install your first Colony app

Expand Down Expand Up @@ -121,9 +122,10 @@ Switch the sidebar origin to **Linux** (or **Windows**) to see only those.

## 5. Customize the theme

Click the **gear icon** at the bottom of the sidebar → **Theme**. Colony ships
26 theme families and 59 palettes (Catppuccin, Gruvbox, Nord, Dracula, Rosé
Pine, Tokyo Night, etc.). Theme changes apply instantly, no restart needed.
Click **Colony** at the top of the sidebar, then **Appearance** → **Theme**.
Colony ships 26 theme families and 59 palettes (Catppuccin, Gruvbox, Nord,
Dracula, Rosé Pine, Tokyo Night, etc.). Theme changes apply instantly, no
restart needed.

## 6. Connect your GitHub account (optional)

Expand Down
Loading
Loading