diff --git a/.github/README1.md b/.github/README1.md index 3845c60..8a3c27f 100644 --- a/.github/README1.md +++ b/.github/README1.md @@ -22,13 +22,25 @@ All builds run in parallel: ### Creating a Release -1. Update version in `package.json` +**⚠️ IMPORTANT: Semantic Versioning Required** + +This project uses **strict semantic versioning with numerical versions only**: +- ✅ **Valid**: `2.0.1`, `2.0.11`, `2.1.0`, `3.0.0` +- ❌ **Invalid**: `2.0.2b`, `2.0.2a`, `2.0.1-beta` + +**Format**: `MAJOR.MINOR.PATCH` (e.g., `2.0.11`) + +The auto-update system requires semantic versioning for proper version comparison. Letter suffixes are not supported. + +**Steps:** + +1. Update version in `package.json` (use numerical format only, e.g., `2.0.11`) 2. Commit and push to `main` 3. Create and push a version tag: ```bash -git tag v2.0.1 -git push origin v2.0.1 +git tag v2.0.11 +git push origin v2.0.11 ``` The workflow will: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5f8216a..4e09ae1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -33,10 +33,11 @@ jobs: name: linux-builds path: | dist/*.AppImage + dist/*.AppImage.blockmap dist/*.deb dist/*.rpm dist/*.pacman - dist/latest.yml + dist/latest-linux.yml build-windows: runs-on: windows-latest @@ -53,6 +54,7 @@ jobs: name: windows-builds path: | dist/*.exe + dist/*.exe.blockmap dist/latest.yml build-macos: @@ -115,4 +117,4 @@ jobs: generate_release_notes: true draft: true # DYNAMIC FLAGS: Mark as pre-release ONLY IF it's NOT a tag (meaning it's a branch push) - prerelease: ${{ github.ref_type != 'tag' }} + prerelease: ${{ github.ref_type != 'tag' }} \ No newline at end of file diff --git a/GUI/js/update.js b/GUI/js/update.js index 00393b4..aa44277 100644 --- a/GUI/js/update.js +++ b/GUI/js/update.js @@ -10,6 +10,23 @@ class ClientUpdateManager { this.showUpdatePopup(updateInfo); }); + // Listen for electron-updater events + window.electronAPI.onUpdateAvailable((updateInfo) => { + this.showUpdatePopup(updateInfo); + }); + + window.electronAPI.onUpdateDownloadProgress((progress) => { + this.updateDownloadProgress(progress); + }); + + window.electronAPI.onUpdateDownloaded((updateInfo) => { + this.showUpdateDownloaded(updateInfo); + }); + + window.electronAPI.onUpdateError((errorInfo) => { + this.handleUpdateError(errorInfo); + }); + this.checkForUpdatesOnDemand(); } @@ -33,23 +50,46 @@ class ClientUpdateManager {
Current Version: - ${updateInfo.currentVersion} + ${updateInfo.currentVersion || updateInfo.version || 'Unknown'}
New Version: - ${updateInfo.newVersion} + ${updateInfo.newVersion || updateInfo.version || 'Unknown'}
A new version of Hytale F2P Launcher is available.
- Please download the latest version to continue using the launcher. + Downloading update automatically... +
- + + +