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
""" | |
Font Converter Script | |
This script converts TrueType Font (TTF) and OpenType Font (OTF) files to Web Open Font Format (WOFF). | |
Usage: | |
1. Set the paths to your TTF font folder and WOFF output folder in the variables `font_folder` and `woff_folder`, respectively. | |
2. Run the script. | |
Dependencies: |
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
automation: | |
# Weekday Automation for Boiler Control | |
- alias: "Control Boiler on Weekdays Based on Energy Price" | |
trigger: | |
- platform: time | |
at: "00:01:00" # Check every day just after midnight to plan for the day ahead. | |
condition: | |
- condition: time | |
weekday: | |
- mon |
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
// Definieer de variabelen voor de leveranciersnaam en API token. | |
// Vervang 'JOUW_LEVERANCIER' en 'JOUW_TOKEN' met de daadwerkelijke waarden. | |
let supplierShortName = 'JOUW_LEVERANCIER'; | |
let token = 'JOUW_TOKEN'; | |
// Stel de API URL samen met de leveranciersnaam en token voor gasprijzen. | |
let apiUrl = `https://energieadvieszeeland.nl/wp-json/prices/v1/gas/${supplierShortName}?token=${token}`; | |
// Definieer een asynchrone functie om de gasprijzen op te halen. | |
async function fetchGasPrices() { |
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
// Definieer de variabelen voor de leveranciersnaam en API token. | |
// Vervang 'JOUW_LEVERANCIER' en 'JOUW_TOKEN' met de daadwerkelijke waarden. | |
let supplierShortName = 'JOUW_LEVERANCIER'; | |
let token = 'JOUW_TOKEN'; | |
// Stel de API URL samen met de leveranciersnaam en token. | |
let apiUrl = `https://energieadvieszeeland.nl/wp-json/prices/v1/electricity/${supplierShortName}?token=${token}`; | |
// Definieer een asynchrone functie om de stroomprijzen op te halen. | |
async function fetchElectricityPrices() { |
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
sensor: | |
# Sensor voor het ophalen van gasprijzen | |
- platform: rest | |
name: Gasprijzen # De naam van de sensor zoals die in Home Assistant verschijnt | |
unique_id: eaz_gasprijzen # Unieke identificatie voor de sensor | |
# De URL van de API resource. Vervang {SUPPLIER_SHORT_NAME} met de korte naam van jouw gasleverancier. | |
# Vervang {TOKEN} met jouw persoonlijke API token. | |
# De API token kan worden verkregen door een account aan te maken en API calls te kopen op energieadvieszeeland.nl. | |
resource: https://energieadvieszeeland.nl/wp-json/prices/v1/gas/[SUPPLIER_SHORT_NAME]?token=[TOKEN] # De API URL voor gasprijzen | |
method: GET # HTTP methode voor de API aanroep |
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
sensor: | |
# Sensor voor het ophalen van stroomprijzen | |
- platform: rest | |
name: Stroomprijzen # De naam van de sensor zoals die in Home Assistant verschijnt | |
unique_id: eaz_stroomprijzen # Unieke identificatie voor de sensor | |
# De URL van de API resource. Vervang {SUPPLIER_SHORT_NAME} met de korte naam van jouw gasleverancier. | |
# Vervang {TOKEN} met jouw persoonlijke API token. | |
# De API token kan worden verkregen door een account aan te maken en API calls te kopen op energieadvieszeeland.nl. | |
resource: https://energieadvieszeeland.nl/wp-json/prices/v1/electricity/[SUPPLIER_SHORT_NAME]?token=[TOKEN] # De API URL voor stroomprijzen | |
method: GET # HTTP methode voor de API aanroep |
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
// https://itheo.tech/supercharge-your-postman-experience-with-custom-json-visualization?showSharer=true | |
const isJsonString = (str) => { | |
try { | |
JSON.parse(str); | |
return true; | |
} catch (e) { | |
return 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
#!/bin/bash | |
echo "Start bootstrapping" | |
# Use Bash Strict Mode (Unless You Love Debugging) | |
# http://redsymbol.net/articles/unofficial-bash-strict-mode/ | |
set -euo pipefail | |
IFS=$'\n\t' | |
# inspired by | |
# https://codeberg.org/lotharschulz/gists/src/branch/main/osx_bootstrap.sh |
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
# Dingen om te doen | |
# pip install requests | |
# API KEY ophalen bij https://epbdwebservices.rvo.nl | |
# mij een kleine donatie geven :-) | |
import requests | |
from dbase import MainSQL | |
from time import sleep | |
class EnergieLabel: |
NewerOlder