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
package MySchema; | |
use Moose; | |
extends 'DBIx::Class::Schema'; | |
use Moose; | |
use DBIx::Class::ResultSource::Table; | |
my $result_class = Moose::Meta::Class->create( | |
Foo => ( superclasses => ['DBIx::Class::Core'] ) | |
); |
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
server { | |
listen 80; | |
server_name search.cpan.org sco.metacpan.org sco.metacpan.org cpansearch.perl.org; | |
if ($args ~ "query=([^&]+)" ) { | |
set $query $1; | |
rewrite ^/search$ https://metacpan.org/search?q=$query?; | |
} | |
rewrite ^/perldoc$ https://metacpan.org/module/$args?; | |
rewrite ^/\~([^/]+)/([^/]+)/?$ https://metacpan.org/release/$1/$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
diff --git a/lib/Moose/Meta/TypeConstraint/DuckType.pm b/lib/Moose/Meta/TypeConstraint/DuckType.pm | |
index 8957156..82fc83c 100644 | |
--- a/lib/Moose/Meta/TypeConstraint/DuckType.pm | |
+++ b/lib/Moose/Meta/TypeConstraint/DuckType.pm | |
@@ -24,10 +24,10 @@ my $inliner = sub { | |
return 'Scalar::Util::blessed(' . $val . ') ' | |
. '&& Scalar::Util::blessed(' . $val . ') ne "Regexp" ' | |
- . '&& &List::MoreUtils::all(' | |
- . 'sub { ' . $val . '->can($_) }, ' |
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
eval "require Test::Aggregate::Nested"; | |
$@ ? tests_recursive 't' : tests 't/*.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
/usr/bin/find/-typed(-fstypenfs-o-fstypeNFS-o-fstypeproc-o-fstypeafs-o-fstypesmbfs-o-fstypeautofs-o-fstypeiso9660-o-fstypencpfs-o-fstypecoda-o-fstypedevpts-o-fstypeftpfs-o-fstypedevfs-o-fstypemfs-o-fstypesysfs-o-fstypeshfs-o-fstypecifs-o-fstype9P-o-fstypeunknown-o-regex\(^/mnt$\)\|\(^/cdrom$\)\|\(^/tmp$\)\|\(^/usr/tmp$\)\|\(^/var/tmp$\)\|\(^/var/spool$\)\|\(^/proc$\)\|\(^/media$\)\|\(^/sys$\))-prune-o-print0 |
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
Test-Simple-0.98 0.134009176432354 | |
Test-Harness-3.23 0.114890159531868 | |
Pod-Parser-1.38 0.100078003549883 | |
PathTools-3.33 0.0861958513522049 | |
Scalar-List-Utils-1.23 0.0515342379546982 | |
File-Path-2.08 0.0387061680609517 | |
Moose-2.0202 0.00629845730668331 | |
MIME-Base64-3.13 0.00550044241816146 | |
libwww-perl-6.02 0.00516502766265222 | |
Exporter-5.63 0.00494346206334457 |
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
package Catalyst::Action::MetaCPAN::Deserialize; | |
use Moose; | |
use namespace::autoclean; | |
extends 'Catalyst::Action::Deserialize'; | |
sub execute { | |
my $self = shift; | |
my ( $controller, $c ) = @_; |
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
curl http://localhost:9200/twitter/tweet/QCpcz4q_5B5C9C75p49e3TZJvgw?pretty=1 | |
{ | |
"_index" : "twitter", | |
"_type" : "tweet", | |
"_id" : "QCpcz4q_5B5C9C75p49e3TZJvgw", | |
"_version" : 1, | |
"exists" : true, "_source" : {"post_date":"2011-07-28T11:16:15","user":"mo","id":"QCpcz4q_5B5C9C75p49e3TZJvgw","message":"Elastic baby!"} | |
} |
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
{ | |
"cpan_v3" : { | |
"aliases" : { | |
"cpan" : { | |
} | |
} | |
}, | |
"user" : { | |
"aliases" : { | |
} |
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
curl -XDELETE localhost:9200/test | |
curl -XPUT localhost:9200/test | |
curl -XPUT localhost:9200/test/file/_mapping -d ' | |
{ | |
"file" : { | |
"properties" : { | |
"name" : { | |
"fields" : { | |
"analyzed" : { | |
"store" : "yes", |