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
button_card_templates: | |
homekit: | |
aspect_ratio: 1/1 | |
hold_action: | |
action: more-info | |
show_label: true | |
show_state: true | |
color_type: card | |
color: '#232321' | |
size: 28px |
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 HvvDeparturesCard extends HTMLElement { | |
set hass (hass) { | |
const entityId = this.config.entity | |
const state = hass.states[entityId] | |
const name = this.config.name || state.attributes['friendly_name'] | |
if (!this.content) { | |
const card = document.createElement('ha-card') | |
card.header = name | |
this.content = document.createElement('div') |
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
# The Path class | |
class Path: | |
def __init__(self, knot0, knot1, metric, sort=False): | |
self.knot0 = knot0 | |
self.knot1 = knot1 | |
self.metric = metric | |
def other(self, knot): | |
if self.knot0 == knot: | |
return self.knot1 |
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
import bpy, os | |
result = "" | |
obdata = bpy.context.object.data | |
result += 'Vertices: \n' | |
for v in obdata.vertices: | |
result += ('{}, {}, {}, '.format(v.co.x, v.co.z, v.co.y)) + '\n' |
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
theme = "onedark" | |
[editor] | |
line-number = "relative" | |
color-modes = true | |
[editor.file-picker] | |
hidden = false | |
[editor.indent-guides] |
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
// Name: Get Departures | |
import "@johnlindquist/kit" | |
type Station = { id: string, name: string, type: string }; | |
async function departuresDom(station: Station): Promise<string> { | |
const now = new Date(); | |
const body = { | |
"version": 47, |
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
// Name: Find JIRA ticket | |
// Shortcode: j | |
import "@johnlindquist/kit" | |
const JIRA_URL = await env("JIRA_URL"); | |
const JIRA_USERNAME = await env("JIRA_USERNAME"); | |
const JIRA_PASSWORD = await env("JIRA_PASSWORD"); | |
const JIRA_PROJECT_KEY = await env("JIRA_PROJECT_KEY"); |
OlderNewer