This file contains 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 | |
# 2014-04-22, v1.0, pull, push, initial clone of projects | |
# 2014-04-26, v2.0, speed improvement, use hashtable to determine push/pull | |
# automatically pull new projects based on remote hashtable | |
# setting up new repo (note: we should automate this at some point): | |
# create local git repo in projects (~/projects/xxx_name) | |
# login remote, create git repo $remote/"$target".git | |
# local git remote add "$remote"/ |
This file contains 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 | |
for f in *.go | |
do | |
echo "processing $f" | |
go fix "$f" | |
gofmt -w "$f" | |
done |
This file contains 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 | |
go test -coverprofile=coverage.out; go tool cover -func=coverage.out; go tool cover -html=coverage.out; rm coverage.out |
This file contains 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
// go control flow in a linked list based on element type using type assertion | |
package main | |
import ( | |
"fmt" | |
"reflect" | |
"container/list" | |
) | |
type Foo struct { |
This file contains 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
.. | |
<variant> | |
<configItem> | |
<name>dvorak-sk-custom</name> | |
<description>English (SK Custom Dvorak)</description> | |
</configItem> | |
</variant> | |
.. |
This file contains 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 python3 | |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
# In this prototype/example a QTreeView is created. Then it's populated with | |
# three containers and all containers are populated with three rows, each | |
# containing three columns. | |
# Then the last container is expanded and the last row is selected. | |
# The container items are spanned through the all columns. | |
# Note: this requires > python-3.2 | |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
import sys, os, pprint, time |
This file contains 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 python3 | |
import sys | |
from PySide.QtCore import * | |
from PySide.QtGui import * | |
""" | |
Create a table model from a two dimensional array, | |
first element being the header. |
This file contains 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 | |
# play files in random order | |
find . -type f \( -name "*.mkv" -o -name "*.avi" -o -name "*.flv" \) -print0 | xargs -0 mplayer -shuffle -fs |
This file contains 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
" 2010-08-11..2010-08-13 | |
" Saves current buffer and executes it. | |
" If the buffer doesn't have a filename, it is stored in a temp location. | |
function! SF_run() | |
if bufname("%") == "" | |
let PATH = "/tmp/".localtime().".vim" | |
else | |
let PATH = bufname("%") | |
endif | |
exec ":write ".PATH |
This file contains 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
# Python test runner. Add more tests with the test_sequence list. | |
# This assumes that the project to be tested is two folders above (../..) | |
# POSIX only | |
import os | |
import sys | |
import shutil | |
NAME = "TEMPLATE" |
NewerOlder