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 datetime | |
| import urllib.request | |
| import urllib.error | |
| JACKETT_BASEURL = "http://jackett.local" | |
| TRACKERS = ["tracker", "names", "here"] | |
| # i just output one line of somewhat obscured info to a file | |
| # that's available on a public url via symlink to my http server | |
| # so betterstack can alert when it doesn't say "it's all good!" |
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 json | |
| from hashlib import blake2b | |
| key = b'examplekey' | |
| traits = [ | |
| b'exampletrait', | |
| b'anotherexample' | |
| ] | |
| hashes = json.dumps([blake2b(trait, digest_size=64, key=key).hexdigest() for trait in traits]) |
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
| version: "3" | |
| services: | |
| sonarr: | |
| image: ghcr.io/linuxserver/sonarr:latest | |
| container_name: sonarr | |
| environment: | |
| - PUID=1002 | |
| - PGID=1002 | |
| - TZ=America/New_York | |
| volumes: |
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
| [Unit] | |
| Description=Home Assistant service | |
| Requires=docker.service | |
| After=docker.service | |
| [Service] | |
| Restart=always | |
| User=hassio | |
| Group=hassio |
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
| version: '2' | |
| services: | |
| homeassistant: | |
| container_name: home-assistant | |
| image: homeassistant/home-assistant:stable | |
| volumes: | |
| - /opt/home-assistant/config:/config | |
| devices: | |
| - /dev/ttyUSB1:/dev/ttyUSB1 | |
| environment: |
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 | |
| ###################################################################### | |
| # # | |
| # da config zone # | |
| # # | |
| ###################################################################### | |
| # where to put all the converted files, relative to where this script lives | |
| OUTPUT_DIR="output-dir" |
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 | |
| if ! [[ $1 =~ ^-?[0-9]+$ ]]; then | |
| echo "Percentage must be an integer" 1>&2 | |
| exit 1 | |
| fi | |
| if (( $1 < 0 || $1 > 100 )); then | |
| echo "Percentage value must be at least 0 or at most 100" 1>&2 | |
| exit 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
| ls parent-dir/ | xargs -I{} -n 1 cp my-cool-file.tgz parent-dir/{}/ |
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 threading | |
| import time | |
| from selenium import webdriver | |
| TOTAL_WORKERS = 10 | |
| TWITTER_USER = 'butts' | |
| TWITTER_PASSWORD = 'bu77s' | |
| def worker(): |
NewerOlder