Initial commit: Brass & Sigil monorepo

Self-hosted Minecraft modpack distribution + administration system.

- launcher/  Avalonia 12 desktop client; single-file win-x64 publish.
             Microsoft auth via XboxAuthNet, manifest+SHA-1 mod sync,
             portable install path, sidecar settings.
- server/    brass-sigil-server daemon (.NET 8, linux-x64). Wraps the
             MC subprocess, embedded Kestrel admin panel with cookie
             auth + rate limiting, RCON bridge, scheduled backups,
             BlueMap CLI integration with player markers + skin proxy,
             friend-side whitelist request flow, world wipe with seed
             selection (keep current / random / custom).
- pack/      pack.lock.json (Modrinth + manual CurseForge entries),
             data-only tweak source under tweaks/, build outputs in
             overrides/ (gitignored).
- scripts/   Build-Pack / Build-Tweaks / Update-Pack / Check-Updates
             plus Deploy-Brass.ps1 unified one-shot deploy with
             version-bump pre-flight and daemon-state detection.
This commit is contained in:
Matt Sijbers
2026-05-05 00:19:05 +01:00
commit a1331212cb
99 changed files with 12640 additions and 0 deletions
+112
View File
@@ -0,0 +1,112 @@
# Brass & Sigil Launcher
A custom Minecraft Java Edition launcher built for distributing the private
"Brass & Sigil" modpack (Create + aeronautics + tech + magic + Distant
Horizons) to a small friend group.
> **NOT AN OFFICIAL MINECRAFT PRODUCT. NOT APPROVED BY OR ASSOCIATED WITH
> MOJANG OR MICROSOFT.**
## What it does
1. Fetches a JSON manifest from a self-hosted server and syncs the modpack
files (mods, configs, resourcepacks) to the player's local install
directory. SHA-1 hashing ensures only changed files are downloaded.
2. Authenticates each player with their own personal Microsoft account via
the standard MSAL OAuth + Xbox Live + Minecraft Services chain, using the
open-source `CmlLib.Core.Auth.Microsoft` library without modification.
3. Installs the appropriate Minecraft Java Edition version and Forge mod
loader, then launches the game with the player's authenticated session.
## Stack
- **C# / .NET 8**
- **Avalonia 12** -- desktop UI
- **CmlLib.Core 4.x** -- Minecraft install + launch
- **CmlLib.Core.Auth.Microsoft 3.x + XboxAuthNet.Game.Msal** -- Microsoft auth
- **CmlLib.Core.Installer.Forge** -- Forge support
## Build
Requires the .NET 8 SDK.
```powershell
dotnet build
```
To produce the shippable single-file executable (~46 MB):
```powershell
dotnet publish -c Release -r win-x64 --self-contained true
```
Output: `bin/Release/net8.0/win-x64/publish/ModpackLauncher.exe` -- a single
file with no other dependencies, ready to send to a friend.
## Configuration
The repo ships with a `launcher-config.template.json`. Copy it to
`launcher-config.json` and fill in real values before building:
```powershell
Copy-Item launcher-config.template.json launcher-config.json
```
`launcher-config.json` is gitignored so local values (manifest URL, Azure
client ID) never get committed.
### Fields
| Field | Purpose |
| --- | --- |
| `packName` | Display name shown in the launcher |
| `manifestUrl` | URL of the hosted manifest JSON |
| `installDirName` | Folder name under `%APPDATA%` for game files |
| `memoryMinMB` / `memoryMaxMB` | JVM memory defaults |
| `msalClientId` | Azure App Registration client ID for Microsoft auth |
The config is **embedded into the exe** at build time, so the launcher ships
as a single self-contained file. A sidecar `launcher-config.json` placed
beside the exe will override the embedded copy at runtime (handy for testing).
## Manifest format
See `manifest.example.json` for the schema. Minimum:
```json
{
"name": "Brass & Sigil",
"version": "1.0.0",
"minecraft": { "version": "1.20.1" },
"loader": { "type": "forge", "version": "47.2.0" },
"files": [
{ "path": "mods/example.jar", "url": "https://...", "sha1": "..." }
]
}
```
The launcher diffs the manifest against the local install dir using SHA-1
hashes and downloads only what has changed. Files removed from the manifest
are pruned from managed folders (`mods/`, `config/`, `resourcepacks/`,
`shaderpacks/`, `kubejs/`, `defaultconfigs/`).
## Privacy
The launcher does not collect, store, or transmit any user data beyond what
the standard Microsoft and Minecraft authentication APIs require. Auth tokens
are cached locally via the MSAL token cache. No telemetry, no analytics, no
third-party services beyond Microsoft and Mojang.
Local data is written to:
- `%APPDATA%\BrassAndSigil\` -- launcher settings + log file
- `%APPDATA%\<installDirName>\` -- modpack and Minecraft installation
## License
MIT -- see [LICENSE](LICENSE).
## Author
Matt Sijbers -- [https://sijbers.uk/matt](https://sijbers.uk/matt) /
[project page](https://sijbers.uk/brass-and-sigil)