- Install ffmpeg.
brew install ffmpeg
- Figure out which device to use.
ffmpeg -f avfoundation -list_devices true -i ""
Ouput will look like:
| this word list comprises the intersection of 5 letter words occurring in three source lists: | |
| - wikipedia's list of most 100k most common words in the english language | |
| - the american english dictionary file on my laptop | |
| - the british english dictionary file on my laptop | |
| the source lists are sanitised by dropping words that contain non-alphabetic or non-ascii | |
| characters and converting capitals to lowercase. | |
| only words that occur in all three resulting lists are kept. |
| #!/usr/bin/env -S uv run --script | |
| # | |
| # /// script | |
| # requires-python = ">=3.12" | |
| # dependencies = [ | |
| # "typer" | |
| # ] | |
| # /// | |
| import os | |
| import sys |
| [ | |
| { | |
| "type": "multiple", | |
| "difficulty": "medium", | |
| "category": "Entertainment: Video Games", | |
| "question": "What is the world's first video game console?", | |
| "correct_answer": "Magnavox Odyssey", | |
| "incorrect_answers": [ | |
| "Coleco Telstar", | |
| "Nintendo Color TV Game", |
| # Increase display brightness command | |
| osascript -e 'tell application "System Events"' -e 'key code 144' -e ' end tell' | |
| # Decrease display brightness command | |
| osascript -e 'tell application "System Events"' -e 'key code 145' -e ' end tell' | |
| # zsh solution to turn it all the way up on one command, just run `b` on the cmd line | |
| alias bright="osascript -e 'tell application \"System Events\"' -e 'key code 144' -e ' end tell'" | |
| alias b="repeat 10 { bright }" |
| # How to fix: "chromedriver" can’t be opened because Apple cannot check it for malicious software. | |
| xattr -d com.apple.quarantine /opt/homebrew/bin/chromedriver |
| import requests | |
| import json | |
| import time | |
| if __name__ == '__main__': | |
| db = {} | |
| token = requests.get('https://opentdb.com/api_token.php?command=request').json()['token'] | |
| while True: | |
| r = requests.get(f'https://opentdb.com/api.php?amount=50&token={token}') | |
| r_json = r.json() |
| { | |
| "1": "2021-06-20", | |
| "2": "2021-06-21", | |
| "3": "2021-06-22", | |
| "4": "2021-06-23", | |
| "5": "2021-06-24", | |
| "6": "2021-06-25", | |
| "7": "2021-06-26", | |
| "8": "2021-06-27", | |
| "9": "2021-06-28", |
firewall-cmd --permanent --add-service=http.firewall-cmd --reload.Here are the steps needed to convert an image (like JPG or TIF) to MBTiles using GDAL:
Download and install GDAL (https://gdal.org/, https://anaconda.org/conda-forge/gdal):
conda install -c conda-forge gdal
Installing GDAL is kind of a pain in the ass, especially on Windows. I'm assuming you'll be able to work out whatever issues you run into here.
Download example jpg and tif map images we can work with:
jpg files.