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
function git_prompt_info() { | |
ref=$(git symbolic-ref HEAD 2> /dev/null) || return | |
ZSH_THEME_GIT_PROMPT_PREFIX="(" | |
ZSH_THEME_GIT_PROMPT_SUFFIX=")$reset_color " | |
ZSH_THEME_GIT_PROMPT_DIRTY="$fg[red]" | |
ZSH_THEME_GIT_PROMPT_CLEAN="" | |
local oh_my_git_string=""; | |
local has_upstream=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
import math | |
def rgb_to_hsv(r, g, b): | |
r = float(r) | |
g = float(g) | |
b = float(b) | |
high = max(r, g, b) | |
low = min(r, g, b) | |
h, s, v = high, high, high |
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 -n "GitHub username: " | |
read USER | |
echo -n "GitHub password or token: " | |
read -s PASS | |
echo "" | |
echo -n "GitHub Repo (e.g. foo/bar): " |
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
[color] | |
ui = true | |
[fetch] | |
prune = true | |
[push] | |
default = simple | |
[diff] | |
noprefix = true | |
[alias] | |
unstage = reset HEAD -- |
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 UIKit | |
class InnerShadowView: UIView { | |
lazy var innerShadowLayer: CAShapeLayer = { | |
let shadowLayer = CAShapeLayer() | |
shadowLayer.shadowColor = UIColor.black.cgColor | |
shadowLayer.shadowOffset = CGSize(width: 0.0, height: 0.0) | |
shadowLayer.shadowOpacity = 0.1 | |
shadowLayer.shadowRadius = 14 |