Skip to content

Instantly share code, notes, and snippets.

Avatar

Jeremy jeremyis

View GitHub Profile
View REMINDER
USE SAFARI BC CHROME IS WHACK!
View Python 2.7 cheat sheet
new_list = [expression(i) for i in old_list if filter(i)]
d = {key: value for (key, value) in dict.items()}
@jeremyis
jeremyis / gist:6f6385c97f8176d1846f
Created Oct 25, 2014
CBS Sports Picks Scraper Json
View gist:6f6385c97f8176d1846f
{"selectors":[{"parentSelectors":["_root"],"type":"SelectorElement","multiple":true,"id":"li.pickContainer","selector":"li.pickContainer","delay":""},{"parentSelectors":["li.pickContainer"],"type":"SelectorText","multiple":false,"id":"Away Pick Percentage","selector":"a.awayTeamSelection span:nth-child(1)","delay":""},{"parentSelectors":["li.pickContainer"],"type":"SelectorText","multiple":false,"id":"Away","selector":"a.awayTeamSelection span:nth-child(2)","delay":""},{"parentSelectors":["li.pickContainer"],"type":"SelectorText","multiple":false,"id":"Home Pick Percentage","selector":"a.homeTeamSelection span:nth-child(2)","delay":""},{"parentSelectors":["li.pickContainer"],"type":"SelectorText","multiple":false,"id":"Home Team","selector":"a.homeTeamSelection span:nth-child(1)","delay":""},{"parentSelectors":["li.pickContainer"],"type":"SelectorText","multiple":false,"id":"Spread","selector":".spreadInfo","regex":"","delay":""},{"parentSelectors":["li.pickContainer"],"type":"SelectorText","multiple":false,"
@jeremyis
jeremyis / gist:4009709
Created Nov 4, 2012
inject jquery into a page
View gist:4009709
var element1 = document.createElement("script");element1.src = "http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js";element1.type="text/javascript";document.getElementsByTagName("head")[0].appendChild(element1);
// full disclosure: i found this through google and didn't write it
@jeremyis
jeremyis / gitmergehelper.sh
Created Jul 6, 2012
Checking git st for unmerged files
View gitmergehelper.sh
for i in `git st -s | awk '{print $2}'` ; do grep -HI '>>>' $i --color=always ; done
You can’t perform that action at this time.