This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
import serial | |
ser = serial.Serial('/dev/tty.usbmodem621', 9600) | |
ser.write('1') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Part of the txt-to-dayone repository: https://github.com/christophersu/txt-to-dayone | |
IFS=$'\n' | |
files=$(ls | egrep '(.txt)') | |
for i in $files; do | |
#get original creation dates | |
original=$( GetFileInfo -d "$i" ) | |
#change the creation date of the same file in the destination | |
if [ -e "/Users/christophersu/Desktop/test/$i" ]; then | |
SetFile -d "$original" "/Users/christophersu/Desktop/test/$i" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Part of the txt-to-dayone repository: https://github.com/christophersu/txt-to-dayone | |
IFS=$'\n' | |
files=$(ls | egrep '(.txt)') | |
for i in $files; do | |
created=$( GetFileInfo -d "$i" ) | |
dayone -d="$created" new < "$i" | |
done | |
unset IFS |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sqlite3 /Users/christophersu/Library/Application\ Support/Growl/notifications.history "SELECT ZTITLE FROM ZNOTIFICATION" | tail -5 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Last login: Tue Sep 4 12:43:23 on ttys000 | |
csu:~ christophersu$ brew pip Glances | |
==> pip install glances==1.4 --install-option=--prefix=/usr/local/Cellar/glances/1.4 | |
==> Build Environment | |
HOMEBREW_VERSION: 0.9.3 | |
HEAD: 7053db47f7f62e8d88238ffc8b56b5059364add6 | |
CPU: 8-core 64-bit ivybridge | |
OS X: 10.8.1-x86_64 | |
Xcode: 4.4.1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Template Name: Bits | |
*/ | |
get_header(); ?> | |
<?php | |
query_posts('cat=13'); | |
while ( have_posts() ) : the_post(); ?> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<iframe name="mapframe" id="mapframe" src="http://18069595.nhd.weebly.com/files/theme/mapframe.html" height=400 width=58%></iframe> | |
<iframe name="dataframe" id="dataframe" src="http://18069595.nhd.weebly.com/files/theme/dataframe.html" height=400 width=40%></iframe> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<a href="/files/theme/map_guangdong.html" TARGET="dataframe" id="rectangle11"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<iframe src="http://docs.google.com/gview?url=http://18069595.nhd.weebly.com/files/theme/dikotter-transcript.pdf&embedded=true" style="width:900px; height:900px;" frameborder="0"></iframe> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import urllib2 | |
import pinboard | |
pinuser = raw_input('Pinboard username: ') | |
pinpasswd = raw_input('Pinboard password: ') | |
oldtag = raw_input('Tag to rename: ') | |
newtag = raw_input('Rename tag to: ') |
OlderNewer