- Enter plan mode for ANY non-trivial task (3+ steps or architectural decisions).
- If something goes sideways, STOP and re-plan immediately—don't keep pushing.
- Use plan mode for verification steps, not just building.
- Write detailed specs upfront to reduce ambiguity.
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
| blueprint: | |
| name: Appliance has finished | |
| description: Do something when an appliance (like a washing machine or dishwasher) | |
| has finished as detected by a power sensor. | |
| domain: automation | |
| input: | |
| power_sensor: | |
| name: Power Sensor | |
| description: Power sensor entity (e.g. from a smart plug device). | |
| selector: |
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
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <title>A simple clock</title> | |
| </head> | |
| <body translate="no" > |
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/bash | |
| c_FAN=26 # gpio pin the fan is connected to | |
| c_MIN_TEMPERATURE=45 # temperature in degrees c when fan should turn on | |
| c_TEMPERATURE_OFFSET=2 # temperarute offset in degrees c when fan should turn off | |
| c_HARDDRIVE="sda" # name of your harddrive | |
| temperature_offset=$(( $c_MIN_TEMPERATURE - $c_TEMPERATURE_OFFSET )) | |
| fan_state=0 |
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 os | |
| import errno | |
| from subprocess import call | |
| from gitlab import Gitlab | |
| def mkdir_p(path): | |
| try: | |
| os.makedirs(path) | |
| except OSError as exc: # Python >2.5 | |
| if exc.errno == errno.EEXIST and os.path.isdir(path): |
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/bash | |
| RED='\033[0;31m' | |
| GREEN='\033[1;32m' | |
| BLUE='\033[1;34m' | |
| NC='\033[0m' # No Color | |
| echo -e "${BLUE}System update${NC}" | |
| sudo apt-get update #2>&1 >/dev/null | |
| echo -e "${BLUE}System upgrade${NC}" | |
| sudo apt-get upgrade -y #2>&1 >/dev/null |
Past August 2024, Authy stopped supported the desktop version of their apps:
See Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August for details.
And indeed, after a while, Authy changed something in their backend which now prevents the old desktop app from logging in. If you are already logged in, then you are in luck, and you can follow the instructions below to export your tokens.
If you are not logged in anymore, but can find a backup of the necessary files, then restore those files, and re-install Authy 2.2.3 following the instructions below, and it should work as expected.
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 | |
| # should install jq first, for mac:brew install jq | |
| # Documentation | |
| # https://docs.gitlab.com/ce/api/projects.html#list-projects | |
| NAMESPACE="your group name in gitlab" | |
| BASE_PATH="https://gitlab.example.com/" | |
| PROJECT_SEARCH_PARAM="" |
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 | |
| # Documentation | |
| # https://docs.gitlab.com/ce/api/projects.html#list-projects | |
| if [[ `whoami` == "root" ]]; then | |
| echo "DO NOT run this program as root! Quitting." | |
| exit 1 | |
| fi |
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 | |
| # Documentation | |
| # https://docs.gitlab.com/ce/api/projects.html#list-projects | |
| # NAMESPACE="YOUR_NAMESPACE" | |
| BASE_PATH="YOUR_GIT_SERVER_PATH" | |
| # PROJECT_SEARCH_PARAM="YOUR_SEARCH_PARAM" | |
| if [ -z "$GITLAB_PRIVATE_TOKEN" ]; then |
NewerOlder