Skip to content

Instantly share code, notes, and snippets.

View elgreg's full-sized avatar
💭
Inside

Greg Lavallee elgreg

💭
Inside
View GitHub Profile
@elgreg
elgreg / addEventListener-polyfill.js
Created June 4, 2012 16:45 — forked from eirikbacker/addEventListener-polyfill.js
addEventListener polyfill for IE6+
//addEventListener polyfill 1.0 / Eirik Backer / MIT Licence
(function(win, doc){
if(win.addEventListener)return; //No need to polyfill
function docHijack(p){var old = doc[p];doc[p] = function(v){return addListen(old(v))}}
function addEvent(on, fn, self){
return (self = this).attachEvent('on' + on, function(e){
var e = e || win.event;
e.preventDefault = e.preventDefault || function(){e.returnValue = false}
e.stopPropagation = e.stopPropagation || function(){e.cancelBubble = true}
<div class="flag">
<div class="stars">
<div class="star star-first">
<div class="star-arrow star-arrow-one"></div>
<div class="star-arrow star-arrow-two"></div>
<div class="star-arrow star-arrow-three"></div>
</div>
<div class="star">
<div class="star-arrow star-arrow-one"></div>
<div class="star-arrow star-arrow-two"></div>
$ git branch -r --merged origin/master |
grep origin |
grep -v '>' |
grep -v master |
xargs -L1 |
awk '{split($0,a,"/"); print a[2]}' |
xargs git push origin --delete