Skip to content

Instantly share code, notes, and snippets.

View xguse's full-sized avatar

Gus Dunn xguse

View GitHub Profile
@xguse
xguse / public email key
Created August 10, 2013 02:13
my public email encryption key. Take it. Use it. Make one for yourself. Send it to me. Screw the NSA.
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: OpenPGP.js v.1.20130712
Comment: http://openpgpjs.org
xsBNBFIFl8QBCACn/Arb96LzlcetuPj2yXMqMVUmJueUJ8/alzQCpAZx5JnU
7R+ajxOgmiV4JxMpOT/9nHJCwDudDrqgoTms1AjJVWoOZTBCpRGq9MpFr0PF
5eue2ioAdoNZyehFYhh7oN6PvBHxMC9y2Xesiza9d4nartZhES2coBJh7FEX
E8gOIrQ7c0cWfpapBUmcfYLQtvo1DFK7dLa1zFqFpN/losfVocHu6cEOdEkB
T0mtedkjhOWAdjq0w3GxYkeXPcbdfGFNM9kW3k+TbF4M4vWGQVgcxgm2g3vc
tpnUAfNqdwXm6x2jZblr/opvONLlvq4dM0fwi/rKWuGZLpWhuytvQZ1XABEB
@xguse
xguse / email signature
Last active December 20, 2015 21:38
my gmail signature and public key
http://about.me/wadunn
W. Augustine Dunn, III
Ph.D. Candidate
Laboratory of Dr. Anthony James
Department of Molecular Biology and Biochemistry
Institute for Genomics and Bioinformatics
University of California, Irvine
(949) 824-3210 - Lab
(949) 824-8551 - Fax
dunnw@uci.edu
@xguse
xguse / xpermutations.py
Created July 23, 2013 00:50
Generators for calculating a) the permutations of a sequence and b) the combinations and selections of a number of elements from a sequence. Uses Python 2.2 generators. Similar solutions found also in comp.lang.python Keywords: generator, combination, permutation, selection See also: http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/105962
#!/usr/bin/env python
__version__ = "1.0"
"""xpermutations.py
Generators for calculating a) the permutations of a sequence and
b) the combinations and selections of a number of elements from a
sequence. Uses Python 2.2 generators.
Similar solutions found also in comp.lang.python
@xguse
xguse / sort_example.py
Created June 30, 2013 21:38
example script to sort a file for seqanswers user marqudiego
import sys
in_file = sys.argv[1]
in_data = open(in_file, 'rU')
data_list = []
@xguse
xguse / bashrc
Last active December 16, 2015 09:39
Generic yet functional bash prompt template
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
[ -z "$PS1" ] && return
# Setup PATH env vars and variants
@xguse
xguse / .condarc
Created October 6, 2015 19:03
condarc starter
---
channels:
- http://xguse.github.io/conda-package-repo/pkgs/channel/
- r
- pandas
- defaults
- https://conda.anaconda.org/davidbgonzalez
show_channel_urls: True
@xguse
xguse / fembot
Created November 29, 2011 21:48
Female robot voice that speaks text. Can be used as a tack-on after a long running command to tell you that it has finished. Uses espeak and sox/play. Allows setting volume and repeat value.
#!/bin/sh
slp=0s
rep=0
vol=1
text='Type something Here for me to say.'
while getopts 'w:r:v:t:' OPTION
do
case $OPTION in
@xguse
xguse / brownNoise.sh
Created March 11, 2011 23:11
brown noise generator using sox for linux. keywords: white pink red brown noise
#!/bin/sh
len='7:00:00'
vol=1
if [ "$1" != '' ]; then
len=$1
fi
if [ "$2" != '' ]; then
@xguse
xguse / PKGBUILD
Last active August 29, 2015 14:24 — forked from flying-sheep/PKGBUILD
# Maintainer: Meow < a.li.devtty at gmail dot com >
# Get download links and md5 sums for latest version of RStudio desktop
cat <<_EOF_ >/dev/null
## R code #############
require(XML)
page = htmlTreeParse("http://www.rstudio.com/products/rstudio/download/",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)
print(cbind(links,md5sums))

Having trouble installing the latest stable version of tmux?

I know, official package for your OS/distro is outdated and you just want the newest version of tmux.

Well, this script should save you some time with that.

Prerequisities

  • gcc