Skip to content

Instantly share code, notes, and snippets.

View akdetrick's full-sized avatar
🛠️

Adam Detrick akdetrick

🛠️
  • Meetup
  • Brooklyn, NY
View GitHub Profile
@nylki
nylki / char-rnn recipes.md
Last active March 16, 2024 15:13
char-rnn cooking recipes

do androids dream of cooking?

The following recipes are sampled from a trained neural net. You can find the repo to train your own neural net here: https://github.com/karpathy/char-rnn Thanks to Andrej Karpathy for the great code! It's really easy to setup.

The recipes I used for training the char-rnn are from a recipe collection called ffts.com And here is the actual zipped data (uncompressed ~35 MB) I used for training. The ZIP is also archived @ archive.org in case the original links becomes invalid in the future.

@akdetrick
akdetrick / modular_scale_type.scss
Created October 13, 2014 04:42
Responsive modular scale typesetting
@import "../bower_components/sassquatch/sass/utils.scss"; // just the mixins
@import "../bower_components/modular-scale/stylesheets/modular-scale.scss";
/* {{{ ~~~~~~~~~~~~~~~~~~~ MODULAR SCALE */
$scale-small: $major-third;
$scale-big: $fourth;
$ms-base: 1rem;
$ms-ratio: $scale-small;
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ }}} */
@staltz
staltz / introrx.md
Last active July 8, 2024 15:46
The introduction to Reactive Programming you've been missing
@akdetrick
akdetrick / rvm-to-rbenv.md
Last active June 12, 2024 03:19
Guide to switching to rbenv bliss from RVM hell

RVM to rbenv

Why? @sstephenson explains it best here.


1) remove RVM from your system

This should get rid of the rvm dir and any installed rubies:

$ rvm implode
@akdetrick
akdetrick / colors.yaml
Created October 22, 2013 03:38
cross-platform colors in yaml configuration file
# colors are listed as [r,g,b,a]
primitive:
comment: "PRIMITIVE COLORS - used in multiple color aliases, try not to use these directly"
colors:
red: &red [226,55,60,1]
blue: &blue [57,135,203,1]
primaryGray: &primaryGray [0,0,0,.8]
secondaryGray: &secondaryGray [0,0,0,.55]
tertiaryGray: &tertiaryGray [0,0,0,.25]
lineGray: &lineGray [0,0,0,.1]
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>x-origin</title>
</head>
<body>
<canvas id="canvas"></canvas>
<br>
<textarea id="data" style="width: 260px; height:260px"></textarea>
@jbenet
jbenet / simple-git-branching-model.md
Last active June 17, 2024 14:53
a simple git branching model

a simple git branching model (written in 2013)

This is a very simple git workflow. It (and variants) is in use by many people. I settled on it after using it very effectively at Athena. GitHub does something similar; Zach Holman mentioned it in this talk.

Update: Woah, thanks for all the attention. Didn't expect this simple rant to get popular.

@PaulKinlan
PaulKinlan / criticalcss.html
Last active March 15, 2023 02:13
Detect Critical CSS
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>JS Bin</title>
</head>
<body>
<h2>Original CSS</h2>
<style style="display: block; white-space: pre; font-family: monospace">
h2 { margin:0; }
---
title: test
layout: main
---
<!-- declare order of pages by id -->
{% assign sassquatch_section_names = "index,test" | split: "," %}
<!-- loop through the ids -->
<h3>Pages by title in the order we declared them in sassquatch_section_names</h3>
@zachleat
zachleat / gist:5407068
Last active December 16, 2015 08:39
Differences between Pure Internet Explorers and IE Compatibility Modes

Or, yet more evidence that you should use feature detection instead of browser/user agent sniffing.

IE9

Not supported in IE9 but works in IE10-as-IE9

  • Unprefixed CSS transform. Should require -ms-transform but doesn’t require it.

IE8