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 bash | |
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | |
if [ -z $BUILDROOT ]; then | |
BUILDROOT=$DIR/.. | |
fi | |
. $BUILDROOT/util/common.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
#include <stdio.h> | |
int alt1(const char *s) | |
{ | |
int i; | |
for(i=0; s[i]; s[i]==':'?i++:(int)(s++)); | |
return i; | |
} | |
int alt2(const char *s) | |
{ | |
int i = 0; |
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
input_text: | |
koksradio: | |
initial: "" | |
switch: | |
- platform: templatek | |
switches: | |
koksradio_p1: | |
value_template: "{{ is_state('media_player.kok', 'playing') and is_state('input_text.koksradio', 'P1') }}" | |
turn_on: |
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 numpy as np | |
import cv2 | |
from matplotlib import pyplot as plt | |
import os | |
def order_points(pts): | |
rect = np.zeros((4,2), dtype = "float32") | |
s = pts.sum(axis = 1) |
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
class DimImageElement extends Polymer.Element { | |
async setConfig(config) { | |
this.dim_entity = config.dim_entity; | |
this.img = document.createElement('hui-image-element') | |
this.img.setConfig(config); | |
this.appendChild(this.img) | |
} | |
set hass(hass) { | |
this.img.hass = hass; |
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
homeassistant: | |
customize: | |
package.node_anchors: | |
coffee_switch: &cfe_switch switch.kaffebryggare | |
coffee_remote: &cfe_remote switch.kaffekontroll | |
common: &common | |
package: 'devices/coffeemaker' | |
input_boolean.cfe_on: |
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
#################### | |
default.conf | |
#################### | |
map $http_upgrade $connection_upgrade { | |
default upgrade; | |
'' close; | |
} | |
server { | |
server_name _; |
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
hass:account | |
hass:alert | |
hass:alert-circle | |
hass:altimeter | |
hass:apple-safari | |
hass:apps | |
hass:arrow-bottom-left | |
hass:arrow-down | |
hass:arrow-left | |
hass:arrow-right |
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
// Add this to your lovelace resources as | |
// url: /local/chart-colors.js | |
// type: module | |
customElements.whenDefined('ha-chart-base').then(() => { | |
// Find the HaChartBase class | |
const HaChartBase = customElements.get('ha-chart-base'); | |
// Write a new color list generator |
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
/* | |
To move a panel to below the divider in Home Assistant | |
Add this to your configuration.yaml | |
frontend: | |
extra_module_url: | |
- /local/move-panel.js | |
And put the following into <config-dir>/www/move-panel.js | |
Replace URL_TO_MOVE with the url of your panel |
OlderNewer