Last active
September 17, 2024 23:16
-
-
Save habovh/5bb425b431dded44e8b666561aead17d to your computer and use it in GitHub Desktop.
Simple bash script to quickly enable/disable macOS crash reporting dialogs. Tested on macOS Sierra.
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
#!/bin/bash | |
# Author: Jordan Becker (https://becker.io/) | |
if [ $# -lt 1 ]; then | |
echo "Usage: $0 (on|off|read)" | |
echo "Lets you quickly enable or disable macOS crash reporting dialogs. Useful for betas ;)" | |
exit 1 | |
fi | |
case "$1" in | |
"on") | |
defaults write com.apple.CrashReporter DialogType crashreport | |
echo "Successfully enabled macOS crash reporting dialogs." | |
exit 0 | |
;; | |
"off") | |
defaults write com.apple.CrashReporter DialogType none | |
echo "Successfully disabled macOS crash reporting dialogs." | |
exit 0 | |
;; | |
"read") | |
echo "Current dialog type: $(defaults read com.apple.CrashReporter DialogType)" | |
exit 0 | |
;; | |
*) | |
echo "Unrecognized parameter '$1'." | |
echo "Usage: $0 (on|off|read)" | |
echo "Current dialog type: $(defaults read com.apple.CrashReporter DialogType)" | |
exit 0 | |
;; | |
esac |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment