Skip to content
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

✨ Disable update checks via variables #676

Merged
merged 6 commits into from
Jan 22, 2025
Merged

✨ Disable update checks via variables #676

merged 6 commits into from
Jan 22, 2025

Conversation

SenpaiHunters
Copy link
Collaborator

  • Introduced updatesEnabled class to first check for the LOOP_SKIP_UPDATE_CHECK environment variable, allowing users to skip update checks by setting this variable, otherwise, setting Defaults to control automatic updates.
  • This allows for disabling automatic updates with defaults write com.MrKai77.Loop updatesEnabled -bool false and reset (to default of true) with defaults delete com.MrKai77.Loop updatesEnabled, otherwise, an environmental variable of LOOP_SKIP_UPDATE_CHECK=1
  • Modified the initialization logic to only set up the update timer if updates are enabled and the environment variable / defaults are not set.
  • Added an environment variable configuration in the Xcode scheme to facilitate testing and development without update checks.

- Introduced `updatesEnabled` setting in `Defaults` to control automatic updates.
- This allows for disabling automatic updates with `defaults write com.MrKai77.Loop updatesEnabled -bool false` and reset (to default of `true`) with `defaults delete com.MrKai77.Loop updatesEnabled`
- Enhanced `Updater` class to handle update checks based on the new setting, including a disabled state.
- Updated `AboutConfigurationView` to reflect the update status and provide user feedback.
- Minor adjustments to project settings and build configurations.
- Updated `updatesEnabled` property in `Updater` class to first check for the `LOOP_SKIP_UPDATE_CHECK` environment variable, allowing users to skip update checks by setting this variable.
- Modified the initialization logic to only set up the update timer if updates are enabled and the environment variable is not set.
- Added an environment variable configuration in the Xcode scheme to facilitate testing and development without update checks.
@SenpaiHunters SenpaiHunters self-assigned this Jan 21, 2025
@SenpaiHunters SenpaiHunters linked an issue Jan 21, 2025 that may be closed by this pull request
4 tasks
@SenpaiHunters SenpaiHunters changed the title ✨ Add an option to disable update checks ✨ Disable update checks via variables Jan 21, 2025
Copy link
Owner

@MrKai77 MrKai77 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Made a few little changes, looks good!

@MrKai77 MrKai77 merged commit ccab30f into develop Jan 22, 2025
1 check passed
@MrKai77 MrKai77 deleted the disable-updates branch January 22, 2025 05:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

✨ Option to disable update checks
2 participants