Repository navigation
feat!: modernize onto keepawake-rs 0.6.0 and revamp activity simulation - #1
Merged
Merged
Conversation
Drop continue-on-error from the formatting step so misformatted code fails CI, and update actions/checkout v3 -> v5.
Bump zbus 3->5, windows 0.52->0.62, sysinfo 0.30->0.37, shadow-rs 0.26->1.4, derive_builder 0.12->0.20, enigo 0.1->0.6; replace apple-sys/core-foundation with objc2-core-foundation/objc2-io-kit on macOS; add thiserror. Make anyhow bin-only, add an 'activity' feature gating enigo, switch build.rs to shadow-rs ShadowBuilder, and bump the crate to 0.2.0.
Replace the fire-and-forget simulate_activity() with an ActivitySimulator that stops and joins its worker thread on drop and surfaces backend init errors. Add --method <mouse|key> (mouse jiggle, default, or a no-op F15 keypress with no cursor movement) and --interval <SECONDS>. Also adopt upstream's CLI fixes: block on the watched PID via sysinfo 0.37 and exit 130 on Ctrl-C.
Document --method and --interval, refresh the usage block, add a status-tracker section, and reconcile the changelog with the shipped activity behavior.
…ror type macOS uses objc2-io-kit assertions, Linux uses the zbus 5 #[proxy] macro, and Windows uses WindowsError::from_thread() (from_win32 was removed in windows 0.62). The library now exposes a thiserror-based Error/Result instead of anyhow and declares the feature-gated activity module. BREAKING CHANGE: library APIs return keep_active::Error instead of anyhow::Error.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rebases the fork onto upstream keepawake-rs 0.6.0 and rewrites the fork's activity feature as a proper RAII subsystem. Bumps the crate to 0.2.0.
Upstream modernization (0.4.5-era → 0.6.0)
apple-sys/core-foundationtoobjc2-core-foundation/objc2-io-kit.zbus3 → 5 (#[dbus_proxy]→#[proxy]).windows0.52 → 0.62;WindowsError::from_win32()→from_thread()(the former was removed in 0.62).thiserror-basedError/Resultinstead ofanyhow;anyhowis nowbin-only.sysinfo0.30 → 0.37,shadow-rs0.26 → 1.4 (ShadowBuilder),derive_builder0.12 → 0.20,enigo0.1 → 0.6, addedthiserror2.-w <PID>now blocks on the process via the sysinfo 0.37 API instead of polling; exits130on Ctrl-C.Activity feature revamp
simulate_activity()(infinite loop, unreachable error path, hardcoded 60s) with an RAIIActivitySimulatorthat stops and joins its worker thread on drop and surfaces backend-init errors synchronously.--method <mouse|key>:mouse(default) keeps the existing 1px nudge;keytapsF15with no cursor movement for a distraction-free option.--interval <SECONDS>(default 60).activityCargo feature (pullsenigo); enabled automatically bybin.Verification
--all-featuresbuild,clippy,fmt, tests/doctests, release build, and binary smoke tests — all clean.cargo checkclean for the ported backends +enigo0.6.continue-on-errorthat was hidingcargo fmtfailures; bumpedactions/checkoutv3 → v5.Breaking changes
keep_active::Errorinstead ofanyhow::Error.simulate_activity()is replaced byActivitySimulator.