[PR #41] [MERGED] feat(update): implement auto-update feature for GitHub Releases #60

Closed
opened 2026-03-03 15:57:34 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/mrgoonie/winshot/pull/41
Author: @mrgoonie
Created: 12/14/2025
Status: Merged
Merged: 12/14/2025
Merged by: @mrgoonie

Base: devHead: goon


📝 Commits (3)

  • 94ed01c feat(annotations): implement undo/redo with keyboard shortcuts
  • bfa2744 fix(settings): migrate background images from localStorage to backend config
  • 96194ef feat(update): implement auto-update feature for GitHub Releases

📊 Changes

15 files changed (+677 additions, -31 deletions)

View changed files

📝 app.go (+22 -0)
📝 frontend/dist/index.html (+2 -2)
📝 frontend/src/App.tsx (+99 -24)
📝 frontend/src/components/annotation-toolbar.tsx (+39 -0)
📝 frontend/src/components/settings-modal.tsx (+39 -1)
📝 frontend/src/components/settings-panel.tsx (+38 -4)
frontend/src/components/update-modal.tsx (+128 -0)
frontend/src/hooks/use-undo-redo.ts (+107 -0)
📝 frontend/wailsjs/go/main/App.d.ts (+9 -0)
📝 frontend/wailsjs/go/main/App.js (+16 -0)
📝 frontend/wailsjs/go/models.ts (+46 -0)
📝 go.mod (+1 -0)
📝 go.sum (+2 -0)
📝 internal/config/config.go (+11 -0)
internal/updater/updater.go (+118 -0)

📄 Description

Summary

  • Implemented auto-update feature for Issue #40 by checking GitHub Releases API on app startup
  • Added update notification modal with version info and release notes
  • Users can skip specific versions and toggle auto-check on startup
  • Download button opens GitHub releases page for portable exe

Changes

Backend (Go)

  • Created internal/updater/updater.go - Module for checking GitHub Releases API with semver comparison
  • Modified internal/config/config.go - Added UpdateConfig struct with CheckOnStartup and SkippedVersion fields
  • Modified app.go - Added CheckForUpdate, OpenURL, SetSkippedVersion, GetSkippedVersion bindings
  • Added dependency: github.com/Masterminds/semver/v3

Frontend (React/TypeScript)

  • Created frontend/src/components/update-modal.tsx - Update notification modal component
  • Modified frontend/src/App.tsx - Integrated update check on app startup
  • Modified frontend/src/components/settings-modal.tsx - Added "Updates" tab with toggle control
  • Created frontend/src/hooks/use-undo-redo.ts - Undo/redo hook (Issue #39)
  • Modified frontend/src/components/annotation-toolbar.tsx - Added undo/redo buttons
  • Updated Wails bindings for new Go functions

Test plan

  • Update check runs on app startup when enabled
  • Modal displays current version, latest version, and release notes
  • "Skip This Version" button persists skipped version to config
  • "Download" button opens GitHub releases page
  • Settings toggle for auto-check can be enabled/disabled
  • Skipped versions do not trigger notification until new version is released
  • No update notification shows when already on latest version
  • Manual update check works if added to menu (for future)

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/mrgoonie/winshot/pull/41 **Author:** [@mrgoonie](https://github.com/mrgoonie) **Created:** 12/14/2025 **Status:** ✅ Merged **Merged:** 12/14/2025 **Merged by:** [@mrgoonie](https://github.com/mrgoonie) **Base:** `dev` ← **Head:** `goon` --- ### 📝 Commits (3) - [`94ed01c`](https://github.com/mrgoonie/winshot/commit/94ed01c486628da51398e587edb1fb497f669bf5) feat(annotations): implement undo/redo with keyboard shortcuts - [`bfa2744`](https://github.com/mrgoonie/winshot/commit/bfa27442f2ac80791a45443458064864692bdab0) fix(settings): migrate background images from localStorage to backend config - [`96194ef`](https://github.com/mrgoonie/winshot/commit/96194ef13e13b909f3fb16cf0b025a56005041c0) feat(update): implement auto-update feature for GitHub Releases ### 📊 Changes **15 files changed** (+677 additions, -31 deletions) <details> <summary>View changed files</summary> 📝 `app.go` (+22 -0) 📝 `frontend/dist/index.html` (+2 -2) 📝 `frontend/src/App.tsx` (+99 -24) 📝 `frontend/src/components/annotation-toolbar.tsx` (+39 -0) 📝 `frontend/src/components/settings-modal.tsx` (+39 -1) 📝 `frontend/src/components/settings-panel.tsx` (+38 -4) ➕ `frontend/src/components/update-modal.tsx` (+128 -0) ➕ `frontend/src/hooks/use-undo-redo.ts` (+107 -0) 📝 `frontend/wailsjs/go/main/App.d.ts` (+9 -0) 📝 `frontend/wailsjs/go/main/App.js` (+16 -0) 📝 `frontend/wailsjs/go/models.ts` (+46 -0) 📝 `go.mod` (+1 -0) 📝 `go.sum` (+2 -0) 📝 `internal/config/config.go` (+11 -0) ➕ `internal/updater/updater.go` (+118 -0) </details> ### 📄 Description ## Summary - Implemented auto-update feature for Issue #40 by checking GitHub Releases API on app startup - Added update notification modal with version info and release notes - Users can skip specific versions and toggle auto-check on startup - Download button opens GitHub releases page for portable exe ## Changes ### Backend (Go) - Created `internal/updater/updater.go` - Module for checking GitHub Releases API with semver comparison - Modified `internal/config/config.go` - Added UpdateConfig struct with CheckOnStartup and SkippedVersion fields - Modified `app.go` - Added CheckForUpdate, OpenURL, SetSkippedVersion, GetSkippedVersion bindings - Added dependency: `github.com/Masterminds/semver/v3` ### Frontend (React/TypeScript) - Created `frontend/src/components/update-modal.tsx` - Update notification modal component - Modified `frontend/src/App.tsx` - Integrated update check on app startup - Modified `frontend/src/components/settings-modal.tsx` - Added "Updates" tab with toggle control - Created `frontend/src/hooks/use-undo-redo.ts` - Undo/redo hook (Issue #39) - Modified `frontend/src/components/annotation-toolbar.tsx` - Added undo/redo buttons - Updated Wails bindings for new Go functions ## Test plan - [x] Update check runs on app startup when enabled - [x] Modal displays current version, latest version, and release notes - [x] "Skip This Version" button persists skipped version to config - [x] "Download" button opens GitHub releases page - [x] Settings toggle for auto-check can be enabled/disabled - [x] Skipped versions do not trigger notification until new version is released - [x] No update notification shows when already on latest version - [x] Manual update check works if added to menu (for future) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-03 15:57:34 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/winshot#60
No description provided.