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 | |
# Might as well ask for password up-front, right? | |
sudo -v | |
# Keep-alive: update existing sudo time stamp if set, otherwise do nothing. | |
while true; do sudo -n true; sleep 60; kill -0 "$$" || exit; done 2>/dev/null & | |
# Example: do stuff over the next 30+ mins that requires sudo here or there. | |
function wait() { |
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
export function diff(color1: string, color2: string): number { | |
if (!color1 && !color2) { | |
return; | |
} | |
const _color1 = color1.charAt(0) == '#' ? color1.substring(1, 7) : color1; | |
const _color2 = color2.charAt(0) == '#' ? color2.substring(1, 7) : color2; | |
const rColor1 = parseInt(_color1.substring(0, 2), 16); | |
const gColor1 = parseInt(_color1.substring(2, 4), 16); |
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
body { | |
background-color: #002b36; | |
color: #839496; | |
font-size: 14px; | |
white-space: pre !important; | |
font-family: "Source Code Pro", monospace; | |
} | |
.property { | |
font-weight: bold; |