Skip to content

Instantly share code, notes, and snippets.

flying-sheep /
Created Dec 13, 2018 — forked from lh3/
Download files from Illumina's BaseSpace



  1. Follow steps 1-5 in the first link above to acquire access_token. This will take a while, but you only need to do this once. Never share this token!!
  2. Find the file you want to download. Copy the link, which looks something like: The "id" is the unique file identifier.
  3. Download the file with: wget -O filename '{id}/content?access_token={token}', where {token} is from step 1 and {id} from step 2.
flying-sheep / userChrome.css
Last active Nov 8, 2018 — forked from isacikgoz/userChrome.css
A fix for firefox title bar buttons when you want them to be on the left hand side.
View userChrome.css
@namespace url("");
/* button box to the left */
#TabsToolbar { direction: rtl }
/* tabs ltr again */
#titlebar-content { direction: rtl }
/* buttons inverted */
#tabbrowser-tabs { direction: ltr }
/* keep these ltr */
flying-sheep / PKGBUILD
Last active Sep 5, 2015 — forked from chmue/PKGBUILD
Updated PKGBUILD for r-studio-bin
# Maintainer: Meow < at gmail dot com >
# Get download links and md5 sums for latest version of RStudio desktop
cat <<_EOF_ >/dev/null
## R code #############
page = htmlTreeParse("",useInternalNodes = T)
links = sapply(getNodeSet(page,'//table[@class="downloads"]/thead/tr/th[text()="Installers"]/../../..//a[contains(@href,".deb")]'),xmlGetAttr,'href')
md5sums = sapply(getNodeSet(page,'//table[@class="downloads"]/thead/tr/th[text()="Installers"]/../../..//a[contains(@href,".deb")]/../..//code'),xmlValue)
import csv
from collections import Counter
from operator import itemgetter
from matplotlib import rcParams
import matplotlib.pyplot as plt
rcParams.update({'figure.autolayout': True})
answers_2013 = {"written_python2": (4660, 119),
flying-sheep / dabblet.css
Created Oct 11, 2012 — forked from LeaVerou/dabblet.css
Scrolling shadows by @kizmarh, @LeaVerou, and @trueflyingsheep
View dabblet.css
* Scrolling shadows by @kizmarh, @leaverou, and @trueflyingsheep
* Only works in browsers supporting background-attachment: local, CSS gradients, and masks
* Degrades gracefully
html {
background: repeating-linear-gradient(45deg,
rgba(0,0,255,.1) 100px,
flying-sheep /
Created Aug 8, 2011 — forked from martinth/
A sample exception hook, that prints useful information if an AssertionError occures
#!/usr/bin/env python3
import sys, pprint
import os.path
# save old exception hook
sys._old_excepthook = sys.excepthook
def assert_hook(exc_type, exception, traceback):
if exc_type.__name__ == "AssertionError":
flying-sheep /
Created Aug 3, 2011 — forked from martinth/ login script
# -*- coding: utf-8 -*-
import cookielib
from urllib2 import HTTPCookieProcessor, build_opener
from urllib import urlencode
from BeautifulSoup import BeautifulSoup
# the login data
login_data = {
'login_username': u'USERNAME',
'login_password': u'PASSWORD',