Skip to content

Instantly share code, notes, and snippets.

View dyigitpolat's full-sized avatar
🌛

Yigit Polat dyigitpolat

🌛
View GitHub Profile
@quinncomendant
quinncomendant / cpu-threshold-alert-microsoft-edge
Last active September 18, 2022 14:40
Detect if Microsoft Edge has been using more than 90% CPU continuously.
#!/usr/bin/env bash
# Microsoft Edge on macOS sometimes will get stuck using 100% CPU endlessly, requiring a relaunch to stop.
# See issue at https://techcommunity.microsoft.com/t5/discussions/edge-browser-100-cpu-requires-force-quit-macos-mojave-and-v91-0/m-p/2441462/highlight/true#M48074
#
# This script will display a macOS notification if Microsoft Edge has been using more
# than 90% CPU continuously for more than 10 minutes. It only checks the main
# Microsoft Edge process, not the Microsoft Edge Helper processes.
#
# Save it to ~/bin/cpu-threshold-alert-microsoft-edge
@jonpacker
jonpacker / gist:2107554
Created March 19, 2012 10:59
Force unmount a nonresponsive SSHFS
kill -9 <sshfs pid>
fusermount -u <mountpoint>