BASH script to kill most app/process logging in macOS Sierra – replace USERNAME with your username (use whois in terminal to discover this)
This file contains 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 | |
for i in {1..70000}; | |
do | |
NUM=`ps -o pid -p $i | grep $i ` | |
if [ $NUM ]; | |
then | |
echo " $i $NUM " | |
log config --process=$i --mode 'level:off' | |
fi | |
done | |
rm -rf /private/var/log/* | |
rm -rf /Library/Logs/* | |
rm -rf /Users/USERNAME/Library/Logs/* |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment