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
(in-package :cl-user) | |
(defun md5-sum (file &rest args) | |
(capi:display-message "~S" | |
(ironclad:byte-array-to-hex-string (ironclad:digest-file :md5 file)))) | |
(capi:contain (make-instance 'capi:text-input-pane | |
:callback 'md5-sum | |
:buttons | |
(list :cancel t |
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
# shell prompt | |
PS1='\[\e[1m\][\u@\h \w]\[\e[0m\]$ ' | |
# terminal title | |
PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"' | |
# environment variables | |
export HISTSIZE=1000 | |
export PATH=/opt/local/bin:/opt/local/sbin:$PATH | |
export EDITOR=ee |
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
;; get some random elements from a list | |
;; i know it's dumb | |
(defparameter *data* '(192 123 34 23 67 3 45 342)) | |
(defun get-and-remove () | |
(let ((one (nth (random (length *data*)) *data*))) | |
(setf *data* (remove one *data*)) | |
one)) |
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
[horus@campus ~/.cpanm/plugins]$ cpanm Test::Class | |
Test::Class: rated 4.6 based on 8 review(s) | |
Fetching http://cpan.sarang.net//authors/id/A/AD/ADAMK/Test-Class-0.33.tar.gz ... OK | |
Configuring Test-Class-0.33 ... OK | |
... ... | |
[horus@campus ~/.cpanm/plugins]$ cpanm Net::Twitter::Lite | |
Net::Twitter::Lite: rated 5.0 based on 2 review(s) | |
Fetching http://cpan.sarang.net//authors/id/M/MM/MMIMS/Net-Twitter-Lite-0.08006.tar.gz ... OK | |
Configuring Net-Twitter-Lite-0.08006 ... OK |
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
[horus@campus ~]$ PERL_CPANM_DEV=1 cpanm WWW::Mechanize | |
WWW::Mechanize: rated 4.7 based on 16 review(s) | |
Fetching http://cpan.sarang.net//authors/id/P/PE/PETDANCE/WWW-Mechanize-1.60.tar.gz ... OK | |
Configuring WWW-Mechanize-1.60 ... OK | |
Building and testing WWW-Mechanize-1.60 for WWW::Mechanize ... FAIL | |
! Installing WWW::Mechanize failed. See /Users/horus/.cpanm/build.log for details. | |
Running autolook requested by module WWW::Mechanize | |
Looking into /Users/horus/.cpanm/work/1267368220.2321/WWW-Mechanize-1.60... | |
bash-3.2$ pwd | |
/Users/horus/.cpanm/work/1267368220.2321/WWW-Mechanize-1.60 |
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
''=~ ( | |
( '(') .(( ( | |
'?' ))). (( '{' | |
)).('['^'+').('['^ ')') .('`'|')').('`'|'.' | |
). ('[' ^+ | |
(( '/') )) .+ | |
(( '"') ).('`'^'(').('`'| | |
(( '%') )) | |
.( ( '`') |+ (( | |
(( ',' )))) ).('`'|',').('`'|'/'). |
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
diff -ruN orig/rakudo-star-2010.07/parrot-2.6.0/config/auto/icu.pm rakudo-star-2010.07/parrot-2.6.0/config/auto/icu.pm | |
--- orig/rakudo-star-2010.07/parrot-2.6.0/config/auto/icu.pm 2010-06-18 00:51:18.000000000 +0800 | |
+++ rakudo-star-2010.07/parrot-2.6.0/config/auto/icu.pm 2010-07-29 23:40:21.000000000 +0800 | |
@@ -312,7 +312,7 @@ | |
else { | |
# on MacOS X there's sometimes an errornous \c at the end of the | |
# output line. Remove it. | |
- $icushared =~ s/\s\\c$//; | |
+ $icushared =~ s/\s\\c\s/ /g; | |
} |
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 | |
use Modern::Perl; | |
my %words; | |
while (<DATA>) { | |
chomp; | |
my ($hex, $word, $odd) = split; | |
$words{$hex} = [$word, $odd]; |
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 -w | |
# Dependence: Net::DNS | |
# To get correct answers, use TCP. | |
# I am not going to say more. | |
use strict; | |
use Net::DNS; | |
use Net::DNS::Nameserver; |
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 | |
use strict; | |
use warnings; | |
my $page = WebBrowsing->new; | |
my $yutou = Tianyutou->new(@ARGV[0,1]); | |
while ("In Spring Brother We Trust") { | |
if (defined(my $p_info = $page->info)) { |
OlderNewer