3 hours ago · Tech · hide · 0 comments

Seeking a simpler mouse jiggler than WakeyWakey, move-mouse-macOS, or MoveMouse, queried Opus 5.5; it conjured up tinynudge in one shot, just 30 lines of Swift and 54k compiled: // tinynudge: Prevent sleep with 1px cursor nudges when idle and a caffeinate-style power assertion // Build: swiftc -O tinynudge.swift -o tinynudge && strip tinynudge Usage: tinynudge [seconds] (default 60, Ctrl-C to quit) import ApplicationServices import IOKit.pwr_mgt setbuf(stdout, nil) let interval = max(1, Double(CommandLine.arguments.dropFirst().first ?? "") ?? 60) var assertion = IOPMAssertionID(0) IOPMAssertionCreateWithName(kIOPMAssertionTypePreventUserIdleDisplaySleep as CFString, IOPMAssertionLevel(kIOPMAssertionLevelOn), "tinynudge" as CFString, &assertion) if !AXIsProcessTrustedWithOptions([kAXTrustedCheckOptionPrompt.takeUnretainedValue(): true] as CFDictionary) { print("tinynudge: Grant Terminal Accessibility access (\"Device Control and Data Access\" on macOS 27+) in System Settings → Privacy…

No comments yet. Log in to reply on the Fediverse. Comments will appear here.