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/Test/Base/Filter.pm view on Meta::CPAN
local $Data::Dumper::Indent = 1;
local $Data::Dumper::Terse = 1;
Data::Dumper::Dumper(@_);
}
sub escape {
$self->assert_scalar(@_);
my $text = shift;
$text =~ s/(\\.)/eval "qq{$1}"/ge;
return $text;
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Spec/Completion/Bash.pm view on Meta::CPAN
my $name = $o->name;
my $aliases = $o->aliases;
my $summary = $o->summary;
$summary =~ s/\s+/ /g if defined $summary;
my @names = ($name, @$aliases);
($summary, @names) = $self->escape_singlequote( $summary, @names );
@names = map {
length $_ > 1 ? "--$_" : "-$_"
} @names;
my @items = map {
lib/App/Spec/Completion/Bash.pm view on Meta::CPAN
}
}
return ("@flags", "@opt");
}
sub escape_singlequote {
my ($self, @strings) = @_;
my @result;
for my $string (@strings) {
no warnings 'uninitialized';
$string =~ s/[']/'"\\\\'"'/g;
lib/App/Spec/Completion/Bash.pm view on Meta::CPAN
=item completion_parameters
=item dynamic_completion
=item escape_singlequote
(@names) = $self->escape_singlequote( @names );
=item flags_options
my ($flags_string, $options_string) = $completer->flags_options($global_options);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Spoor/AccessEntryParser.pm view on Meta::CPAN
=cut
sub parse {
use DateTime::Format::Strptime;
use URI::Escape qw( uri_unescape );
my $log_entry = shift;
my $level;
my $event;
my $status;
lib/App/Spoor/AccessEntryParser.pm view on Meta::CPAN
\[(?<timestamp>[^\]]+)\]\s
"(?<http_request>[^"]+)"\s
(?<response_code>\d{3})\s
/x) {
my $log_time = $date_parser->parse_datetime($+{timestamp})->epoch();
my $credential = uri_unescape($+{username});
my $ip = $+{ip};
my $http_request = $+{http_request};
my $response_code = $+{response_code};
if ($credential =~ /@/) {
lib/App/Spoor/AccessEntryParser.pm view on Meta::CPAN
} elsif (
$credential =~ /@/ &&
$http_request =~ /\AGET.+dodelfwd.html\?.*emaildest=(?<forward_recipient>[^\s?]+)/
) {
$event = 'forward_removed';
$forward_recipient = uri_unescape($+{forward_recipient});
} else {
$event = 'unrecognised';
}
%result = (
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/SpreadRevolutionaryDate/MsgMaker/PromptUser.pm view on Meta::CPAN
$msg = prompt($question, $self->default);
$confirm = prompt(
message => $confirm_intro . ' "' . $msg . '", ' . $confirm_question,
default => $confirm_ok,
validate => qr/^[$confirm_ok$confirm_nok]$/i,
escape => qr/^$confirm_abort$/,
error => $confirm_error,
tries => 2,
);
}
die "$abort\n" unless defined $confirm && $confirm =~ qr($confirm_ok);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/SpreadsheetUtils.pm view on Meta::CPAN
schema => 'bool*',
description => <<'_',
This is like `--input-tsv` option but for output instead of input.
Overriden by `--output-sep-char`, `--output-quote-char`, `--output-escape-char`
options. If one of those options is specified, then `--output-tsv` will be
ignored.
_
tags => ['category:output'],
lib/App/SpreadsheetUtils.pm view on Meta::CPAN
Defaults to `"` (double quote). Overrides `--output-tsv` option.
_
tags => ['category:output'],
},
output_escape_char => {
summary => 'Specify character to escape value in field in output CSV, will be passed to Text::CSV_XS',
schema => ['str*', len=>1],
description => <<'_',
This is like `--input-escape-char` option but for output instead of input.
Defaults to `\\` (backslash). Overrides `--output-tsv` option.
_
tags => ['category:output'],
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Sqitch/Command/config.pm view on Meta::CPAN
=head1 Description
You can query/set/replace/unset Sqitch options with this command. The name is
actually the section and the key separated by a dot, and the value will be
escaped.
=head1 Interface
=head2 Class Methods
view all matches for this distribution
view release on metacpan or search on metacpan
newRV_noinc() NEED_newRV_noinc NEED_newRV_noinc_GLOBAL
newSV_type() NEED_newSV_type NEED_newSV_type_GLOBAL
newSVpvn_flags() NEED_newSVpvn_flags NEED_newSVpvn_flags_GLOBAL
newSVpvn_share() NEED_newSVpvn_share NEED_newSVpvn_share_GLOBAL
pv_display() NEED_pv_display NEED_pv_display_GLOBAL
pv_escape() NEED_pv_escape NEED_pv_escape_GLOBAL
pv_pretty() NEED_pv_pretty NEED_pv_pretty_GLOBAL
sv_2pv_flags() NEED_sv_2pv_flags NEED_sv_2pv_flags_GLOBAL
sv_2pvbyte() NEED_sv_2pvbyte NEED_sv_2pvbyte_GLOBAL
sv_catpvf_mg() NEED_sv_catpvf_mg NEED_sv_catpvf_mg_GLOBAL
sv_catpvf_mg_nocontext() NEED_sv_catpvf_mg_nocontext NEED_sv_catpvf_mg_nocontext_GLOBAL
ptr_table_split||5.009005|
ptr_table_store||5.009005|
push_scope|||
put_byte|||
pv_display|5.006000||p
pv_escape|5.009004||p
pv_pretty|5.009004||p
pv_uni_display||5.007003|
qerror|||
qsortsvu|||
re_compile||5.009005|
#ifndef PERL_PV_PRETTY_REGPROP
# define PERL_PV_PRETTY_REGPROP PERL_PV_PRETTY_ELLIPSES|PERL_PV_PRETTY_LTGT|PERL_PV_ESCAPE_RE
#endif
/* Hint: pv_escape
* Note that unicode functionality is only backported to
* those perl versions that support it. For older perl
* versions, the implementation will fall back to bytes.
*/
#ifndef pv_escape
#if defined(NEED_pv_escape)
static char * DPPP_(my_pv_escape)(pTHX_ SV * dsv, char const * const str, const STRLEN count, const STRLEN max, STRLEN * const escaped, const U32 flags);
static
#else
extern char * DPPP_(my_pv_escape)(pTHX_ SV * dsv, char const * const str, const STRLEN count, const STRLEN max, STRLEN * const escaped, const U32 flags);
#endif
#ifdef pv_escape
# undef pv_escape
#endif
#define pv_escape(a,b,c,d,e,f) DPPP_(my_pv_escape)(aTHX_ a,b,c,d,e,f)
#define Perl_pv_escape DPPP_(my_pv_escape)
#if defined(NEED_pv_escape) || defined(NEED_pv_escape_GLOBAL)
char *
DPPP_(my_pv_escape)(pTHX_ SV *dsv, char const * const str,
const STRLEN count, const STRLEN max,
STRLEN * const escaped, const U32 flags)
{
const char esc = flags & PERL_PV_ESCAPE_RE ? '%' : '\\';
const char dq = flags & PERL_PV_ESCAPE_QUOTE ? '"' : esc;
char octbuf[32] = "%123456789ABCDF";
STRLEN wrote = 0;
wrote++;
}
if (flags & PERL_PV_ESCAPE_FIRSTCHAR)
break;
}
if (escaped != NULL)
*escaped= pv - str;
return SvPVX(dsv);
}
#endif
#endif
DPPP_(my_pv_pretty)(pTHX_ SV *dsv, char const * const str, const STRLEN count,
const STRLEN max, char const * const start_color, char const * const end_color,
const U32 flags)
{
const U8 dq = (flags & PERL_PV_PRETTY_QUOTE) ? '"' : '%';
STRLEN escaped;
if (!(flags & PERL_PV_PRETTY_NOCLEAR))
sv_setpvs(dsv, "");
if (dq == '"')
sv_catpvs(dsv, "<");
if (start_color != NULL)
sv_catpv(dsv, D_PPP_CONSTPV_ARG(start_color));
pv_escape(dsv, str, count, max, &escaped, flags | PERL_PV_ESCAPE_NOCLEAR);
if (end_color != NULL)
sv_catpv(dsv, D_PPP_CONSTPV_ARG(end_color));
if (dq == '"')
sv_catpvs(dsv, "\"");
else if (flags & PERL_PV_PRETTY_LTGT)
sv_catpvs(dsv, ">");
if ((flags & PERL_PV_PRETTY_ELLIPSES) && escaped < count)
sv_catpvs(dsv, "...");
return SvPVX(dsv);
}
view all matches for this distribution
view release on metacpan or search on metacpan
examples/complex/complex_endpoint.pl view on Meta::CPAN
my $group_id = $q->param('group_id');
my $queue = $q->param('queue');
return unless $queue && $group_id;
$queue = URI::Escape::uri_unescape($queue);
my $JSON = JSON::->new()->utf8();
my $queue_ref = $JSON->decode($queue);
$queue = undef;
# the current jantior is on top of the list
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Standup/Diary/Template.pm view on Meta::CPAN
return $diary_template;
}
method render {
my $mt = Mojo::Template->new(auto_escape => 1);
my $month = $self->date->mon;
my $month_numeric = $self->date->mon < 10 ? "0$month" : $month;
return $mt->vars(1)->render(
$self->get_template, {
priorities_date => $self->date->year . '-' . $month_numeric,
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/Sysadmin/Log/Simple/HTTP.pm view on Meta::CPAN
# ABSTRACT: a HTTP (maybe RESTful?) logger for App::Sysadmin::Log::Simple
our $VERSION = '0.009'; # VERSION
use Carp;
use HTTP::Tiny;
use URI::Escape qw(uri_escape);
our $HTTP_TIMEOUT = 10;
sub new {
view all matches for this distribution
view release on metacpan or search on metacpan
share/test/asciitable/ascii7.org view on Meta::CPAN
| 013 | 11 | 0B | VT '\v' (vertical tab) |
| 014 | 12 | 0C | FF '\f' (form feed) |
| 015 | 13 | 0D | CR '\r' (carriage ret) |
| 016 | 14 | 0E | SO (shift out) |
| 017 | 15 | 0F | SI (shift in) |
| 020 | 16 | 10 | DLE (data link escape) |
| 021 | 17 | 11 | DC1 (device control 1) |
| 022 | 18 | 12 | DC2 (device control 2) |
| 023 | 19 | 13 | DC3 (device control 3) |
| 024 | 20 | 14 | DC4 (device control 4) |
| 025 | 21 | 15 | NAK (negative ack.) |
| 026 | 22 | 16 | SYN (synchronous idle) |
| 027 | 23 | 17 | ETB (end of trans. blk) |
| 030 | 24 | 18 | CAN (cancel) |
| 031 | 25 | 19 | EM (end of medium) |
| 032 | 26 | 1A | SUB (substitute) |
| 033 | 27 | 1B | ESC (escape) |
| 034 | 28 | 1C | FS (file separator) |
| 035 | 29 | 1D | GS (group separator) |
| 036 | 30 | 1E | RS (record separator) |
| 037 | 31 | 1F | US (unit separator) |
| 040 | 32 | 20 | SPACE |
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/Tailor.pm view on Meta::CPAN
Modifier rules are applied to each line of input B<SECOND>.
=head2 colorize
Accepts a regex which, when matched, will cause the entire match to be
colorized using ANSI color escapes. The second argument is a list of color
labels to be applied. See L<Term::ANSIColor/Function-Interface> for acceptable
labels.
# "foo" has fg:red, bg:white
colorize qr/foo/ => qw(red on_white);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Tarotplane/Cards.pm view on Meta::CPAN
# Truncate whitespace
$card->{Term} =~ s/\s+/ /g;
$card->{Definition} =~ s/\s+/ /g;
## Now interpret some escape codes
# '\:' -> ':'
$card->{Term} =~ s/\\:/:/g;
$card->{Definition} =~ s/\\:/:/g;
# '\n' -> line break
lib/App/Tarotplane/Cards.pm view on Meta::CPAN
# Skip comments and blanks
my $first = substr $l, 0, 1;
next if $first eq '#' or $first eq "\n";
# Substitute '\\' now so that '\\:' does not count as an escaped colon.
# The null byte is added so that the subsequent substitutions do not
# try to replace any '\\' escaped backslash.
$l =~ s/\\\\/\\\0/g;
if ($state == CARD_TERM) {
# Does card contain non-escaped colon?
if ($l =~ /(^|[^\\]):/) {
my (undef,
$te,
$de
) = split(/(^.*[^\\]):/, $l, 2);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Task.pm view on Meta::CPAN
);
return $rv;
}
sub _escape {
my ( $str, $leave_slashes ) = @_;
$str =~ s/\\/\\\\/g unless $leave_slashes;
$str =~ s/\n/\\n/g;
$str =~ s/\t/\\t/g;
lib/App/Task.pm view on Meta::CPAN
my $task = $code;
my $type = ref($code);
if ( $type eq 'ARRAY' ) {
my $disp = join " ", map {
my $copy = "$_";
$copy = _escape( $copy, 1 );
if ( $copy =~ m/ / ) { $copy =~ s/'/\\'/g; $copy = "'$copy'" }
$copy
} @{$code};
if ( $ENV{App_Task_DRYRUN} ) {
$task = sub { print "(DRYRUN) ï¼ï¼¿ $disp\n" };
lib/App/Task.pm view on Meta::CPAN
$task = $cmdhr->{fatal} ? sub { _sys( @{$code} ) or die "`$disp` did not exit cleanly: $?\n" } : sub { _sys( @{$code} ) };
}
}
elsif ( !$type ) {
my $disp = _escape( $code, 0 );
if ( $ENV{App_Task_DRYRUN} ) {
$task = sub { print "(DRYRUN) ï¼ï¼¿ $disp\n" };
}
else {
$task = $cmdhr->{fatal} ? sub { _sys($code) or die "`$disp` did not exit cleanly: $?\n" } : sub { _sys($code) };
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/TemplateServer.pm view on Meta::CPAN
);
};
method _render_template($req) {
my $context = $self->_mk_context($req);
my $template = uri_unescape($req->uri->path);
$template =~ s{^/}{};
my $content = $self->provider->render_template($template, $context);
return _success($content);
};
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Templer/Plugin/Dollar.pm view on Meta::CPAN
=for example begin
<html>
<head>
<title>${title escape="html"}</title>
<meta name='author' content='${author} ${email escape=url}'/>
</head>
<body>
</body>
</html>
lib/Templer/Plugin/Dollar.pm view on Meta::CPAN
the transformation. The third line of the example is for instance transformed
as
=for example begin
<title><tmpl_var name="title" escape="html"></title>
=for example end
=cut
view all matches for this distribution
view release on metacpan or search on metacpan
Revision history for App-Termcast
0.13 2014-09-16
- Use a less intrusive (and more easily parsable) escape sequence for
metadata. I believe terminals should just ignore this if it ends up
actually getting sent to the terminal instead of stripped out by the
termcast server, but let me know if this isn't the case.
0.12 2012-03-15
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
asciitable.
0.008 2022-02-18 Released-By: PERLANCAR; Urgency: medium
- [bugfix] Revert back 0.007's decision to set escape_char to '\'
because the common default is '"'.
0.007 2022-02-18 Released-By: PERLANCAR; Urgency: medium; Backward-Incompatible: yes; Broken: yes
- Allow customizing CSV's escape_char with --escape-char.
- [backward incompatible] CSV parser is instantiated with escape_char
set to '\' (backslash) to handle backslash escaping. Also, the
precedence of --tsv is increased to preced --csv-sep et al. UPDATE:
reversed in 0.008.
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/TimeTracker/Command/Gitlab.pm view on Meta::CPAN
our $VERSION = "1.004";
use Moose::Role;
use HTTP::Tiny;
use JSON::XS qw(encode_json decode_json);
use URI::Escape qw(uri_escape);
has 'issue' => (
is => 'rw',
isa => 'Str',
documentation => 'gitlab issue',
lib/App/TimeTracker/Command/Gitlab.pm view on Meta::CPAN
if (my $remove = $on_start->{remove}) {
foreach my $remove (@$remove) {
delete $l{$remove};
}
}
$self->_call('PUT','projects/'.$self->project_id.'/issues/'.$self->issue.'?labels='.uri_escape(join(',',keys %l)));
say "Labels are now: ".join(', ',sort keys %l);
}
};
#after [ 'cmd_start', 'cmd_continue', 'cmd_append' ] => sub {
view all matches for this distribution