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 | |
# From https://stackoverflow.com/questions/192249/how-do-i-parse-command-line-arguments-in-bash | |
while [[ "$#" -gt 0 ]]; do | |
case $1 in | |
-t|--target) target="$2"; shift ;; | |
-u|--uglify) uglify=1 ;; | |
*) echo "Unknown parameter passed: $1"; exit 1 ;; | |
esac |
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/sh | |
CLOUDDEST="<remote destination>:/" | |
RCLONE_WARNING_SIZE_GB=500 # Replace as desired | |
RCLONE_ALERT_SIZE_GB=1000 # Replace as desired | |
echo "Checking Rclone remote size ($CLOUDDEST)" | |
rclone_size="$(rclone size --json $CLOUDDEST)" | |
rclone_size_bytes="$(echo $rclone_size | jq '.bytes')" |
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
# If the repository has already been cloned/initialized | |
# First, cd to the folder containing the project of interest | |
# Then, execute the following: | |
git config core.sshCommand "ssh -i <path to SSH key>" | |
# If the repository has NOT yet been cloned: | |
git clone git@github.com:<username>/<repo name> --config sshCommand "ssh -i <path to SSH key>" |
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
du ./* -s --inodes | sort -rh |