Skip to content

Instantly share code, notes, and snippets.

@haleyrc
haleyrc / SketchSystems.spec
Last active March 1, 2019 02:12
Logged Out*
Logged Out*
login -> Logged In
Logged In
menu -> Menu
Inventory*
plus -> Fab Button
{
"env": {
"browser": true,
"es6": true,
"node": true,
"jest": true
},
"parser": "babel-eslint",
"extends": "eslint:recommended",
"parserOptions": {
node_modules/**
node_modules/**
{
"arrowParens": "always",
"tabWidth": 2,
"singleQuote": false,
"semi": false,
"useTabs": false,
"printWidth": 80
}
{
"linters": {
"*.js": [
"eslint"
],
"**/*.+(js|jsx|json|yml|yaml|css|less|scss|ts|tsx|md|mdx|graphql|vue)": [
"prettier --write",
"git add"
]
}
@haleyrc
haleyrc / settings.json
Last active January 18, 2019 03:46
VS Code Settings
{
"editor.fontWeight": "400",
"workbench.iconTheme": "vs-seti",
"editor.rulers": [80, 100],
"editor.minimap.enabled": false,
"editor.fontLigatures": true,
"explorer.openEditors.visible": 0,
"terminal.integrated.shell.windows": "C:\\Program Files\\Git\\bin\\bash.exe",
"terminal.integrated.shellArgs.windows": [
"--init-file",
@haleyrc
haleyrc / snippets.json
Last active March 15, 2019 18:03
VS Code Snippets
{
"class SomeWidget extends StatefulWidget": {
"scope": "dart",
"prefix": "sfw",
"body": [
"class ${1:name} extends StatefulWidget {",
"\t const ${1}({ Key key }) : super(key: key);",
"",
"\t@override",
"\t_${1}State createState() => _${1}State();",
@haleyrc
haleyrc / example.yml
Created December 19, 2018 16:41
An example blue/green deployment
apiVersion: v1
kind: Service
metadata:
name: backend-service
spec:
selector:
app: backend
color: blue
type: NodePort
ports:
@haleyrc
haleyrc / rabinmiller.go
Created June 24, 2015 20:17
Rabin-Miller Primality Test
func BitsN(n int64) []int64 {
var bits []int64
bits = make([]int64, 0)
for {
if n == 0 {
return bits
}
bits = append(bits, n % 2)
n >>= 1