This file contains hidden or 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
package mro; | |
package MRO::Compat; | |
use strict; | |
use warnings; | |
require 5.006_000; | |
our $VERSION = '0.11'; | |
BEGIN { |
This file contains hidden or 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
package Android::FixupUTF8; | |
sub fixup { | |
package Android; | |
no warnings 'redefine'; | |
*do_rpc = sub { | |
my $self = shift; | |
if ( $self->trace ) { | |
show_trace(qq[do_rpc: $self: @_]); | |
} |
This file contains hidden or 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/env perl -w | |
use strict; | |
use IPC::Cmd qw/run/; | |
use IPC::System::Simple qw(systemx); | |
die "You must provide deploy name as argument" unless scalar(@ARGV) > 0; | |
my $deploy_name = $ARGV[0]; | |
my ($ok, $err, undef, $stdout) = run( |
This file contains hidden or 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
/* | |
PC Emulator | |
Copyright (c) 2011 Fabrice Bellard | |
Redistribution or commercial use is prohibited without the author's | |
permission. | |
*/ | |
"use strict"; | |
var aa; | |
var ba = [1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, | |
0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 0, |
This file contains hidden or 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/env perl -w | |
use strict; | |
use Net::Frame::Dump::Online2; | |
use Net::Frame::Simple; | |
my $d = Net::Frame::Dump::Online2->new( dev => 'en1', ); | |
$d->start; | |
while (1) { |
This file contains hidden or 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 Test::More tests => 1; | |
use strict; | |
use warnings; | |
local *STDERR; | |
my $stderr; | |
open STDERR, '>', \$stderr or die $!; | |
warn 'error'; |
This file contains hidden or 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
package WWW::ImagePager; | |
use Any::Moose; | |
use Any::Moose '::Util::TypeConstraints'; | |
use URI; | |
class_type 'URI'; | |
coerce 'URI' => from 'Str' => via { URI->new(shift) }; | |
has 'basepage' => ( is => 'rw', isa => 'URI', coerce => 1 ); |
This file contains hidden or 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 strict; | |
use warnings; | |
use Class::Load qw(load_class); | |
my $module_name = 'MY::MODULE::NAME'; | |
#Moose::Util::load_class()とほぼ同等、ロードに失敗すると例外を投げる | |
load_class($module_name); | |
#can()はCodeRefを返す |
This file contains hidden or 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
#!perl | |
use strict; | |
use warnings; | |
use Growl::GNTP; | |
use AnyEvent; | |
use AnyEvent::HTTP; | |
use JSON; | |
use Data::MessagePack; | |
use Cache::LRU; |
This file contains hidden or 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/env perl -w | |
use strict; | |
my $kw_path = shift @ARGV; | |
if( !defined($kw_path) || !(-e $kw_path ) ){ | |
die <<"__USAGE__"; | |
Usage: | |
# tail -f | ./color.pl keywords.pl | |
keywords are defined by ArrayRef such as: | |
[qw(error fail)]; |
OlderNewer