-
Notifications
You must be signed in to change notification settings - Fork 1
Auto-Update #4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Auto-Update #4
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds automatic update functionality to the Anytype CLI by extracting update logic into a reusable core package and implementing background update checks. The update now runs silently in the background on CLI startup once every 24 hours.
- Refactored update logic from
cmd/update/update.gotocore/update/update.gofor reusability - Added automatic update checking via
core/autoupdate/autoupdate.gothat runs in a goroutine on startup - Integrated auto-update into main entry point with lock file to prevent concurrent updates
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 9 comments.
| File | Description |
|---|---|
| main.go | Added auto-update check on CLI startup |
| core/update/update.go | New package containing extracted update logic with GitHub API integration and archive extraction |
| core/autoupdate/autoupdate.go | New package implementing background update checks with 24-hour interval and file-based locking |
| cmd/update/update.go | Refactored to use core/update package, removed duplicated code |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Copilot reviewed 8 out of 9 changed files in this pull request and generated 5 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
No description provided.