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 | |
| echo "Making windows movable by CTRL-⌘" | |
| defaults write -g NSWindowShouldDragOnGesture -bool true | |
| # The dock on your Mac can sometimes feel too crowded. One way to fix that is by hiding all inactive apps from the dock. You can do this with a simple Terminal command. | |
| echo "cleaning dock" | |
| defaults write com.apple.dock static-only -bool true; killall Dock | |
| # Add an option that lets you quit the app (which means relaunch in the case of Finder) from the menu bar. Use this command to get the job done: |
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
| Save this to ~/.firewalla/config/post_main.d inorder to make sure homebridge restarts automatically every time Firewalla does. That directory may not exist so just create it if that's the case. |
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 | |
| # https://hub.docker.com/r/assaflavie/runlike/ | |
| if [ $1 ] ; then | |
| sudo docker run -v /var/run/docker.sock:/var/run/docker.sock assaflavie/runlike $1 | |
| else | |
| echo -e "\nYou must specify a docker container that is running, like so: \n\n $0 homebridge\n " | |
| exit |
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 | |
| echo Running installer | |
| read -p "Do you want to continue? (y|n) ? " -n 1 -r | |
| if [[ $REPLY =~ ^[Yy]$ ]]; then | |
| sudo su - | |
| systemctl stop docker-compose@* | |
| systemctl stop docker | |
| cd /var/lib/docker/ |
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
| function acraCleanup() { | |
| var rowsToKeep = 1996; // CHANGE TO YOUR DESIRED NUMBER OF ROWS TO KEEP. | |
| var rows = SpreadsheetApp.getActiveSheet().getLastRow(); | |
| var numToDelete = rows - rowsToKeep -1; | |
| if ( numToDelete >= 1 ) { | |
| SpreadsheetApp.getActiveSheet().deleteRows(2, numToDelete); | |
| } | |
| } |
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 | |
| # v 2.1.0 | |
| syslog=/etc/rsyslog.d/09-externalserver.conf | |
| # this logs notice and above. use *.* log everything. | |
| filter=*.notice | |
| server=192.168.0.19 # Change the server to the IP of your syslog server. | |
| port=514 | |
| hostname=firewalla | |
| valid=$(grep "$server:$port" $syslog 2>/dev/null) |
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 | |
| ip=$1 | |
| port=$2 | |
| # port=${2:-5001} | |
| if [[ $ip =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]] && [[ $port =~ ^[0-9]* ]] ; then | |
| nc -vnz $ip $port | |
| exit | |
| else | |
| echo -e "Sorry you have to enter an IP and port?\n\n $(basename $0) [xxx.xxx.xxx.xxx port]" |
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 | |
| app=iftop | |
| command_exists () { | |
| command -v $1 >/dev/null 2>&1; | |
| } | |
| if command_exists $app; then | |
| echo -e "\n\n$app instaleld!\n bye" |
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 | |
| # 2.1 | |
| # https://gist.github.com/mbierman/561643e89e98137ea5f11f02a0f3ccd2 | |
| # Put this script in ~/.firewalla/config/post_main.d in order to resinstall after upgrades | |
| log=/data/fw_reboot.txt | |
| if ! [ -w $log ] ; then | |
| sudo touch $log | |
| sudo chmod a+w $log |
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/sh | |
| # | |
| # Docker Homebridge Custom Startup Script - oznu/homebridge | |
| # | |
| # This script can be used to customise the environment and will be executed as | |
| # the root user each time the container starts. | |
| # | |
| # If using this to install plugins DO NOT use the global flag (-g). | |
| # |