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
| #!/usr/bin/env bash | |
| CLIENT_DB="$HOME/Library/Application Support/CloudDocs/session/db/client.db" | |
| [[ -e $CLIENT_DB ]] || { echo "db not found"; exit 1; } | |
| mapfile -t ITEM_IDS < <(sqlite3 "$CLIENT_DB" <<-EOS | |
| SELECT throttle_id | |
| FROM client_sync_up | |
| EOS | |
| ) |
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
| # place in same dir as compose.yml, adjust as needed for your environment | |
| # create a limited user and run `id <username>` to get the PUID/PGID values | |
| TZ=America/New_York | |
| CNAME=speedtest | |
| DOCKER_DIR=/volume1/docker | |
| PUID=1030 | |
| PGID=100 | |
| MARIADB_DATABASE=speedtest-tracker | |
| MARIADB_USER=speedy |
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
| Just something weird I'm investigating | |
| https://www.alfredforum.com/topic/20542-with-space-keywordargument-option-being-ignored-script-filter/ |
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
| #!/usr/bin/env python3 | |
| """ | |
| generates multiple random passphrases in one go | |
| https://github.com/ulif/diceware/issues/53 | |
| requires diceware: pip install diceware | |
| """ | |
| import os |
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
| #!/usr/bin/env bash | |
| ENDPOINT='https://hc-ping.com/{insert-HealthChecks-UUID-here}' | |
| #logfile location changed as of v4.1.2-4039 | |
| #LOGFILE='/var/log/synolog/synobackup.log' | |
| LOGFILE='/volume1/@appdata/HyperBackup/log/synolog/synobackup.log' | |
| [[ -e $LOGFILE ]] || exit 1 | |
| awk -f- $LOGFILE <<'EOF' |
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
| #!/usr/bin/env bash | |
| # https://docs.syncthing.net/rest/events-get.html | |
| # https://docs.syncthing.net/dev/events.html#event-types | |
| APIKEY=$(defaults read com.github.xor-gate.syncthing-macosx ApiKey) | |
| [[ -n "$APIKEY" ]] || { echo "error retreiving API key"; exit 1; } | |
| ENDPOINT='http://localhost:8384/rest/events/disk' | |
| INTERVAL=2 |
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
| #!/usr/bin/env bash | |
| ############################################### | |
| ### requires python3 installed via Homebrew ### | |
| ############################################### | |
| unset TARGETED_URL | |
| MENU_KIND=-1 | |
| SELECTED_ITEM_URLS=() |
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 | |
| # put the line below at the end of /etc/rc.gatway_alarm, just above the final `exit`: | |
| # /root/wgfix.sh "${GW}" "${alarm_flag}" | |
| # set the 2 variables below to match the interface name and public key | |
| # of the wg tunnel that you want to "fail back" when your default gateway changes | |
| # WG_PEER_PUBLIC_KEY should be the public key from the FAR side (i.e the one from the PEERS tab) | |
| WG_IFNAME='tun_wg0' | |
| WG_PEER_PUBLIC_KEY='xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' |
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
| <?php | |
| // includes | |
| require_once("functions.inc"); | |
| require_once("system.inc"); | |
| require_once("util.inc"); | |
| // global dpinger_dont_add_static_routes option | |
| $dp_global_sr_disable = (isset($config['system']['dpinger_dont_add_static_routes']) ? 'ENABLED (checked)' : 'default (unchecked)'); | |
| printf("==> global `dpinger_dont_add_static_routes` setting: %s\n", $dp_global_sr_disable); |
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
| #!/usr/bin/env python3 | |
| import sys | |
| import plistlib | |
| try: | |
| f = sys.argv[1] | |
| k = sys.argv[2] | |
| except: | |
| print(f'supply .plist pathname AND key as args', file=sys.stderr) |