Discover gists
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
pastie was soo 2007 |
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/perl | |
my $word = 'hello, world!'; | |
say $word; | |
__END__ |
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
javascript:var parts=location.pathname.split('/');location.href='http://twictur.es/' + parts[parts.length-1] + '.gif'; |
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/zsh | |
rm -rf cover_db | |
make realclean | |
perl Makefile.PL | |
HARNESS_PERL_SWITCHES=-MDevel::Cover=+ignore,inc,-coverage,statement,branch,condition,path,subroutine make test | |
cover | |
open cover_db/coverage.html |
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/sh | |
rm -rf nytprof | |
rm nytprof.out | |
perl -d:NYTProf -S ./tools/profile.pl . | |
nytprofhtml | |
open ./nytprof/index.html |
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
kevin@Erebor:~> sudo port install nethack | |
Password: | |
---> Fetching nethack | |
---> Attempting to fetch nethack-343-src.tgz from http://distfiles.macports.org/nethack | |
---> Verifying checksum(s) for nethack | |
---> Extracting nethack | |
---> Applying patches to nethack | |
---> Configuring nethack | |
---> Building nethack with target all | |
Error: Target org.macports.build returned: shell command " cd "/opt/local/var/macports/build/_Users_kevin_Dev_macports_dports_games_nethack/work/nethack-3.4.3" && make all " returned error 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
def default_value | |
p 'generate default_value' | |
'default value' | |
end | |
def some_method(param = nil) | |
param ||= default_value | |
p param | |
end | |
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
def default_value | |
p 'generate default_value' | |
'default value' | |
end | |
def some_method(param = nil) | |
param ||= default_value | |
p param | |
end | |
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
require "openssl" | |
require "net/smtp" | |
require "openssl" | |
require "net/smtp" | |
Net::SMTP.class_eval do | |
private | |
def do_start(helodomain, user, secret, authtype) | |
raise IOError, 'SMTP session already started' if @started |
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
Last login: Sat Jul 26 20:54:27 on ttys007 | |
~ $ mkdir git-bug | |
~ $ cd git-bug/ | |
~/git-bug $ git init | |
Initialized empty Git repository in /Users/rich/git-bug/.git/ | |
~/git-bug $ echo "test line one" > readme | |
~/git-bug $ git add readme | |
~/git-bug $ git commit -a -m "one" | |
Created initial commit 541fc1d: one | |
1 files changed, 1 insertions(+), 0 deletions(-) |