view release on metacpan or search on metacpan
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $Pod::Escapes::Name2character_number{$1}
? chr($Pod::Escapes::Name2character_number{$1})
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
elsif (eval "require Pod::Text; 1" && $Pod::Text::VERSION < 3) {
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $mapping->{$1}
? $mapping->{$1}
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $Pod::Escapes::Name2character_number{$1}
? chr($Pod::Escapes::Name2character_number{$1})
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
elsif (eval "require Pod::Text; 1" && $Pod::Text::VERSION < 3) {
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $mapping->{$1}
? $mapping->{$1}
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $Pod::Escapes::Name2character_number{$1}
? chr($Pod::Escapes::Name2character_number{$1})
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
elsif (eval "require Pod::Text; 1" && $Pod::Text::VERSION < 3) {
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $mapping->{$1}
? $mapping->{$1}
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/NoPAN.pm view on Meta::CPAN
use File::Temp qw(tempdir);
use HTML::LinkExtor;
use List::Util qw(first);
use LWP::Simple ();
use Scope::Guard;
use URI::Escape qw/uri_unescape/;
# FIXME find and automatically load NoPAN::Installer::*.pm
require App::NoPAN::Installer::Perl;
require App::NoPAN::Installer::Configure;
require App::NoPAN::Installer::Makefile; # should better be the last
lib/App/NoPAN.pm view on Meta::CPAN
$_ !~ m{^(\.{1,2}|)$},
} map {
substr($_, 0, length $url) eq $url ? (substr $_, length $url) : ()
} map {
my ($tag, %attr) = @$_;
$tag eq 'a' && $attr{href} ? (uri_unescape $attr{href}) : ();
} do {
my $lx = HTML::LinkExtor->new(undef, $url);
$lx->parse($body);
$lx->links;
};
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $Pod::Escapes::Name2character_number{$1}
? chr($Pod::Escapes::Name2character_number{$1})
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
elsif (eval "require Pod::Text; 1" && $Pod::Text::VERSION < 3) {
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $mapping->{$1}
? $mapping->{$1}
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Nopaste/Service/ssh.pm view on Meta::CPAN
use parent 'App::Nopaste::Service';
use File::Temp;
use File::Spec;
use POSIX qw(strftime);
use URI::Escape qw(uri_escape);
use namespace::clean 0.19;
sub run {
my ($self, %args) = @_;
lib/App/Nopaste/Service/ssh.pm view on Meta::CPAN
if defined $mode;
system('scp', '-pq', $filename, "$server:$docroot");
my $file = ( File::Spec->splitpath($filename) )[2];
$file = uri_escape($file);
$file =~ s/%2b/+/gi;
return (1, "$topurl/$file");
}
view all matches for this distribution
view release on metacpan or search on metacpan
bin/nostray view on Meta::CPAN
RangeError, Rectangle, ReferenceError, RegExp, ResizeAnimation, Request, RotateAnimation,
SQRT1_2, SQRT2, ScrollBar, ScriptEngine, ScriptEngineBuildVersion,
ScriptEngineMajorVersion, ScriptEngineMinorVersion, Scriptaculous, Scroller,
Slick, Slider, Selector, SharedWorker, String, Style, SyntaxError, Sortable, Sortables,
SortableObserver, Sound, Spinner, System, Swiff, Text, TextArea, Template,
Timer, Tips, Type, TypeError, Toggle, Try, "use strict", unescape, URI, URIError, URL,
VBArray, WSH, WScript, XDomainRequest, Web, Window, XMLDOM, XMLHttpRequest, XMLSerializer,
XPathEvaluator, XPathException, XPathExpression, XPathNamespace, XPathNSResolver, XPathResult,
"\\", a, addEventListener, address, alert, apply, applicationCache, arguments, arity, asi, atob,
b, basic, basicToken, bitwise, block, blur, boolOptions, boss, browser, btoa, c, call, callee,
caller, cases, charAt, charCodeAt, character, clearInterval, clearTimeout,
close, closed, closure, comment, condition, confirm, console, constructor,
content, couch, create, css, curly, d, data, datalist, dd, debug, decodeURI,
decodeURIComponent, defaultStatus, defineClass, deserialize, devel, document,
dojo, dijit, dojox, define, else, emit, encodeURI, encodeURIComponent,
entityify, eqeq, eqeqeq, eqnull, errors, es5, escape, esnext, eval, event, evidence, evil,
ex, exception, exec, exps, expr, exports, FileReader, first, floor, focus,
forin, fragment, frames, from, fromCharCode, fud, funcscope, funct, function, functions,
g, gc, getComputedStyle, getRow, getter, getterToken, GLOBAL, global, globals, globalstrict,
hasOwnProperty, help, history, i, id, identifier, immed, implieds, importPackage, include,
indent, indexOf, init, ins, instanceOf, isAlpha, isApplicationRunning, isArray,
bin/nostray view on Meta::CPAN
passfail : true, // if the scan should stop on first error
plusplus : true, // if increment/decrement should not be allowed
proto : true, // if the `__proto__` property should be allowed
prototypejs : true, // if Prototype and Scriptaculous globals should be
// predefined
regexdash : true, // if unescaped first/last dash (-) inside brackets
// should be tolerated
regexp : true, // if the . should not be allowed in regexp literals
rhino : true, // if the Rhino environment globals should be predefined
undef : true, // if variables should be declared before used
scripturl : true, // if script-targeted URLs should be tolerated
bin/nostray view on Meta::CPAN
dojox : false,
define : false,
"require" : false
},
escapes = {
'\b': '\\b',
'\t': '\\t',
'\n': '\\n',
'\f': '\\f',
'\r': '\\r',
bin/nostray view on Meta::CPAN
URIError : false
},
// widely adopted global names that are not part of ECMAScript standard
nonstandard = {
escape : false,
unescape : false
},
standard_member = {
E : true,
LN2 : true,
bin/nostray view on Meta::CPAN
cx = /[\u0000-\u001f\u007f-\u009f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/;
// token
tx = /^\s*([(){}\[.,:;'"~\?\]#@]|==?=?|\/(\*(jshint|jslint|members?|global)?|=|\/)?|\*[\/=]?|\+(?:=|\++)?|-(?:=|-+)?|%=?|&[&=]?|\|[|=]?|>>?>?=?|<([\/=!]|\!(\[|--)?|<=?)?|\^=?|\!=?=?|[a-zA-Z_$][a-zA-Z0-9_$]*|[0-9]+([xX][0-9a-fA-F]+|\.[0-9]*)?(...
// characters in strings that need escapement
nx = /[\u0000-\u001f&<"\/\\\u007f-\u009f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/;
nxg = /[\u0000-\u001f&<"\/\\\u007f-\u009f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g;
// star slash
lx = /\*\/|\/\*/;
bin/nostray view on Meta::CPAN
if (ix.test(this)) {
return this;
}
if (nx.test(this)) {
return '"' + this.replace(nxg, function (a) {
var c = escapes[a];
if (c) {
return c;
}
return '\\u' + ('0000' + a.charCodeAt().toString(16)).slice(-4);
}) + '"';
bin/nostray view on Meta::CPAN
function esc(n) {
var i = parseInt(s.substr(j + 1, n), 16);
j += n;
if (i >= 32 && i <= 126 &&
i !== 34 && i !== 92 && i !== 39) {
warningAt("Unnecessary escapement.", line, character);
}
character += n;
c = String.fromCharCode(i);
}
j = 0;
bin/nostray view on Meta::CPAN
warningAt("Avoid \\x-.", line, character);
}
esc(2);
break;
case '':
// last character is escape character
// always allow new line if escaped, but show
// warning if option is not set
allowNewLine = true;
if (option.multistr) {
if (jsonmode) {
warningAt("Avoid EOL escapement.", line, character);
}
c = '';
character -= 1;
break;
}
warningAt("Bad escapement of EOL. Use option multistr if needed.",
line, character);
break;
default:
warningAt("Bad escapement.", line, character);
}
}
r += c;
character += 1;
j += 1;
bin/nostray view on Meta::CPAN
if (c < ' ') {
warningAt(
"Unexpected control character in regular expression.", line, from + l);
} else if (c === '<') {
warningAt(
"Unexpected escaped character '{a}' in regular expression.", line, from + l, c);
}
l += 1;
break;
case '(':
depth += 1;
bin/nostray view on Meta::CPAN
case '|':
b = false;
break;
case ')':
if (depth === 0) {
warningAt("Unescaped '{a}'.",
line, from + l, ')');
} else {
depth -= 1;
}
break;
bin/nostray view on Meta::CPAN
l += 1;
if (option.regexp) {
warningAt("Insecure '{a}'.",
line, from + l, c);
} else if (s.charAt(l) === ']') {
errorAt("Unescaped '{a}'.",
line, from + l, '^');
}
}
if (c === ']') {
warningAt("Empty class.", line,
bin/nostray view on Meta::CPAN
c = s.charAt(l);
l += 1;
switch (c) {
case '[':
case '^':
warningAt("Unescaped '{a}'.",
line, from + l, c);
if (isInRange) {
isInRange = false;
} else {
isLiteral = true;
bin/nostray view on Meta::CPAN
} else if (s.charAt(l) === ']') {
isInRange = true;
} else {
if (option.regexdash !== (l === 2 || (l === 3 &&
s.charAt(1) === '^'))) {
warningAt("Unescaped '{a}'.",
line, from + l - 1, '-');
}
isLiteral = true;
}
break;
case ']':
if (isInRange && !option.regexdash) {
warningAt("Unescaped '{a}'.",
line, from + l - 1, '-');
}
break klass;
case '\\':
c = s.charAt(l);
if (c < ' ') {
warningAt(
"Unexpected control character in regular expression.", line, from + l);
} else if (c === '<') {
warningAt(
"Unexpected escaped character '{a}' in regular expression.", line, from + l, c);
}
l += 1;
// \w, \s and \d are never part of a character range
if (/[wsd]/i.test(c)) {
if (isInRange) {
warningAt("Unescaped '{a}'.",
line, from + l, '-');
isInRange = false;
}
isLiteral = false;
} else if (isInRange) {
bin/nostray view on Meta::CPAN
} else {
isLiteral = true;
}
break;
case '/':
warningAt("Unescaped '{a}'.",
line, from + l - 1, '/');
if (isInRange) {
isInRange = false;
} else {
bin/nostray view on Meta::CPAN
case '?':
case '{':
case '}':
case '+':
case '*':
warningAt("Unescaped '{a}'.", line,
from + l, c);
}
if (b) {
switch (s.charAt(l)) {
case '?':
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Office/CMS.pm view on Meta::CPAN
This saves the user the effort of going to the Search tab to find a site or design
=item o When clicking on the site map, the Edit Pages fields are updated, but the Edit Content fields are not
=item o Add an option, perhaps, to escape entities when inputting HTML
=item o Adopt DBIx::Connector
=item o Implement user-initiated backup and restore
view all matches for this distribution
view release on metacpan or search on metacpan
data/currency.html view on Meta::CPAN
</script><img border="0" width="1" height="1" src="http://au.yahoo.com/csc-bottom.gif?106692251333358/currency" style="display: none"><script type="text/javascript">
var _rsCI="yahoo-au";
var _rsCG="0";
var _rsIMG = new Image(1,1);
_rsIMG.src = "//secure-au.imrworldwide.com/cgi-bin/m?rnd=" + (new Date()).getTime() + "&ci="
+ _rsCI + "&cg=" + _rsCG + "&si=" + escape(window.location.href) + "&rp=" +
escape(document.referrer) + "&cc=1";
</script><noscript><div><img src="//secure-au.imrworldwide.com/cgi-bin/m?ci=yahoo-au&cg=0&cc=1" alt=""></div></noscript></div></body></html><!--ci100.finance.sp1.yahoo.com-->
<!-- xi101.finance.sp2.yahoo.com uncompressed/chunked Mon Nov 30 19:20:28 PST 2009 -->
<script language=javascript>
if(window.yzq_p==null)document.write("<scr"+"ipt language=javascript src=http://l.yimg.com/d/lib/bc/bcr_2.0.4.js></scr"+"ipt>");
</script><script language=javascript>
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $Pod::Escapes::Name2character_number{$1}
? chr($Pod::Escapes::Name2character_number{$1})
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
elsif (eval "require Pod::Text; 1" && $Pod::Text::VERSION < 3) {
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $mapping->{$1}
? $mapping->{$1}
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Oozie/Deploy/Template.pm view on Meta::CPAN
}
return @define;
}
sub _xml_escape {
my($self, $input) = @_;
return XML::LibXML::Document
->new('1.0', 'UTF-8')
->createTextNode( $input )
->toString;
lib/App/Oozie/Deploy/Template.pm view on Meta::CPAN
my $flat = Hash::Flatten->new->flatten( $rs );
my $var = [
map {
+{
key => $key_prefix . q{.} . $_,
value => $self->_xml_escape( $flat->{ $_ } ),
}
}
sort { lc $a cmp lc $b }
keys %{ $flat }
];
view all matches for this distribution
view release on metacpan or search on metacpan
script/org2html view on Meta::CPAN
if ($args{browser}) {
require Browser::Open;
require URI::Escape;
my $url = "file:" . URI::Escape::uri_escape($temporgfname);
Browser::Open::open_browser($url);
[200];
} else {
return [200, "OK", File::Slurper::read_text($temporgfname)];
}
script/org2html view on Meta::CPAN
my ($fh, $fpath) = File::Temp::tempfile();
print $fh $res->[2];
close $fh;
my $url = "file:" . URI::Escape::uri_escape($fpath);
Browser::Open::open_browser($url);
return [200];
} else {
return $res;
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/PAIA/Command.pm view on Meta::CPAN
$self->auto_login_for($command);
my $patron = $self->patron // $self->usage_error("missing patron identifier");
my $url = "$core/".uri_escape($patron);
$url .= "/$command" if $command ne 'patron';
# save PAIA core URL in session
if ( ($self->session->get('core') // '') ne $core ) {
$self->session->set( core => $core );
view all matches for this distribution
view release on metacpan or search on metacpan
bin/pft-gen-rss view on Meta::CPAN
use utf8;
use v5.16;
use Carp;
use Digest::MD5;
use HTML::Escape qw/escape_html/;
use PFT::Tree;
use POSIX qw/strftime/;
use Encode;
use Encode::Locale;
bin/pft-gen-rss view on Meta::CPAN
$pubDate = do {
my($y, $m, $d) = @{$node->date};
strftime("%a, %d %b %Y %H:%M:%S %z", 0, 0, 0, $d, $m, $y - 1900)
};
my $content = escape_html $node->html(\&node_to_href);
if ($first) {
$first = 0;
say "<lastBuildDate>$pubDate</lastBuildDate>"
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/PTP/Commands.pm view on Meta::CPAN
sub prepare_re {
my ($re, $modes) = @_;
$re = base_prepare_re($re, $modes);
my $r;
if ($modes->{regex_engine} ne 'perl') {
# Some play to correctly escape whatever special characters might be in the
# regex while preserving its semantics. This relies on the fact that the
# 'Terse' option of Data::Dumper is set in the main program.
# The regex-engine variable has been validated in the Args module.
my $str_re = Dumper($re);
my $engine = 're::engine::'.$modes->{regex_engine};
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $Pod::Escapes::Name2character_number{$1}
? chr($Pod::Escapes::Name2character_number{$1})
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
elsif (eval "require Pod::Text; 1" && $Pod::Text::VERSION < 3) {
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $mapping->{$1}
? $mapping->{$1}
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $Pod::Escapes::Name2character_number{$1}
? chr($Pod::Escapes::Name2character_number{$1})
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
elsif (eval "require Pod::Text; 1" && $Pod::Text::VERSION < 3) {
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $mapping->{$1}
? $mapping->{$1}
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/PackUtils.pm view on Meta::CPAN
},
string => {
schema => 'str*',
pos => 1,
},
escaped_string => {
schema => 'str*',
cmdline_aliases => {e=>{}},
},
},
args_rels => {
req_one => ['string', 'escaped_string'],
},
'cmdline.default_format' => 'perl',
result_naked => 1,
};
sub perl_unpack {
my %args = @_;
[unpack($args{template}, @{ exists $args{string} ? $args{string} : eval($args{escaped_string}) })];
}
$SPEC{perl_pack_template_is_fixed_size} = {
v => 1.1,
summary => 'Check if a Perl pack() template specifies a fixed-size data',
lib/App/PackUtils.pm view on Meta::CPAN
Arguments ('*' denotes required arguments):
=over 4
=item * B<escaped_string> => I<str>
=item * B<string> => I<str>
=item * B<template>* => I<str>
view all matches for this distribution
view release on metacpan or search on metacpan
bin/pa_policy_verify view on Meta::CPAN
A path to a file containing logs you wish to run against the firewall's rulebase. This is the only B<mandatory> field and has no default value.
=item B<-s|--sepchar>
The character which separates the fields in the logfile. If not provided a comma (',') will be used. Remember to escape any characters which may be first interpreted by the shell. For example if the logfile is separated by semicolons, you will need t...
=item B<-f|--fields>
The columns of the logfile where the pertinent fields are, indexed at 0. The pertinent fields are source IP, destination IP, source port, destination port, protocol. The fields are specified as comma separated values.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/ParseCommandLineUtils.pm view on Meta::CPAN
req => 1,
pos => 0,
cmdline_src => 'stdin_or_args',
description => <<'_',
You can also feed command-line from standard input, to avoid having to escape if
specified as shell argument.
_
},
module => {
lib/App/ParseCommandLineUtils.pm view on Meta::CPAN
=over 4
=item * B<cmdline>* => I<str>
You can also feed command-line from standard input, to avoid having to escape if
specified as shell argument.
=item * B<module> => I<str> (default: "Text::ParseWords")
(No description)
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $Pod::Escapes::Name2character_number{$1}
? chr($Pod::Escapes::Name2character_number{$1})
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
elsif (eval "require Pod::Text; 1" && $Pod::Text::VERSION < 3) {
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $mapping->{$1}
? $mapping->{$1}
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $Pod::Escapes::Name2character_number{$1}
? chr($Pod::Escapes::Name2character_number{$1})
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
elsif (eval "require Pod::Text; 1" && $Pod::Text::VERSION < 3) {
inc/Module/Install/Metadata.pm view on Meta::CPAN
defined $2
? chr($2)
: defined $mapping->{$1}
? $mapping->{$1}
: do {
warn "Unknown escape: E<$1>";
"E<$1>";
};
}gex;
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/PerlCriticUtils.pm view on Meta::CPAN
applies_to => "PPI::Token::QuoteLike::Regexp",
supported_parameters => "",
},
{
name => "RegularExpressions::ProhibitEscapedMetacharacters",
abstract => "Use character classes for literal meta-characters instead of escapes.",
supported_parameters => "",
default_severity => 1,
default_themes => "core, pbp, cosmetic",
applies_to => "PPI::Token::QuoteLike::Regexp",
},
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Phoebe.pm view on Meta::CPAN
} elsif (($host, $space) = $url =~ m!^(?:gemini:)?//($hosts)(?::$port)?(?:/($spaces))?/do/all/atom$!) {
serve_all_atom($stream, $host);
} elsif (($host) = $url =~ m!^(?:gemini:)?//($hosts)(?::$port)?/robots.txt(?:[#?].*)?$!) {
serve_raw($stream, $host, undef, "robots");
} elsif (($host, $space, $id, $n, $style) = $url =~ m!^(?:gemini:)?//($hosts)(?::$port)?(?:/($spaces))?/history/([^/]*)(?:/(\d+))?(?:/(colour|fancy))?$!) {
serve_history($stream, $host, space($stream, $host, $space), decode_utf8(uri_unescape($id)), $n||10, $style);
} elsif (($host, $space, $id, $n, $style) = $url =~ m!^(?:gemini:)?//($hosts)(?::$port)?(?:/($spaces))?/diff/([^/]*)(?:/(\d+))?(?:/(colour))?$!) {
serve_diff($stream, $host, space($stream, $host, $space), decode_utf8(uri_unescape($id)), $n, $style);
} elsif (($host, $space, $id, $n) = $url =~ m!^(?:gemini:)?//($hosts)(?::$port)?(?:/($spaces))?/raw/([^/]*)(?:/(\d+))?$!) {
serve_raw($stream, $host, space($stream, $host, $space), decode_utf8(uri_unescape($id)), $n);
} elsif (($host, $space, $id, $n) = $url =~ m!^(?:gemini:)?//($hosts)(?::$port)?(?:/($spaces))?/html/([^/]*)(?:/(\d+))?$!) {
serve_html($stream, $host, space($stream, $host, $space), decode_utf8(uri_unescape($id)), $n);
} elsif (($host, $space, $id, $n) = $url =~ m!^(?:gemini:)?//($hosts)(?::$port)?(?:/($spaces))?/page/([^/]+)(?:/(\d+))?$!) {
serve_page($stream, $host, space($stream, $host, $space), decode_utf8(uri_unescape($id)), $n);
} elsif (($host, $space, $id) = $url =~ m!^(?:gemini:)?//($hosts)(?::$port)?(?:/($spaces))?/file/([^/]+)?$!) {
serve_file($stream, $host, space($stream, $host, $space), decode_utf8(uri_unescape($id)));
} elsif (($host) = $url =~ m!^(?:gemini:)?//($hosts)(?::$port)?(/|$)!) {
$log->info("Unknown path for $url\r");
result($stream, "51", "Path not found for $url");
} elsif ($authority) {
$log->info("Unsupported proxy request for $url");
lib/App/Phoebe.pm view on Meta::CPAN
}
sub decode_query {
my $query = shift;
return $query unless $query;
$query = decode_utf8(uri_unescape($query));
$query =~ s/\+/ /g;
return $query;
}
sub run_extensions {
lib/App/Phoebe.pm view on Meta::CPAN
my $scheme = shift || "gemini";
my $port = port($stream);
if ($space) {
$space = "" if $space eq $host;
$space =~ s/.*\///;
$space = uri_escape_utf8($space);
}
# don't encode the slash
return "$scheme://$host:$port/"
. ($space ? "$space/" : "")
. join("/", map { uri_escape_utf8($_) } split (/\//, $id));
}
sub gemini_link {
my $stream = shift;
my $host = shift;
lib/App/Phoebe.pm view on Meta::CPAN
$ts, $id_log, $revision, $code, $host, $space, 0 },
undef, #$kept
undef, #$filter
$style);
$stream->write("\n");
print_link($stream, $host, $space, "More...", "history/" . uri_escape_utf8($id) . "/" . 10 * $n . ($style ? "/$style" : ""));
}
sub footer {
my $stream = shift;
my $host = shift;
lib/App/Phoebe.pm view on Meta::CPAN
# supplied in the URL matches a known hostname/space combo.
sub space {
my $stream = shift;
my $host = shift;
my $space = shift;
$space = decode_utf8(uri_unescape($space)) if $space;
if (keys %{$server->{host}} > 1) {
return undef unless $space;
return $space if grep { $_ eq "$host/$space" } @{$server->{wiki_space}};
# else it's an error and we jump out to the eval {} in handle_url
result($stream, "40", "$host doesn't know about $space");
lib/App/Phoebe.pm view on Meta::CPAN
my($scheme, $authority, $path, $query, $fragment) =
$request =~ m|(?:([^:/?#]+):)?(?://([^/?#]*))?([^?#]*)(?:\?([^#]*))?(?:#(.*))?|;
if ($path =~ m!^(?:/($spaces_regex))?(?:/raw|/page|/file)?/([^/;=&]+(?:;\w+=[^;=&]+)+)!) {
my $space = $1;
my ($id, @params) = split(/[;=&]/, $2);
my $params = { map {decode_utf8(uri_unescape($_))} @params };
if (valid_params($stream, $host, $space, $id, $params)) {
return {
host => $host,
space => space($stream, $host, $space),
id => decode_utf8(uri_unescape($id)),
params => $params,
}
}
} else {
$log->debug("The path $path is malformed");
view all matches for this distribution
view release on metacpan or search on metacpan
script/_pick view on Meta::CPAN
# my ($word, $is_cur_word, $after_ws) = @_;
#
# #say "D:add_unquoted word=$word is_cur_word=$is_cur_word after_ws=$after_ws";
#
# $word =~ s!^(~)(\w*)(/|\z) | # 1) tilde 2) username 3) optional slash
# \\(.) | # 4) escaped char
# \$(\w+) # 5) variable name
# !
# $1 ? (not($after_ws) || $is_cur_word ? "$1$2$3" : _expand_tilde($2, $3)) :
# $4 ? $4 :
# ($is_cur_word ? "\$$5" : $ENV{$5})
script/_pick view on Meta::CPAN
#sub _add_double_quoted {
# no warnings 'uninitialized';
#
# my ($word, $is_cur_word) = @_;
#
# $word =~ s!\\(.) | # 1) escaped char
# \$(\w+) # 2) variable name
# !
# $1 ? $1 :
# ($is_cur_word ? "\$$2" : $ENV{$2})
# !egx;
script/_pick view on Meta::CPAN
#bash versions 4.2-4.3):
#
#1) quotes and backslashes are stripped (bash's `COMP_WORDS` contains all the
# quotes and backslashes);
#
#2) quoted phrase that contains spaces, or phrase that contains escaped spaces is
# parsed as a single word. For example:
#
# command "First argument" Second\ argument
#
# bash would split it as (represented as Perl):
script/_pick view on Meta::CPAN
# # add things to words, etc
# local point=... # calculate the new point
# COMPREPLY=( `COMP_LINE="foo ${words[@]}" COMP_POINT=$point foo` )
# }
#
# To avoid these word-breaking characters to be split/grouped, we can escape
# them with backslash or quote them, e.g.:
#
# command "http://example.com:80" Foo\:\:Bar
#
# which bash will parse as:
script/_pick view on Meta::CPAN
# v => 1.1,
# summary => 'Format completion for output (for shell)',
# description => <<'_',
#
#Bash accepts completion reply in the form of one entry per line to STDOUT. Some
#characters will need to be escaped. This function helps you do the formatting,
#with some options.
#
#This function accepts completion answer structure as described in the `Complete`
#POD. Aside from `words`, this function also recognizes these keys:
#
script/_pick view on Meta::CPAN
# array.
#
#* esc_mode
#
# Escaping mode for entries. Either `default` (most nonalphanumeric characters
# will be escaped), `shellvar` (like `default`, but dollar sign `$` will also be
# escaped, convenient when completing environment variables for example),
# `filename` (currently equals to `default`), `option` (currently equals to
# `default`), or `none` (no escaping will be done).
#
#* word
#
script/_pick view on Meta::CPAN
# ESCAPE_WORDS:
# for my $entry (@$words) {
# my $word = ref($entry) eq 'HASH' ? $entry->{word} : $entry;
# my $summary = (ref($entry) eq 'HASH' ? $entry->{summary} : undef) // '';
# if ($esc_mode eq 'shellvar') {
# # escape $ also
# $word =~ s!([^A-Za-z0-9,+._/:~-])!\\$1!g;
# } elsif ($esc_mode eq 'none') {
# # no escaping
# } else {
# # default
script/_pick view on Meta::CPAN
# format_completion($completion, $opts) -> str|array
#
#Format completion for output (for shell).
#
#Bash accepts completion reply in the form of one entry per line to STDOUT. Some
#characters will need to be escaped. This function helps you do the formatting,
#with some options.
#
#This function accepts completion answer structure as described in the C<Complete>
#POD. Aside from C<words>, this function also recognizes these keys:
#
script/_pick view on Meta::CPAN
#array.
#
#=item * esc_mode
#
#Escaping mode for entries. Either C<default> (most nonalphanumeric characters
#will be escaped), C<shellvar> (like C<default>, but dollar sign C<$> will also be
#escaped, convenient when completing environment variables for example),
#C<filename> (currently equals to C<default>), C<option> (currently equals to
#C<default>), or C<none> (no escaping will be done).
#
#=item * word
#
script/_pick view on Meta::CPAN
#bash versions 4.2-4.3):
#
#1) quotes and backslashes are stripped (bash's C<COMP_WORDS> contains all the
# quotes and backslashes);
#
#2) quoted phrase that contains spaces, or phrase that contains escaped spaces is
# parsed as a single word. For example:
#
# command "First argument" Second\ argument
#
# bash would split it as (represented as Perl):
script/_pick view on Meta::CPAN
# # add things to words, etc
# local point=... # calculate the new point
# COMPREPLY=( C<COMP_LINE="foo ${words[@]}" COMP_POINT=$point foo> )
#}
#
#To avoid these word-breaking characters to be split/grouped, we can escape
#them with backslash or quote them, e.g.:
#
#command "http://example.com:80" Foo\:\:Bar
#
#which bash will parse as:
script/_pick view on Meta::CPAN
# modify_answer(answer=>$fres, suffix=>"=");
# $fres->{path_sep} = "=";
# # XXX actually not entirely correct, we want normal
# # escaping but without escaping "=", maybe we should
# # allow customizing, e.g. esc_mode=normal, dont_esc="="
# # (list of characters to not escape)
# $fres->{esc_mode} = "none";
# goto RETURN_RES;
# }
# } else {
# $fres = complete_arg_val(
script/_pick view on Meta::CPAN
# )x;
#
## note: order is important here, brace encloses the other
#our $RE_WILDCARD_BASH =
# qr(
# # non-escaped brace expression, with at least one comma
# (?P<bash_brace>
# (?<!\\)(?P<slashes_before_bash_brace>\\\\)*\{
# (?P<bash_brace_content>
# $re_bash_brace_element(?:, $re_bash_brace_element )+
# )
# (?<!\\)(?:\\\\)*\}
# )
# |
# # non-escaped brace expression, to catch * or ? or [...] inside so
# # they don't go to below pattern, because bash doesn't consider them
# # wildcards, e.g. '/{et?,us*}' expands to '/etc /usr', but '/{et?}'
# # doesn't expand at all to /etc.
# (?P<literal_brace_single_element>
# (?<!\\)(?:\\\\)*\{
# $re_bash_brace_element
# (?<!\\)(?:\\\\)*\}
# )
# |
# (?P<bash_class>
# # non-empty, non-escaped character class
# (?<!\\)(?:\\\\)*\[
# (?: \\\\ | \\\[ | \\\] | [^\\\[\]] )+
# (?<!\\)(?:\\\\)*\]
# )
# |
# (?P<bash_joker>
# # non-escaped * and ?
# (?<!\\)(?:\\\\)*(?:\*\*?|\?)
# )
# |
# (?P<sql_joker>
# # non-escaped % and ?
# (?<!\\)(?:\\\\)*[%_]
# )
# |
# (?P<literal>
# [^\\\[\]\{\}*?%_]+
script/_pick view on Meta::CPAN
# }
#
# } elsif (defined($p = $m{literal_brace_single_element})) {
# push @res, quotemeta($p);
# } elsif (defined($p = $m{bash_class})) {
# # XXX no need to escape some characters?
# push @res, $p;
# } elsif (defined($p = $m{sql_joker})) {
# push @res, quotemeta($p);
# } elsif (defined($p = $m{literal})) {
# push @res, quotemeta($p);
script/_pick view on Meta::CPAN
# $bool = contains_wildcard($wildcard_str)
#
#Return true if C<$str> contains wildcard pattern. Wildcard patterns include
#I<joker> such as C<*> (meaning zero or more of any characters) and C<?> (exactly
#one of any character), I<character class> C<[...]>, and I<brace> C<{...,}>
#(brace expansion). A pattern can be escaped using a bacslash so it becomes
#literal, e.g. C<foo\*> does not contain wildcard because it's C<foo> followed by
#a literal asterisk C<*>.
#
#Aside from the abovementioned wildcard patterns, bash does other types of
#expansions/substitutions too, but these are not considered wildcard. These
script/_pick view on Meta::CPAN
#
#Convert bash wildcard to SQL pattern. This includes:
#
#=over
#
#=item * converting unescaped C<*> to C<%>
#
#=item * converting unescaped C<?> to C<_>
#
#=item * escaping unescaped C<%>
#
#=item * escaping unescaped C<_>
#
#=back
#
#Unsupported constructs will cause the function to die.
#
view all matches for this distribution
view release on metacpan or search on metacpan
t/files/moby11.txt view on Meta::CPAN
Meanwhile, he continued the business of undressing, and at
last showed his chest and arms. As I live, these covered
parts of him were checkered with the same squares as his face,
his back, too, was all over the same dark squares;
he seemed to have been in a Thirty Years' War, and just
escaped from it with a sticking-plaster shirt.
Still more, his very legs were marked, as if a parcel of dark
green frogs were running up the trunks of young palms.
It was now quite plain that he must be some abominable savage
or other shipped aboard of a whaleman in the South Seas,
and so landed in this Christian country. I quaked to think of it.
t/files/moby11.txt view on Meta::CPAN
as if ascending the main-top of his vessel.
The perpendicular parts of this side ladder, as is usually the case
with swinging ones, were of cloth-covered rope, only the rounds
were of wood, so that at every step there was a joint. At my first
glimpse of the pulpit, it had not escaped me that however convenient
for a ship, these joints in the present instance seemed unnecessary.
For I was not prepared to see Father Mapple after gaining the height,
slowly turn round, and stooping over the pulpit, deliberately drag
up the ladder step by step, till the whole was deposited within,
leaving him impregnable in his little Quebec.
t/files/moby11.txt view on Meta::CPAN
while some one of you reads me that other and more awful lesson
which Jonah teaches to me, as a pilot of the living God. How being
an anointed pilot-prophet, or speaker of true things and bidden
by the Lord to sound those unwelcome truths in the ears of a
wicked Nineveh, Jonah, appalled at the hostility he should raise,
fled from his mission, and sought to escape his duty and his God by taking
ship at Joppa. But God is everywhere; Tarshish he never reached.
As we have seen, God came upon him in the whale, and swallowed
him down to living gulfs of doom, and with swift slantings tore
him along 'into the midst of the seas,' where the eddying depths
sucked him ten thousand fathoms down, and 'the weeds were wrapped
t/files/moby11.txt view on Meta::CPAN
Though his entire back down to his side fins is of a deep sable,
yet a boundary line, distinct as the mark in a ship's hull,
called the "bright waist," that line streaks him from stem
to stern, with two separate colors, black above and white below.
The white comprises part of his head, and the whole of his mouth,
which makes him look as if he had just escaped from a
felonious visit to a meal-bag. A most mean and mealy aspect!
His oil is much like that of the common porpoise.
Beyond the DUODECIMO, this system does not proceed,
t/files/moby11.txt view on Meta::CPAN
the progeny of a bankrupt baker and a hospital nurse.
And what with the standing spectacle of the black terrific Ahab,
and the periodical tumultuous visitations of these three savages,
Dough-Boy's whole life was one continual lip-quiver. Commonly,
after seeing the harpooneers furnished with all things they demanded,
he would escape from their clutches into his little pantry adjoining,
and fearfully peep out at them through the blinds of its door,
till all was over.
It was a sight to see Queequeg seated over against Tashtego,
opposing his filed teeth to the Indian's; crosswise to them,
t/files/moby11.txt view on Meta::CPAN
individualizing tidings concerning Moby Dick. It was hardly
to be doubted, that several vessels reported to have encountered,
at such or such a time, or on such or such a meridian,
a Sperm Whale of uncommon magnitude and malignity, which whale,
after doing great mischief to his assailants, has completely
escaped them; to some minds it was not an unfair presumption,
I say, that the whale in question must have been no other than
Moby Dick. Yet as of late the Sperm Whale fishery had been
marked by various and not unfrequent instances of great ferocity,
cunning, and malice in the monster attacked; therefore it was,
that those who by accident ignorantly gave battle to Moby Dick;
t/files/moby11.txt view on Meta::CPAN
by an underground passage); these fabulous narrations are almost
fully equalled by the realities of the whalemen.
Forced into familiarity, then, with such prodigies as these;
and knowing that after repeated, intrepid assaults, the White Whale
had escaped alive; it cannot be much matter of surprise that
some whalemen should go still further in their superstitions;
declaring Moby Dick not only ubiquitous, but immortal
(for immortality is but ubiquity in time); that though groves
of spears should be planted in his flanks, he would still swim
away unharmed; or if indeed he should ever be made to spout
t/files/moby11.txt view on Meta::CPAN
But how had the mystic thing been caught? Whisper it not,
and I will tell; with a treacherous hook and line, as the fowl
floated on the sea. At last the Captain made a postman of it;
tying a lettered, leathern tally round its neck, with the ship's
time and place; and then letting it escape. But I doubt not,
that leathern tally, meant for man, was taken off in Heaven,
when the white fowl flew to join the wing-folding, the invoking,
and adoring cherubim!
t/files/moby11.txt view on Meta::CPAN
even as a white-bearded Mufti in the thronged thoroughfares
of Constantinople? Yes. For the peculiar snow-white brow of
Moby Dick, and his snow-white hump, could not but be unmistakable.
And have I not tallied the whale, Ahab would mutter to himself,
as after poring over his charts till long after midnight he would
throw himself back in reveries--tallied him, and shall he escape?
His broad fins are bored, and scalloped out like a lost sheep's ear!
And here, his mad mind would run on in a breathless race;
till a weariness and faintness of pondering came over him!
and in the open air of the deck he would seek to recover
his strength. Ah, God! what trances of torments does that man
t/files/moby11.txt view on Meta::CPAN
hunter of the white whale; this Ahab that had gone to his hammock,
was not the agent that so caused him to burst from it in horror again.
The latter was the eternal, living principle or soul in him;
and in sleep, being for the time dissociated from the characterizing mind,
which at other times employed it for its outer vehicle or agent,
it spontaneously sought escape from the scorching contiguity of the
frantic thing, of which, for the time, it was no longer an integral.
But as the mind does not exist unless leagued with the soul, therefore it
must have been that, in Ahab's case, yielding up all his thoughts
and fancies to his one supreme purpose; that purpose, by its own sheer
inveteracy of will, forced itself against gods and devils into a kind
t/files/moby11.txt view on Meta::CPAN
by separate citations of items, practically or reliably known
to me as a whaleman; and from these citations, I take it--
the conclusion aimed at will naturally follow of itself.
First: I have personally known three instances where a whale,
after receiving a harpoon, has effected a complete escape;
and, after an interval (in one instance of three years), has been
again struck by the same hand, and slain; when the two irons,
both marked by the same private cypher, have been taken from the body.
In the instance where three years intervened between the flinging
of the two harpoons; and I think it may have been something more
t/files/moby11.txt view on Meta::CPAN
while we who were below all sprang instantly upon the deck,
concluding that we had struck upon some rock; instead of this we
saw the monster sailing off with the utmost gravity and solemnity.
Captain D'Wolf applied immediately to the pumps to examine
whether or not the vessel had received any damage from the shock,
but we found that very happily it had escaped entirely uninjured."
Now, the Captain D'Wolf here alluded to as commanding the ship
in question, is a New Englander, who, after a long life of unusual
adventures as a sea-captain, this day resides in the village
of Dorchester near Boston. I have the honor of being a nephew
t/files/moby11.txt view on Meta::CPAN
but tilted everywhere to right and left; the whales seemed
separating their wakes. The boats were pulled more apart;
Starbuck giving chase to three whales running dead to leeward.
Our sail was now set, and, with the still rising wind, we rushed along;
the boat going with such madness through the water, that the lee
oars could scarcely be worked rapidly enough to escape being torn
from the row-locks.
Soon we were running through a suffusing wide veil of mist;
neither ship nor boat to be seen.
t/files/moby11.txt view on Meta::CPAN
the sail collapsed and exploded; a gush of scalding vapor shot up
near by; something rolled and tumbled like an earthquake beneath us.
The whole crew were half suffocated as they were tossed
helter-skelter into the white curdling cream of the squall.
Squall, whale, and harpoon had all blended together; and the whale,
merely grazed by the iron, escaped.
Though completely swamped, the boat was nearly unharmed.
Swimming round it we picked up the floating oars, and lashing
them across the gunwale, tumbled back to our places.
There we sat up to our knees in the sea, the water covering
t/files/moby11.txt view on Meta::CPAN
On the second day, numbers of Right Whales were seen, who, secure from
the attack of a Sperm-Whaler like the Pequod, with open jaws sluggishly
swam through the brit, which, adhering to the fringing fibres of that
wondrous Venetian blind in their mouths, was in that manner separated
from the water that escaped at the lips.
As morning mowers, who side by side slowly and seethingly advance
their scythes through the long wet grass of marshy meads;
even so these monsters swam, making a strange, grassy, cutting sound;
and leaving behind them endless swaths of blue upon the yellow sea.*
t/files/moby11.txt view on Meta::CPAN
when every flying beam, and shaft, and wheel, is grazing you.
It is worse; for you cannot sit motionless in the heart of
these perils, because the boat is rocking like a cradle, and you
are pitched one way and the other, without the slightest warning;
and only by a certain self-adjusting buoyancy and simultaneousness
of volition and action, can you escape being made a Mazeppa of,
and run away with where the all-seeing sun himself could never
pierce you out.
Again: as the profound calm which only apparently precedes and
prophesies of the storm, is perhaps more awful than the storm itself;
t/files/moby11.txt view on Meta::CPAN
situation of mine was the precise situation of every mortal
that breathes; only, in most cases, he, one way or other,
has this Siamese connexion with a plurality of other mortals.
If your banker breaks, you snap; if your apothecary by mistake
sends you poison in your pills, you die. True, you may
say that, by exceeding caution, you may possibly escape
these and the multitudinous other evil chances of life.
But handle Queequeg's monkey-rope heedfully as I would,
sometimes he jerked it so, that I came very near sliding overboard.
Nor could I possibly forget that, do what I would, I only had
the management of one end of it.*
t/files/moby11.txt view on Meta::CPAN
fin beat his side in an agony of fright. Now to this hand,
now to that, he yawed in his faltering flight, and still at
every billow that he broke, he spasmodically sank in the sea,
or sideways rolled towards the sky his one beating fin.
So have I seen a bird with clipped wing, making affrighted broken
circles in the air, vainly striving to escape the piratical hawks.
But the bird has a voice, and with plaintive cries will make
known her fear; but the fear of this vast dumb brute of the sea,
was chained up and enchanted in him; he had no voice,
save that choking respiration through his spiracle, and this
made the sight of him unspeakably pitiable; while still,
t/files/moby11.txt view on Meta::CPAN
there was enough to appal the stoutest man who so pitied.
Seeing now that but a very few moments more would give the Pequod's
boats the advantage, and rather than be thus foiled of his game,
Derick chose to hazard what to him must have seemed a most unusually
long dart, ere the last chance would for ever escape.
But no sooner did his harpooneer stand up for the stroke, than all
three tigers--Queequeg, Tashtego, Daggoo--instinctively sprang
to their feet, and standing in a diagonal row, simultaneously pointed
their barbs; and darted over the head of the German harpooneer,
t/files/moby11.txt view on Meta::CPAN
must have taken refuge in the floating body of a dead whale--
even as the French soldiers in the Russian campaign turned
their dead horses into tents, and crawled into them.
Besides, it has been divined by other continental commentators,
that when Jonah was thrown overboard from the Joppa ship,
he straightway effected his escape to another vessel near by,
some vessel with a whale for a figure-head; and, I would add,
possibly called "The Whale," as some craft are nowadays
christened the "Shark," the "Gull," the "Eagle." Nor have
there been wanting learned exegetists who have opined
that the whale mentioned in the book of Jonah merely meant
t/files/moby11.txt view on Meta::CPAN
spans of horses in a ring; and so closely shoulder to shoulder,
that a Titanic circus-rider might easily have over-arched
the middle ones, and so have gone round on their backs.
Owing to the density of the crowd of reposing whales,
more immediately surrounding the embayed axis of the herd,
no possible chance of escape was at present afforded us.
We must watch for a breach in the living wall that hemmed us in;
the wall that had only admitted us in order to shut us up.
Keeping at the centre of the lake, we were occasionally
visited by small tame cows and calves; the women and children
of this routed host.
t/files/moby11.txt view on Meta::CPAN
The boat was now all but jammed between two vast black bulks,
leaving a narrow Dardanelles between their long lengths.
But by desperate endeavor we at last shot into a temporary opening;
then giving way rapidly, and at the same time earnestly watching
for another outlet. After many similar hair-breadth escapes, we at
last swiftly glided into what had just been one of the outer circles,
but now crossed by random whales, all violently making for one centre.
This lucky salvation was cheaply purchased by the loss of Queequeg's
hat, who, while standing in the bows to prick the fugitive whales,
had his hat taken clean from his head by the air-eddy made by the sudden
t/files/moby11.txt view on Meta::CPAN
prior possession, should the boats of any other ship draw near.
The result of this lowering was somewhat illustrative of that
sagacious saying in the Fishery,--the more whales the less fish.
Of all the drugged whales only one was captured.
The rest contrived to escape for the time, but only to be taken,
as will hereafter be seen, by some other craft than the Pequod.
t/files/moby11.txt view on Meta::CPAN
but one, necessitates some account of the laws and regulations
of the whale fishery, of which the waif may be deemed the grand
symbol and badge.
It frequently happens that when several ships are cruising in company,
a whale may be struck by one vessel, then escape, and be finally killed
and captured by another vessel; and herein are indirectly comprised
many minor contingencies, all partaking of this one grand feature.
For example,--after a weary and perilous chase and capture of a whale,
the body may get loose from the ship by reason of a violent storm;
and drifting far away to leeward, be retaken by a second whaler, who,
t/files/moby11.txt view on Meta::CPAN
It came to pass, that in the ambergris affair Stubb's after-oarsman
chanced so to sprain his hand, as for a time to become quite maimed;
and, temporarily, Pip was put into his place.
The first time Stubb lowered with him, Pip evinced much nervousness;
but happily, for that time, escaped close contact with the whale;
and therefore came off not altogether discreditably; though Stubb
observing him, took care, afterwards, to exhort him to cherish his
courageousness to the utmost, for he might often find it needful.
Now upon the second lowering, the boat paddled upon the whale;
t/files/moby11.txt view on Meta::CPAN
he bumps us the first thing; then Gemini, or the Twins--
that is, Virtue and Vice; we try to reach Virtue,
when lo! comes Cancer the Crab, and drags us back; and here,
going from Virtue, Leo, a roaring Lion, lies in the path--
he gives a few fierce bites and surly dabs with his paw;
we escape, and hail Virgo, the Virgin! that's our first love;
we marry and think to be happy for aye, when pop comes Libra,
or the Scales--happiness weighed and found wanting; and while we
are very sad about that, Lord! how we suddenly jump, as Scorpio,
or the Scorpion, stings us in the rear; we are curing the wound,
when whang comes the arrows all round; Sagittarius, or the Archer,
t/files/moby11.txt view on Meta::CPAN
with a blinding sun, all crown-jewels; as I was groping, I say,
after the second iron, to toss it overboard--down comes the tail
like a Lima tower, cutting my boat in two, leaving each half
in splinters; and, flukes first, the white hump backed through
the wreck, as though it was all chips. We all struck out.
To escape his terrible flailings, I seized hold of my harpoon-pole
sticking in him, and for a moment clung to that like a sucking fish.
But a combing sea dashed me off, and at the same instant,
the fish, taking one good dart forwards, went down like a flash;
and the barb of that cursed second iron towing along near me
caught me here" (clapping his hand just below his shoulder);
t/files/moby11.txt view on Meta::CPAN
but one single word with thee! Nay--the shuttle flies--
the figures float from forth the loom; the fresher-rushing
carpet for ever slides away. The weaver-god, he weaves;
and by that weaving is he deafened, that he hears no mortal voice;
and by that humming, we, too, who look on the loom are deafened;
and only when we escape it shall we hear the thousand voices that
speak through it. For even so it is in all material factories.
The spoken words that are inaudible among the flying spindles;
those same words are plainly heard without the walls, bursting from
the opened casements. Thereby have villainies been detected.
Ah, mortal! then, be heedful; for so, in all this din of the great
t/files/moby11.txt view on Meta::CPAN
which, not forty years ago, overspread by tens of thousands the prairies
of Illinois and Missouri, and shook their iron manes and scowled with
their thunder-clotted brows upon the sites of populous river-capitals,
where now the polite broker sells you land at a dollar an inch;
in such a comparison an irresistible argument would seem furnished,
to show that the hunted whale cannot now escape speedy extinction.
But you must look at this matter in every light. Though so short
a period ago--not a good lifetime--the census of the buffalo in Illinois
exceeded the census of men now in London, and though at the present
day not one horn or hoof of them remains in all that region;
t/files/moby11.txt view on Meta::CPAN
at every flash of the lightning glancing aloft, to see
what additional disaster might have befallen the intricate
hamper there; while Stubb and Flask were directing the men
in the higher hoisting and firmer lashing of the boats.
But all their pains seemed naught. Though lifted to the very top
of the cranes, the windward quarter boat (Ahab's) did not escape.
A great rolling sea, dashing high up against the reeling ship's
high teetering side, stove in the boat's bottom at the stern,
and left it again, all dripping through like a sieve.
"Bad work, bad work! Mr. Starbuck," said Stubb, regarding the wreck,
t/files/moby11.txt view on Meta::CPAN
"Thou liest!" smiting him with his clenched fist.
"Heading East at this hour in the morning, and the sun astern?"
Upon this every soul was confounded; for the phenomenon just
then observed by Ahab had unaccountably escaped every one else;
but its very blinding palpableness must have been the cause.
Thrusting his head half-way into the binnacle, Ahab caught
one glimpse of the compasses; his uplifted arm slowly fell;
for a moment he almost seemed to stagger. Standing behind
t/files/moby11.txt view on Meta::CPAN
the body; so, then--Oh! God"--advancing towards the hammock
with uplifted hands--"may the resurrection and the life-"
"Brace forward! Up helm!" cried Ahab like lightning to his men.
But the suddenly started Pequod was not quick enough to escape
the sound of the splash that the corpse soon made as it struck the sea;
not so quick, indeed, but that some of the flying bubbles might have
sprinkled her hull with their ghostly baptism.
As Ahab now glided from the dejected Delight, the strange life-buoy
t/files/moby11.txt view on Meta::CPAN
and so planetarily swift the ever-contracting circles
he made, that he seemed horizontally swooping upon them.
And though the other boats, unharmed, still hovered hard by;
still they dared not pull into the eddy to strike, lest that should be
the signal for the instant destruction of the jeopardized castaways,
Ahab and all; nor in that case could they themselves hope to escape.
With straining eyes, then, they remained on the outer edge of
the direful zone, whose centre had now become the old man's head.
Meantime, from the beginning all this had been descried from the ship's
mast heads; and squaring her yards, she had borne down upon the scene;
t/files/moby11.txt view on Meta::CPAN
Ha, ha! we go the gait that leaves no dust behind!"
"There she blows--she blows!--she blows!--right ahead!"
was now the mast-head cry.
"Aye, aye!" cried Stubb, "I knew it--ye can't escape--blow on and split
your spout, O whale! the mad fiend himself is after ye! blow your trump--
blister your lungs!--Ahab will dam off your blood, as a miller shuts
his watergate upon the stream!"
And Stubb did but speak out for well nigh all that crew.
t/files/moby11.txt view on Meta::CPAN
bowl of punch.
While the two crews were yet circling in the waters, reaching out
after the revolving line-tubs, oars, and other floating furniture,
while aslope little Flask bobbed up and down like an empty vial,
twitching his legs upwards to escape the dreaded jaws of sharks;
and Stubb was lustily singing out for some one to ladle him up;
and while the old man's line--now parting--admitted of his
pulling into the creamy pool to rescue whom he could;--
in that wild simultaneousness of a thousand concreted perils,--
Ahab's yet unstricken boat seemed drawn up towards Heaven by
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Pimpd/Transfer.pm view on Meta::CPAN
@tracks = map { $config{music_directory} . '/' . $_->file } @tracks;
if(remote_host()) {
for(@tracks) {
#$_ = escape($_);
_scp($_, $destination);
}
}
else {
for(@tracks) {
#$_ = escape($_);
if(copy($_, $destination)) {
printf("%40.40s => %s\n", basename($_), $destination);
}
else {
warn("cp_album: $!");
lib/App/Pimpd/Transfer.pm view on Meta::CPAN
return;
}
sub _scp {
my($source, $dest) = @_;
$source = escape($source);
system('scp', '-r',
"-P $config{ssh_port}",
qq($config{ssh_host}:$source), $dest
) == 0;# or confess("scp: $!");
view all matches for this distribution
view release on metacpan or search on metacpan
t/000-report-versions.t view on Meta::CPAN
# Error storage
$YAML::Tiny::errstr = '';
}
# Printable characters for escapes
my %UNESCAPES = (
z => "\x00", a => "\x07", t => "\x09",
n => "\x0a", v => "\x0b", f => "\x0c",
r => "\x0d", e => "\x1b", '\\' => '\\',
);
view all matches for this distribution
view release on metacpan or search on metacpan
script/platform-info view on Meta::CPAN
# allow_blessed convert_blessed relaxed allow_unknown
# allow_tags
# );
# my @pp_bit_properties = qw(
# allow_singlequote allow_bignum loose
# allow_barekey escape_slash as_nonblessed
# );
#
# if ( OLD_PERL ) {
# my $helper = $] >= 5.006 ? 'JSON::PP::Compat5006' : 'JSON::PP::Compat5005';
# eval qq| require $helper |;
script/platform-info view on Meta::CPAN
# my $canonical;
# my $allow_blessed;
# my $convert_blessed;
#
# my $indent_length;
# my $escape_slash;
# my $bignum;
# my $as_nonblessed;
# my $allow_tags;
#
# my $depth;
script/platform-info view on Meta::CPAN
# $depth = 0;
#
# my $props = $self->{PROPS};
#
# ($ascii, $latin1, $utf8, $indent, $canonical, $space_before, $space_after, $allow_blessed,
# $convert_blessed, $escape_slash, $bignum, $as_nonblessed, $allow_tags)
# = @{$props}[P_ASCII .. P_SPACE_AFTER, P_ALLOW_BLESSED, P_CONVERT_BLESSED,
# P_ESCAPE_SLASH, P_ALLOW_BIGNUM, P_AS_NONBLESSED, P_ALLOW_TAGS];
#
# ($max_depth, $indent_length) = @{$self}{qw/max_depth indent_length/};
#
script/platform-info view on Meta::CPAN
#
# sub string_to_json {
# my ($self, $arg) = @_;
#
# $arg =~ s/([\x22\x5c\n\r\t\f\b])/$esc{$1}/g;
# $arg =~ s/\//\\\//g if ($escape_slash);
# $arg =~ s/([\x00-\x08\x0b\x0e-\x1f])/'\\u00' . unpack('H2', $1)/eg;
#
# if ($ascii) {
# $arg = JSON_PP_encode_ascii($arg);
# }
script/platform-info view on Meta::CPAN
# }
#}
#
#{
#
# my %escapes = (
# b => "\x8",
# t => "\x9",
# n => "\xA",
# f => "\xC",
# r => "\xD",
script/platform-info view on Meta::CPAN
#
# return $s;
# }
# elsif($ch eq '\\'){
# next_chr();
# if(exists $escapes{$ch}){
# $s .= $escapes{$ch};
# }
# elsif($ch eq 'u'){
# my $u = '';
#
# for(1..4){
script/platform-info view on Meta::CPAN
#
# }
# else{
# unless ($loose) {
# $at -= 2;
# decode_error('illegal backslash escape sequence in string');
# }
# $s .= $ch;
# }
# }
# else{
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Pod.pm view on Meta::CPAN
#
=head2 trim
Trim a line to fit the terminal width.
Handles also escape codes within the line.
=cut
sub trim {
my ( $line ) = @_;
state $esc = qr{ \033\[ [\d;]+ m }x;
state $data = qr{ (?: (?!$esc) . )++ }x;
state $data_or_escape = qr{ (?<data>$data) | (?<esc>$esc) }x;
state $term_width = Pod::Query::get_term_width();
state $replacement = " ...";
state $width_raw = $term_width - length( $replacement );
state $base_width = $width_raw >= 0 ? $width_raw : 0; # To avoid negatives.
# Figure out the total len of the line (uncolored).
my $total_chars = 0;
my @detailed_line_parts;
while ( $line =~ /$data_or_escape/g ) {
my $part = {%+};
$total_chars += $part->{len} = length( $part->{data} // "" );
push @detailed_line_parts, $part;
}
lib/App/Pod.pm view on Meta::CPAN
my @parts;
my $size_exceeded;
my $so_far_len = 0;
for my $part ( @detailed_line_parts ) {
# Handle escape codes.
if ( not $part->{len} ) {
push @parts, $part->{esc}; # Add escapes back.
last if $size_exceeded; # Done.
next;
}
# Handle trailing escapes.
last if $size_exceeded;
# Trim line if it would be too long.
if ( $so_far_len + $part->{len} > $base_width ) {
$size_exceeded = 1; # Still need to possibly add a trailing escape.
# Limit line to allowed width.
$part->{data} = substr(
$part->{data},
0,
view all matches for this distribution