feat: add Modrinth integration (#255)#431
Conversation
Add ability to search, install and manage mods from Modrinth: - Search mods filtered by Minecraft version and loader - One-click install from search results - Check for updates on installed Modrinth mods - Update mods to latest compatible version Creates a dedicated "Mods" tab in the version selector. Mods are downloaded to the custom_mods folder with metadata tracking. Example: Go to Mods tab, search "sodium", click install, and the mod will be ready for your next launch. Safe: Metadata stored in .modrinth_meta.json tracks installed mods. Updating a mod removes the old file before downloading the new one. Closes CCBlueX#255 Screenshots:  
1efe6e5 to
601207a
Compare
|
This PR still needs some fixes before it's ready for review. Converting to draft. |
Downloads: - Use temp file + atomic rename to prevent corruption on network failure - Verify file size matches expected before saving - Add 5-minute timeout for large downloads Updates: - Download new version BEFORE deleting old (safe if connection fails) Auto-sync existing mods: - Scans mods folder and calculates SHA-512 hash - Looks up hash on Modrinth API to identify mods - Automatically tracks manually-installed mods for updates - Example: WorldEdit installed manually → detected → update available 
Adds 'Auto-update Modrinth mods' toggle in Settings → General. When enabled, the launcher automatically: 1. Checks for updates on all tracked Modrinth mods before launch 2. Downloads and installs new versions if available 3. Shows progress: 'Updating Sodium...' etc. Disabled by default. Updates run silently - if update fails, the game still launches with existing mod versions.
|
Fixed the issues, ready for review now. |
src/lib/main/ModrinthUpdates.svelte
Outdated
| <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"> | ||
| <path d="M1 4v6h6M23 20v-6h-6"/> | ||
| <path d="M20.49 9A9 9 0 0 0 5.64 5.64L1 10m22 4l-4.64 4.36A9 9 0 0 1 3.51 15"/> | ||
| </svg> |
There was a problem hiding this comment.
AI generated SVG slop. Replace with actual icon.
src/lib/main/ModrinthUpdates.svelte
Outdated
| <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"> | ||
| <path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"/> | ||
| <polyline points="7 10 12 15 17 10"/> | ||
| <line x1="12" y1="15" x2="12" y2="3"/> | ||
| </svg> |
There was a problem hiding this comment.
AI generated SVG slop. Replace with actual icon.
src-tauri/src/app/modrinth.rs
Outdated
|
|
||
| let response = HTTP_CLIENT | ||
| .get(&url) | ||
| .header("User-Agent", "LiquidLauncher/0.5.0") |
src-tauri/src/app/modrinth.rs
Outdated
|
|
||
| let response = HTTP_CLIENT | ||
| .get(&url) | ||
| .header("User-Agent", "LiquidLauncher/0.5.0") |
|
Hi @1zun4, Thank you for the thorough code review and detailed feedback. I appreciate you taking the time to identify these issues. I'll work on addressing all the points you've raised. Would you prefer I submit these changes as separate commits for easier review, or would you like me to address everything in a single comprehensive update? Thanks again for the feedback! |
|
One pull request per feature is the correct way. I'm asking you to review your own code. |
4404c60 to
9b697bb
Compare
- replace placeholder icons with project SVGs\n- add uninstall + auto-refresh for Modrinth updates list\n- align custom mods section with Mods tab\n- use shared HTTP user agent\n- keep lockfile in sync
aaeec17 to
db7de38
Compare
Current implementation works and Maven can be a future improvement |
- make refresh button more visible with glow and spin\n- stabilize Modrinth install state during rapid installs\n- uninstall Modrinth mods by project id

Add ability to search, install and manage mods from Modrinth:
Creates a dedicated "Mods" tab in the version selector.
Mods are downloaded to the custom_mods folder with metadata tracking.
Example: Go to Mods tab, search "sodium", click install,
and the mod will be ready for your next launch.
Safe: Metadata stored in
.modrinth_meta.jsontracks installed mods.Updating a mod removes the old file before downloading the new one.
Closes #255
Screenshots