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
| find /opt/homebrew/var -type f -name "*.pid" | |
| find /opt/homebrew/var -type f -name "*.pid" -exec rm {} \; |
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
| osascript -e 'quit app "Docker"' # stop | |
| open -a Docker # start | |
| docker info |
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
| tccutil reset Camera | |
| tccutil reset Microphone | |
| tccutil reset Location | |
| tccutil reset AddressBook | |
| tccutil reset Calendar | |
| tccutil reset Photos | |
| tccutil reset Reminders | |
| tccutil reset BluetoothAlways | |
| tccutil reset SystemPolicyDocumentsFolder |
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
| # /opt/homebrew/etc/squid.conf | |
| debug_options ALL,1 33,2 | |
| # 8.8.8.8 8.8.4.4 blocked in Russia | |
| dns_nameservers 1.1.1.1 9.9.9.9 | |
| dns_v4_first on | |
| visible_hostname localhost | |
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
| brew install squid | |
| brew link --force squid | |
| sudo ln -fs /opt/homebrew/opt/squid/sbin/squid /usr/local/bin/squid | |
| sudo ln -fs /opt/homebrew/Cellar/squid/6.11/libexec/security_file_certgen /usr/local/bin/security_file_certgen | |
| find /opt/homebrew -name "security_file_certgen" 2>/dev/null | |
| # /opt/homebrew/Cellar/squid/6.11/libexec/security_file_certgen | |
| sudo mkdir -p /usr/local/etc/squid/ssl_cert |
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
| SELECT rolname FROM pg_roles; | |
| --DROP USER postgres; | |
| CREATE USER postgres WITH PASSWORD 'postgres'; | |
| ALTER USER postgres WITH SUPERUSER; |
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
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
| <plist version="1.0"> | |
| <dict> | |
| <key>KeepAlive</key> | |
| <true/> | |
| <key>Label</key> | |
| <string>homebrew.mxcl.postgresql</string> | |
| <key>ProgramArguments</key> | |
| <array> |
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
| import os | |
| import requests | |
| headers = { | |
| "Authorization": "Bearer %s" % os.getenv('GITHUB_TOKEN') | |
| } | |
| r = requests.get("https://api.github.com/",headers=headers) | |
| for k,v in r.headers.items(): | |
| print('%s: %s' % (k,v)) |
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
| child-pids() { | |
| local childs= | |
| childs="$(pgrep -P "$1")" | |
| [[ -n "$childs" ]] && while IFS= read child; do | |
| pids "$child" | |
| done <<< "$childs" | |
| [[ $1 != $$ ]] && echo "$1" | |
| } | |
| child-pids "$1" |
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
| Development Status :: 1 - Planning | |
| Development Status :: 2 - Pre-Alpha | |
| Development Status :: 3 - Alpha | |
| Development Status :: 4 - Beta | |
| Development Status :: 5 - Production/Stable | |
| Development Status :: 6 - Mature | |
| Development Status :: 7 - Inactive | |
| Environment :: Console | |
| Environment :: Console :: Curses | |
| Environment :: Console :: Framebuffer |