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 | |
# Used with https://github.com/dwaan/homebridge-file-switch | |
API_URL="https://hourlypricing.comed.com/api?type=currenthouraverage" | |
price=$(curl -s "$API_URL" | jq -r '.[0].price') | |
if [ -n "$DEBUG" ]; then echo $price; fi | |
if (( $(echo "$price < 5" | bc -l) )); then echo "On"; else echo "Off"; fi |
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
defmodule Db.Application do | |
@moduledoc false | |
use Application | |
require Logger | |
def start(_type, _args) do | |
import Supervisor.Spec, warn: false | |
init_cluster(System.get_env("CLUSTER_DNS"), System.get_env("CLUSTER")) |