Skip to content

Instantly share code, notes, and snippets.

View lukeorland's full-sized avatar

Luke Orland lukeorland

View GitHub Profile
#!/bin/bash
#---------------------------------------#
# Python 2.7.3 Install on CentOS 5 #
# https://gist.github.com/timss/5122008 #
# #
# Installs to /usr/local/{bin,lib} #
# Seperate from system default #
# /usr/bin/python(2.4) #
#---------------------------------------#
# std
import io
import time
# vendor
import serial
ser = serial.Serial('/dev/tty.usbserial-A6008sxN', 115200, timeout=1)
time.sleep(2)
function split_novowel {
echo $1 | cut -d_ -f$2 | sed 's/[aeiou]//g'
}
function abbr {
echo $(split_novowel $1 1 | cut -c 1-3)$(split_novowel $1 2 | cut -c 1-1)
}
abbr Computer_Hardware