Skip to content

Instantly share code, notes, and snippets.

Dem keyboards don't go click click on their own you know

Alec Clews alecthegeek

Dem keyboards don't go click click on their own you know
View GitHub Profile
alecthegeek / SqlplusStartup
Created Jun 4, 2009
Oracle SQLplus. Add this to $SQLPATH/login.sql
View SqlplusStartup
set sqlprompt "&_USER@&_CONNECT_IDENTIFIER> "
define _editor='c:\Progra~1\Vim\vim72\gvim.exe --nofork'
rem -----
rem Also add to filetype.vim
rem ------------------
View Find the git dir for local repo
if b=`git rev-parse --git-dir 2>/dev/null`; then
echo git here at $b
echo no git
alecthegeek / Kill UNIX processes by string
Created Sep 14, 2009
Kill a proccess identifed vy a string
View Kill UNIX processes by string
#! /bin/sh
# See
string="$1" ; export string
scriptname=`basename $0` ; export scriptname
kps=`ps -ef|nawk '$0 ~ ENVIRON["string"] && $0 !~ ENVIRON["scriptname"] {print $2}'`
echo $string has PID \"$kps\"
View Dimensions: Find bad item lib files
Query that might help locate item library files that have been inserted incorrectly
select filename
from pcms_item_data, pcms_workset_items, pcms_workset_info
where file_version > 1
and lib_file_length = 0
and pcms_workset_info.product_id = '$GENERIC'
and pcms_workset_info.workset_name = '$GLOBAL'
and pcms_workset_info.workset_uid = pcms_workset_items.workset_uid
View Text mode 'gitk --all'. Thanks to schacon
git log --pretty=oneline --abbrev-commit --all --graph
alecthegeek / build IDs with git
Created Nov 4, 2009
Generate build ID in Git
View build IDs with git
use the output of git log -1 '--pretty=format:%h %ai' (example: "d19611c 2009-10-01 01:58:19 -0400")
(from Nikolas Coukouma)
alecthegeek / gist:226499
Created Nov 4, 2009 — forked from claudinec/gist:226453
Locate dropbox conflicts
View gist:226499
find ~/Dropbox -name '*conflicted copy*'
alecthegeek / yahoo pipe to filter github RSS feeds
Created Nov 10, 2009
yahoo pipe to filter github RSS feeds
View yahoo pipe to filter github RSS feeds
alecthegeek / Pomodoro_Template.tsktmpl
Created Dec 29, 2009
Pomodoro template for taskcoach
View Pomodoro_Template.tsktmpl
<?xml version="1.0" ?>
<?taskcoach release="0.77.0" tskversion="27"?>
<task id="168052332:1262058476.11" startdatetmpl="Today() + TimeDelta(0)" status="1" subject="Pomodoro Task">
Estimated : xP
Actual (X):
Internal Interuptions ('):
External Interuption (-):
alecthegeek / git-croncheck
Created Mar 4, 2010 — forked from elecnix/git-croncheck
be notified when your repo is dirty
View git-croncheck
# Put this in your crontab to be notified when your repo is dirty or commits needs to be pushed to a remote.
# Example crontab:
# MAILTO=user@yourdomain
# 0 * * * Mon-Fri /path/to/check-repo-status /path/to/repo
cd $1
git status | grep 'working directory clean' 2>/dev/null 1>/dev/null || {
git status
git diff