Skip to content

Instantly share code, notes, and snippets.

View shillcock's full-sized avatar

Scott Shillcock shillcock

View GitHub Profile
# Disable Access to .svn directories
RewriteRule \.svn - [F]
# Disable Access to .git directories
RewriteRule \.git - [F]
open -h MacErrors.h
@shillcock
shillcock / .bashrc
Created March 12, 2009 17:52 — forked from henrik/.bashrc
# http://henrik.nyh.se/2008/12/git-dirty-prompt
# http://www.simplisticcomplexity.com/2008/03/13/show-your-git-branch-name-in-your-prompt/
# username@Machine ~/dev/dir[master]$ # clean working directory
# username@Machine ~/dev/dir[master*]$ # dirty working directory
function parse_git_dirty {
[[ $(git status 2> /dev/null | tail -n1) != "nothing to commit (working directory clean)" ]] && echo "*"
}
function parse_git_branch {
git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e "s/* \(.*\)/[\1$(parse_git_dirty)]/"
function gr {
## If the current working directory is inside of
## a git repository, this function will change
## it to the git root (ie, the directory that
## contains the .git/ directory), and then print
## the new directory.
git branch > /dev/null 2>&1 || return 1
cd "$(git rev-parse --show-cdup)".
pwd
#!/bin/sh
if [ ! "$1" = "" ] ; then
if [ "$GITREPO" = "" -a -d "$HOME/cm/src" ] ; then
GITREPO="$HOME/cm/src"
fi
if [ "$GITREPO" != "" ] ; then
echo "Git repositories found in $GITREPO"
//
// EGOTitledTableViewCell.h
// EGOClasses
//
// Created by Shaun Harrison on 6/2/09.
// Copyright 2009 enormego. All rights reserved.
//
#import <UIKit/UIKit.h>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>beforeRunningCommand</key>
<string>nop</string>
<key>bundleUUID</key>
<string>5A9D4FC6-6CBE-11D9-A21B-000D93589AF6</string>
<key>command</key>
<string>#!/usr/bin/env ruby
*.pbxproj -crlf -diff -merge
*.pbxproj -crlf -diff -merge
#import <Foundation/Foundation.h>
@interface NSDate(Misc)
+ (NSDate *)dateWithoutTime;
- (NSDate *)dateByAddingDays:(NSInteger)numDays;
- (NSDate *)dateAsDateWithoutTime;
- (int)differenceInDaysTo:(NSDate *)toDate;
- (NSString *)formattedDateString;
- (NSString *)formattedStringUsingFormat:(NSString *)dateFormat;
@end