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
#!/usr/bin/env python3 | |
import os | |
problems = { | |
"problems": { | |
"Array": { | |
"two-sum": { | |
"name": "Two Sum", | |
"premium": False, |
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
GITHUB_USER=user | |
GITHUB_TOKEN=github_pat_abcdefghijklmnopqrstuvwxyz0123456789 |
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
version: "3.8" | |
services: | |
changedetection: | |
container_name: changedetection | |
hostname: changedetection | |
image: ghcr.io/dgtlmoon/changedetection.io:latest | |
environment: | |
- TZ=America/Los_Angeles | |
- PLAYWRIGHT_DRIVER_URL=ws://playwright-chrome:3000/?stealth=1&--disable-web-security=true&token=<redacted> |
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
alias ssh='ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no"' |
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
#!/usr/bin/env python3 | |
import multiprocessing | |
import random | |
import time | |
class Worker(multiprocessing.Process): |
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
[ | |
{ | |
"form": "1", | |
"description": "Application for registration or exemption from registration as a national securities exchange (PDF)", | |
"last_updated": "Feb 1999", | |
"sec_number": "SEC1935", | |
"topics": [ | |
"Self-Regulatory Organizations" | |
] | |
}, |
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
# automate sourcing virtualenv if venv dir in local dir. | |
function cd() { | |
builtin cd "$@" | |
if [[ -z "$VIRTUAL_ENV" ]] ; then | |
## If venv folder is found then activate the vitualenv | |
if [[ -d ./venv ]] ; then | |
source ./venv/bin/activate | |
fi | |
else |
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
#!/usr/bin/bash | |
cat .env | awk -F"\=" '{ print $1 }' | grep -v -e '^$' | while read line; do echo "ENV $line=\"\""; done |
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
# requires pup, and jq to be installed | |
# this is likely to break based on the css selector, but a quick hack for now. | |
curl "https://docs.aws.amazon.com/general/latest/gr/rande.html" | pup "#w420aac12b7b9c13 > tbody > tr json{}" | jq '.[].children | { region: .[1].text, name: .[0].text} ' | sed -e '$!s/"$/",/' | sed -e 's/}/},/' |
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 | |
# say -v ? lists the voices available | |
for voice in $(say -v ? | awk '{ print $1 }') | |
do | |
echo "==> ${voice}" | |
say -v $voice "hello this is ${voice}" | |
sleep 1 | |
done |
NewerOlder