Skip to content

Instantly share code, notes, and snippets.

View rdmurphy's full-sized avatar
🔴
Red pandas are the best.

Ryan Murphy rdmurphy

🔴
Red pandas are the best.
View GitHub Profile
@rdmurphy
rdmurphy / aight.events.js
Created April 23, 2014 23:24
Getting pym.js to play along with IE8. Polyfill `addEventListener` for maximum success. I pulled the event polyfill out of aight (https://github.com/shawnbot/aight), minified it, and chucked it into an IE conditional. Happy <iframe>'ing!
(function() {
if (!window.addEventListener) {
(function (WindowPrototype, DocumentPrototype, ElementPrototype, addEventListener, removeEventListener, dispatchEvent, registry) {
WindowPrototype[addEventListener] = DocumentPrototype[addEventListener] = ElementPrototype[addEventListener] = function (type, listener) {
var target = this;
registry.unshift([target, type, listener, function (event) {
event.currentTarget = target;
event.preventDefault = function () { event.returnValue = false; };
event.stopPropagation = function () { event.cancelBubble = true; };

#GeoRodeo Resources Talk

Data Sources

  • Natural Earth Shapefile downloads for cultural and physical data sets for the entire earth.
  • US Census Shapefiles and KML files for US shapes.
@rdmurphy
rdmurphy / corgis.js
Created July 29, 2014 14:46
c-o-r-g-i-s
(function(c,o,r,g,i,s){c.GoogleAnalyticsObject=g;c[g]||(c[g]=
function(){(c[g].q=c[g].q||[]).push(arguments)});c[g].g=+new Date;
i=o.createElement(r);s=o.getElementsByTagName(r)[0];
i.src='//www.google-analytics.com/analytics.js';
s.parentNode.insertBefore(i,s)}(window,document,'script','ga'));
ga('create','UA-XXXXX-X');ga('send','pageview');
@rdmurphy
rdmurphy / SassMeister-input.scss
Created September 12, 2014 00:04
Generated by SassMeister.com.
// ----
// libsass (v2.0.0)
// ----
$em-base: 16px;
@function em($pxval, $base: $em-base) {
@if unitless($pxval) {
$pxval: $pxval * 1px
}
@rdmurphy
rdmurphy / SassMeister-input.scss
Created September 12, 2014 14:31
Generated by SassMeister.com.
// ----
// libsass (v2.0.0)
// ----
$em-base: 16px;
@function em($pxval, $base: $em-base) {
@if unitless($pxval) {
$pxval: $pxval * 1px
}
@rdmurphy
rdmurphy / SassMeister-input-HTML.html
Created September 12, 2014 14:59
Generated by SassMeister.com.
<div class="container">
<div class="story"></div>
<div class="sidebar"></div>
</div>
@rdmurphy
rdmurphy / SassMeister-input-HTML.html
Created September 12, 2014 16:07
Generated by SassMeister.com.
<div class="container">
<div class="story"></div>
<div class="sidebar"></div>
</div>
@rdmurphy
rdmurphy / SassMeister-input-HTML.html
Created September 12, 2014 16:34
Generated by SassMeister.com.
<div class="container">
<section class="content">
<div class="story">
<header>
<h1>What up</h1>
</header>
<div class="prose">
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit amet ipsum mauris. Maecenas congue ligula ac quam viverra nec consectetur ante hendrerit. Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean ut gravida lorem.
</div>
</div>
@rdmurphy
rdmurphy / problems.md
Last active August 29, 2015 14:07
Yosemite Upgrade Problems

Problems I Had With OS X Yosemite (10.10)

PostgreSQL Wouldn't Start

Tried to run postgres -D /usr/local/var/postgres and got this:

FATAL: could not open directory "pg_tblspc": No such file or directory

An easy fix. The Yosemite install blows away some empty directories that PostgreSQL expects.

@rdmurphy
rdmurphy / SassMeister-input.scss
Created August 5, 2015 22:40
Generated by SassMeister.com.
// ----
// libsass (v3.2.5)
// ----
.story-box {
&__header {
font-weight: 500;
.story-box:hover & {
text-decoration: underline;