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
/* | |
example usage in subclassed form: | |
$this->addTableGroup(array( | |
// row 1 | |
array( | |
$this->createElement('text', 'name1', array('label' => 'test1')), | |
$this->createElement('text', 'name2', array('label' => 'test1')), | |
), | |
// row 2 |
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
class Primes | |
attr_reader :primes | |
def initialize(len = nil) | |
return nil if len.nil? | |
state = Numeric.new | |
@primes = [2, 3] | |
i = 4 |
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
class PerfectNumbers | |
attr_reader :perfects | |
def initialize(len = nil) | |
return nil if len.nil? | |
# sequence A000043 in OEIS | |
# http://www.research.att.com/~njas/sequences/A000043 | |
n = [2, 3, 5, 7, 13, 17, 19, 31, 61, 89, 107, 127, 521, 607, 1279, 2203, | |
2281, 3217, 4253, 4423, 9689, 9941, 11213, 19937, 21701, 23209, 44497, | |
86243, 110503, 132049, 216091, 756839, 859433, 1257787, 1398269, |
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
if has('win32') | |
set backupdir=C:/cygwin_updated/var/vim/backup | |
set directory=C:/cygwin_updated/var/vim/tmp | |
elseif has('win32unix') | |
if exists("*mkdir") | |
if !isdirectory('/var/vim/') | |
mkdir('/var/vim/') | |
endif | |
if !isdirectory('/var/vim/backup/') | |
mkdir('/var/vim/backup/') |
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
(ANDY) | |
Lock eyes from across the room | |
down my drink while the rhythms boom | |
take your hand and skip the names | |
no need here for the silly games | |
make our way through the smoke and crowd | |
the club is the sky and I’m on your cloud | |
move in close as the lasers fly | |
our bodies touch and the angels cry |
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
CMP (COLUMBIA) - Okay. Thank you. Glad to hear the system's looking good. You have a suggested attitude for me? This one here seems all right. | |
CC - Stand by. | |
CMP (COLUMBIA) - Let me know when it's lunch time, will you? | |
CC - Say again. | |
CMP (COLUMBIA) - Oh, disregard. |
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
1Password | |
Adium | |
Adobe Photoshop | |
AppFresh | |
AudialHub | |
Awaken | |
BetterZip | |
Boxee | |
Burn | |
Caffeine |
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
# Rename an email address in all old commits. | |
# WARNING: Will change all your commit SHA1s. | |
# Based off of the script from here: | |
# http://coffee.geek.nz/how-change-author-git.html | |
git filter-branch -f --commit-filter ' | |
if [ "$GIT_COMMITTER_EMAIL" = "[email protected]" ]; | |
then | |
GIT_AUTHOR_EMAIL="[email protected]"; | |
GIT_COMMITTER_EMAIL="[email protected]"; | |
git commit-tree "$@"; |
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
(2:37:08 PM) Rick: i'm going to complain for a moment | |
(2:37:19 PM) Rick: i'm working with another developer | |
(2:37:33 PM) Rick: on a project i started and my client brought him in to help | |
(2:37:49 PM) Rick: i told him that we're using jquery | |
(2:38:08 PM) Rick: the admin screen css and the user css are separate | |
(2:38:18 PM) Rick: and what does he do | |
(2:38:31 PM) Rick: uses prototype/script.. | |
(2:38:38 PM) Rick: and does inline css | |
(2:38:48 PM) Harold: damn | |
(2:38:54 PM) Rick: now there's a conflict and retarded load times |
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
# Move to tmp directory | |
cd $TMPDIR | |
# Download version 1.8.1 of MacPorts | |
curl -OL http://distfiles.macports.org/MacPorts/MacPorts-1.8.1.tar.gz | |
# Untar it | |
tar xzvf MacPorts-1.8.1.tar.gz | |
# Open it |
OlderNewer