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
set nocompatible | |
syntax on | |
filetype plugin indent on | |
" encoding | |
set encoding=utf-8 | |
set termencoding=utf-8 | |
set fileencoding=utf-8 | |
set fileencodings=utf-8,euc-jp,sjis,iso-2022-jp,cp932 |
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
escape | |
defkanji utf-8 | |
defencoding utf-8 | |
encoding utf-8 utf-8 | |
startup_message off | |
autodetach on | |
vbell off | |
defscrollback 5000 |
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
{ | |
use Catalyst::Utils (); | |
no warnings 'redefine'; | |
sub Catalyst::Utils::class2prefix { | |
my $class = shift || ''; | |
my $case = shift || 0; | |
my $prefix; | |
if ( $class =~ /^.+?::([MVC]|Model|View|Controller)::(.+)$/ ) { | |
$prefix = $case ? $2 : do { | |
$prefix = $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
{ | |
use CSS::Tiny::Style (); | |
no warnings 'redefine'; | |
sub CSS::Tiny::Style::_sel_arr { | |
local $_ = shift; | |
my @d; | |
while ($_) { | |
my ($tag, $op); | |
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
(function(){ | |
var url=location.href; | |
var r=url.match(/http:\/\/[\w]+\.youtube\.com\/watch\?v=([\w-]+)/i); | |
var flv=RegExp.$1; | |
var d=document; | |
var f=d.createElement('form'); | |
f.action='http://mixi.jp/add_diary.pl?id=374297'; | |
f.method='post'; | |
f.target=flv; | |
f.innerHTML='<input type=\'hidden\' name=\'diary_body\' value=\'<externalvideo src=%22YT:'+flv+':D%22>\'/>'; |
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 is CPAN.pm's systemwide configuration file. This file provides | |
# defaults for users, and the values can be changed in a per-user | |
# configuration file. The user-config file is being looked for as | |
# ~/.cpan/CPAN/MyConfig.pm. | |
$CPAN::Config = { | |
'auto_commit' => q[0], | |
'build_cache' => q[10], | |
'build_dir' => q[/root/.cpan/build], | |
'cache_metadata' => q[1], |
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
autoload -U compinit | |
compinit | |
autoload -U colors | |
colors | |
bindkey -e | |
## history | |
HISTFILE=~/.zsh_history |
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
cd /var/tmp | |
sync | |
sysctl -w vm.drop_caches=3 | |
sysctl -w vm.drop_caches=0 | |
swapoff -a | |
swapon -a | |
perl -le '$text .= "a" x 10 for 1 .. 400_000_000; open $fh, ">", shift or die $!; print $fh $text; close $fh' mem_hdd_check.txt | |
ll |
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
sub AUTOLOAD { | |
my $self = shift; | |
(my $method) = (our $AUTOLOAD =~ /([^:]+)$/); | |
return if $method eq "DESTROY"; | |
$self->obj->$method(@_); | |
} |
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; | |
use utf8; | |
use Encode qw(encode); | |
my $data = "~-あいうえお"; | |
$data =~ tr/\x{ff5e}\x{ff0d}/\x{301c}\x{2212}/; |
OlderNewer