Result:
found more than 741 distributions - search limited to the first 2001 files matching your query ( run in 2.746 )


App-ShellCompleter-YoutubeDl

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN



0.09    2016-06-01  Released-By: PERLANCAR

	- Update to youtube-dl 2016.05.30.2 (add --(no-)mark-watched,
	  --fragment-retries, --hls-prefer-ffmpeg).


0.08    2016-02-16  Released-By: PERLANCAR

	- Update to youtube-dl 2016.02.13 (add --hls-use-mpegts).

 view all matches for this distribution


App-ShellCompleter-cpanm

 view release on metacpan or  search on metacpan

devdata/Menlo-CLI-Compat.v1.9022.pm.txt  view on Meta::CPAN

        'verify!'   => \$self->{verify},
        'q|quiet!'  => \$self->{quiet},
        'h|help'    => sub { $self->{action} = 'show_help' },
        'V|version' => sub { $self->{action} = 'show_version' },
        'perl=s'    => sub {
            $self->diag("--perl is deprecated since it's known to be fragile in figuring out dependencies. Run `$_[1] -S cpanm` instead.\n", 1);
            $self->{perl} = $_[1];
        },
        'l|local-lib=s' => sub { $self->{local_lib} = $self->maybe_abs($_[1]) },
        'L|local-lib-contained=s' => sub {
            $self->{local_lib} = $self->maybe_abs($_[1]);

 view all matches for this distribution


App-SimpleBackuper

 view release on metacpan or  search on metacpan

local/lib/perl5/Module/Build/Base.pm  view on Meta::CPAN


  if (my $add = $self->meta_add) {
    if (not exists $add->{'meta-spec'} or $add->{'meta-spec'}{version} != 2) {
      require CPAN::Meta::Converter;
      if (CPAN::Meta::Converter->VERSION('2.141170')) {
        $add = CPAN::Meta::Converter->new($add)->upgrade_fragment;
        delete $add->{prereqs}; # XXX this would now overwrite all prereqs
      }
      else {
        $self->log_warn("Can't meta_add without CPAN::Meta 2.141170");
      }

 view all matches for this distribution


App-SimulateReads

 view release on metacpan or  search on metacpan

lib/App/SimulateReads/Command/Custom.pm  view on Meta::CPAN

	'count-loops-by'   => 'coverage',
	'coverage'         => 8,
	'strand-bias'      => 'random',
	'seqid-weight'     => 'length',
	'sequencing-type'  => 'paired-end',
	'fragment-mean'    => 300,
	'fragment-stdd'    => 50,
	'sequencing-error' => 0.005,
	'read-size'        => 100,
	'quality-profile'  => 'poisson'
}

lib/App/SimulateReads/Command/Custom.pm  view on Meta::CPAN

  -e, --sequencing-error         sequencing error rate
                                 [default:"0.005"; Number]
  -r, --read-size                the read size [default:"100"; Integer]
                                 the quality_profile from database overrides
                                 this value
  -m, --fragment-mean            the mean size fragments for paired-end reads
                                 [default:"300"; Integer]
  -d, --fragment-stdd            the standard deviation for fragment sizes
                                 [default:"50"; Integer]
  -b, --strand-bias              which strand to be used: plus, minus and random
                                 [default:"random"]
  -w, --seqid-weight             seqid raffle type: length, same, file
                                 [default: "length"]

lib/App/SimulateReads/Command/Custom.pm  view on Meta::CPAN

	%e           sequencing error
	%R           read 1, or 2 if it is the paired-end mate
	%U           read number
	%r           read size
	%c           sequence id as chromossome, ref
	%s           read or fragment strand
	%t           read start position
	%n           read end position

Paired-end specific escape characters

	Escape       Meaning
	------       ------------------------------------------
	%T           mate read start position
	%N           mate read end position
	%D           distance between the paired-reads
	%m           fragment mean
	%d           fragment standard deviation
	%f           fragment size
	%S           fragment start position
	%E           fragment end position

=item B<--jobs>

Sets the number of child jobs to be created

lib/App/SimulateReads/Command/Custom.pm  view on Meta::CPAN


=item B<--sequencing-type>

Sets the sequencing type to single-end or paired-end

=item B<--fragment-mean>

If the sequencing-type is set to paired-end, it sets the
fragment mean

=item B<--fragment-stdd>

If the sequencing-type is set to paired-end, it sets the
fragment standard deviation

=item B<--sequencing-error>

Sets the sequencing error rate. Valid values are between zero and one

 view all matches for this distribution


App-Slackeria

 view release on metacpan or  search on metacpan

lib/App/Slackeria/Plugin/Whohas.pm  view on Meta::CPAN


whohas(1).

=head1 BUGS AND LIMITATIONS

whohas is quite fragile at times.  Also, we are parsing raw text output here,
so there's no guarantee that we actually get the right line.

=head1 AUTHOR

Copyright (C) 2011 by Daniel Friesel E<lt>derf@finalrewind.orgE<gt>

 view all matches for this distribution


App-SlideServer

 view release on metacpan or  search on metacpan

share/public/highlight/highlight.min.js  view on Meta::CPAN

aliases:["rb","gemspec","podspec","thor","irb"],keywords:t,illegal:/\/\*/,
contains:[e.SHEBANG({binary:"ruby"})].concat(m).concat(b).concat(u)}}})()
;hljs.registerLanguage("ruby",e)})();/*! `graphql` grammar compiled for Highlight.js 11.7.0 */
(()=>{var e=(()=>{"use strict";return e=>{const a=e.regex;return{name:"GraphQL",
aliases:["gql"],case_insensitive:!0,disableAutodetect:!1,keywords:{
keyword:["query","mutation","subscription","type","input","schema","directive","interface","union","scalar","fragment","enum","on"],
literal:["true","false","null"]},
contains:[e.HASH_COMMENT_MODE,e.QUOTE_STRING_MODE,e.NUMBER_MODE,{
scope:"punctuation",match:/[.]{3}/,relevance:0},{scope:"punctuation",
begin:/[\!\(\)\:\=\[\]\{\|\}]{1}/,relevance:0},{scope:"variable",begin:/\$/,
end:/\W/,excludeEnd:!0,relevance:0},{scope:"meta",match:/@\w+/,excludeEnd:!0},{

 view all matches for this distribution


App-SlimPacker

 view release on metacpan or  search on metacpan

t/bundle.t  view on Meta::CPAN

    unlike $c, qr/# keep me/, 'module comments minified (default)';
    unlike $c, qr/# boot comment/, 'program comments minified (default)';
    unlike $c, qr/\$who/, 'short variable renamed (strings with it would block, fixture avoids that)';
    unlike $c, qr/use lib/, 'use lib stripped from program';
    like $c, qr/BEGIN\{my%sl=\(/, 'compact loader: single BEGIN{my%sl=(...) block';
    like $c, qr/bless\\%sl,\$class;/, 'compact loader: bless+unshift {$class} fragment';
    unlike $c, qr/__SLPACK_ENTRIES__/, 'loader placeholder spliced away';
    like $c, qr/use Compress::Raw::Zlib \(\);/, 'compressed loader: core zlib loaded';
    like $c, qr/use MIME::Base64 qw\(decode_base64\);/, 'compressed loader: core base64 loaded';
    my ($table) = $c =~ /BEGIN\{my%sl=\((.*?)\);my\$class=/s
        or die "cannot locate module table in bundle";

 view all matches for this distribution


App-SocialSKK

 view release on metacpan or  search on metacpan

inc/File/Find/Rule.pm  view on Meta::CPAN


sub in {
    my $self = _force_object shift;

    my @found;
    my $fragment = $self->_compile( $self->{subs} );
    my @subs = @{ $self->{subs} };

    warn "relative mode handed multiple paths - that's a bit silly\n"
      if $self->{relative} && @_ > 1;

inc/File/Find/Rule.pm  view on Meta::CPAN

           and return;

        #print "Testing \'$_\'\n";

        my $discarded;
        return unless ' . $fragment . ';
        return if $discarded;
        if ($relative) {
            push @found, $relpath if $relpath ne "";
        }
        else {

inc/File/Find/Rule.pm  view on Meta::CPAN

a private global hash.  Something like $subs{$self} = []; and in
C<DESTROY>, delete $subs{$self}.

That'd make compiling subrules really much easier (no need to pass
@subs in for context), and things that work via a mix of callbacks and
code fragments are possible (you'd probably want this for the stat
tests).

Need to check this currently working version in before I play with
that though.

 view all matches for this distribution


App-SpreadRevolutionaryDate

 view release on metacpan or  search on metacpan

lib/App/SpreadRevolutionaryDate/MsgMaker/RevolutionaryDate/Locale/fr.pm  view on Meta::CPAN

      1pierre_à_plâtre  0sel             0fer             0cuivre    0chat
      2étain            0plomb           0zinc            0mercure   0crible
    ),
    # Pluviôse
    qw(
      1lauréole      1mousse      0fragon     0perce-neige  0taureau
      0laurier-thym  2amadouvier  0mézéréon   0peuplier     1coignée
      2ellébore      0brocoli     0laurier    2avelinier    1vache
      0buis          0lichen      2if         1pulmonaire   1serpette
      0thlaspi       0thymelé     0chiendent  1traînasse    0lièvre
      1guède         0noisetier   0cyclamen   1chélidoine   0traîneau

 view all matches for this distribution


App-Sqitch

 view release on metacpan or  search on metacpan

lib/sqitch-target.pod  view on Meta::CPAN

=item C<uri>

The L<database connection URI|URI::db> for the target. Required. Its format is:

  db:engine:[dbname]
  db:engine:[//[user[:password]@][host][:port]/][dbname][?params][#fragment]

Some examples:

=over

 view all matches for this distribution


App-Staticperl

 view release on metacpan or  search on metacpan

README  view on Meta::CPAN


DESCRIPTION
    This script helps you to create single-file perl interpreters or
    applications, or embedding a perl interpreter in your applications.
    Single-file means that it is fully self-contained - no separate shared
    objects, no autoload fragments, no .pm or .pl files are needed. And when
    linking statically, you can create (or embed) a single file that
    contains perl interpreter, libc, all the modules you need, all the
    libraries you need and of course your actual program.

    With uClibc and upx on x86, you can create a single 500kb binary that

README  view on Meta::CPAN

        approach.

    Getting rid of netdb functions
        The perl core has lots of netdb functions ("getnetbyname",
        "getgrent" and so on) that few applications use. You can avoid
        compiling them in by putting the following fragment into a
        "preconfigure" hook:

           preconfigure() {
              for sym in \
                 d_getgrnam_r d_endgrent d_endgrent_r d_endhent \

 view all matches for this distribution


App-Tel

 view release on metacpan or  search on metacpan

inc/Module/AutoInstall.pm  view on Meta::CPAN

    return 1;
}

sub postamble {
    $PostambleUsed = 1;
    my $fragment;

    $fragment .= <<"AUTO_INSTALL" if !$InstallDepsTarget;

config :: installdeps
\t\$(NOECHO) \$(NOOP)
AUTO_INSTALL

    $fragment .= <<"END_MAKE";

checkdeps ::
\t\$(PERL) $0 --checkdeps

installdeps ::

inc/Module/AutoInstall.pm  view on Meta::CPAN

listalldeps ::
\t$PostambleActionsListAllDeps

END_MAKE

    return $fragment;
}

1;

__END__

 view all matches for this distribution


App-Templer

 view release on metacpan or  search on metacpan

examples/complex/input/jquery.min.js  view on Meta::CPAN

/*! jQuery v1.8.3 jquery.com | jquery.org/license */
(function(e,t){function _(e){var t=M[e]={};return v.each(e.split(y),function(e,n){t[n]=!0}),t}function H(e,n,r){if(r===t&&e.nodeType===1){var i="data-"+n.replace(P,"-$1").toLowerCase();r=e.getAttribute(i);if(typeof r=="string"){try{r=r==="true"?!0:r=...

 view all matches for this distribution


App-Test-Generator

 view release on metacpan or  search on metacpan

lib/App/Test/Generator.pm  view on Meta::CPAN

				}
			}
		}
	}

	# Prepare seed/iterations code fragment for the generated test
	my $seed_code = '';
	if (defined $seed) {
		# ensure integer-ish
		$seed = int($seed);
		$seed_code = "srand($seed);\n";

lib/App/Test/Generator.pm  view on Meta::CPAN

}

=head2 render_arrayref_map

Render a hashref whose values are arrayrefs into a Perl source-code
fragment suitable for use as a hash literal in a generated test file.

    my $code = render_arrayref_map({ name => ['', 'a' x 100] });

=head3 Arguments

lib/App/Test/Generator.pm  view on Meta::CPAN

#             falling back to single-quoted form with
#             escaped apostrophes if no delimiter is
#             available.
#
# Entry:      $s - the string to wrap. May be undef.
# Exit:       Returns a Perl source-code fragment that
#             evaluates to the original string value,
#             or the string 'undef' if $s is undef.
#
# Notes:      index() returns -1 when not found and
#             any value >= 0 when found, including 0

lib/App/Test/Generator.pm  view on Meta::CPAN

	return $s;
}

=head2 perl_quote

Convert any Perl value into a source-code fragment that reproduces that value
when evaluated in a generated test file.

=head3 Arguments

=over 4

 view all matches for this distribution


App-TextFragmentUtils

 view release on metacpan or  search on metacpan

lib/App/TextFragmentUtils.pm  view on Meta::CPAN

    }
    $tf_args{text} = $text;
    \%tf_args;
}

$SPEC{list_fragments} = do {
    my $meta = clone $Text::Fragment::SPEC{list_fragments};
    delete $meta->{args}{text};
    $meta->{args}{filename} = $filename_arg;
    $meta;
};
sub list_fragments {
    my %args = @_;

    my $tf_args = _get_tf_args(%args);
    Text::Fragment::list_fragments(%$tf_args);
}

$SPEC{get_fragment} = do {
    my $meta = clone $Text::Fragment::SPEC{get_fragment};
    delete $meta->{args}{text};
    $meta->{args}{filename} = $filename_arg;
    $meta;
};
sub get_fragment {
    my %args = @_;

    my $tf_args = _get_tf_args(%args);
    Text::Fragment::get_fragment(%$tf_args);
}

1;
# ABSTRACT: CLI utilities related to Text::Fragment

lib/App/TextFragmentUtils.pm  view on Meta::CPAN

This document describes version 0.002 of App::TextFragmentUtils (from Perl distribution App-TextFragmentUtils), released on 2021-05-25.

=head1 DESCRIPTION

This distributions provides the following command-line utilities related to
text fragment:

=over

=item * L<get-fragment>

=item * L<list-fragments>

=back

=head1 FUNCTIONS


=head2 get_fragment

Usage:

 get_fragment(%args) -> [$status_code, $reason, $payload, \%result_meta]

Get fragment with a certain ID in text.

If there are multiple occurences of the fragment with the same ID ,

This function is not exported.

Arguments ('*' denotes required arguments):

lib/App/TextFragmentUtils.pm  view on Meta::CPAN

that contains extra information.

Return value: Fragment (array)


Will return status 200 if fragment is found. Result will be a hash with the
following keys: C<raw> (string), C<payload> (string), C<attrs> (hash), C<id>
(string, can also be found in attributes).

Return 404 if fragment is not found.



=head2 list_fragments

Usage:

 list_fragments(%args) -> [$status_code, $reason, $payload, \%result_meta]

List fragments in text.

This function is not exported.

Arguments ('*' denotes required arguments):

lib/App/TextFragmentUtils.pm  view on Meta::CPAN

($reason) is a string containing error message, or "OK" if status is
200. Third element ($payload) is optional, the actual result. Fourth
element (%result_meta) is called result metadata and is optional, a hash
that contains extra information.

Return value: List of fragments (array)


Will return status 200 if operation is successful. Result will be an array of
fragments, where each fragment is a hash containing these keys: C<raw> (string),
C<payload> (string), C<attrs> (hash), C<id> (string, can also be found in
attributes).

=head1 HOMEPAGE

 view all matches for this distribution


App-TextTemplatePermuteUtils

 view release on metacpan or  search on metacpan

lib/App/TextTemplatePermuteUtils.pm  view on Meta::CPAN

This document describes version 0.002 of App::TextTemplatePermuteUtils (from Perl distribution App-TextTemplatePermuteUtils), released on 2026-02-22.

=head1 DESCRIPTION

This distributions provides the following command-line utilities related to
text fragment:

=over

=item * L<template-permute>

 view all matches for this distribution


App-URIUtils

 view release on metacpan or  search on metacpan

lib/App/URIUtils.pm  view on Meta::CPAN


            scheme => $url->scheme,
            has_recognized_scheme => $url->has_recognized_scheme,
            opaque => $url->opaque,
            path => $url->path, # unescaped string
            fragment => $url->fragment,
            canonical => $url->canonical . "",
            authority => $url->authority,
            query => $url->query, # escaped

            # server/host methods

lib/App/URIUtils.pm  view on Meta::CPAN

 {
   authority             => "www.tokopedia.com",
   base                  => undef,
   canonical             => "https://www.tokopedia.com/search?st=product&q=soundmagic%20e10",
   default_port          => 443,
   fragment              => undef,
   full_path             => "/search?st=product&q=soundmagic%20e10",
   has_recognized_scheme => 1,
   host                  => "www.tokopedia.com",
   opaque                => "//www.tokopedia.com/search?st=product&q=soundmagic%20e10",
   orig                  => "https://www.tokopedia.com/search?st=product&q=soundmagic%20e10",

 view all matches for this distribution


App-WRT

 view release on metacpan or  search on metacpan

lib/App/WRT.pm  view on Meta::CPAN

You will likely need to use C<sudo> or C<su> to get a systemwide install.

=head1 DESCRIPTION

This started life somewhere around 2001 as C<display.pl>, a CGI script to
concatenate fragments of handwritten HTML by date.  It has since accumulated
several of the usual weblog features (lightweight markup, feed generation,
embedded Perl, poetry tools, image galleries, and ill-advised dependencies),
but the basic idea hasn't changed that much.

The C<wrt> utility now generates static HTML files, instead of expecting to

lib/App/WRT.pm  view on Meta::CPAN


sub datestamp {
  my $self = shift;
  my ($entry) = @_;

  my @fragment_stack;
  my @fragment_stamps = (
    a({ href => $self->{url_root} }, $self->{title_prefix}),
  );

  # Chop up by directory separator:
  my @pieces = split '/', $entry;

  foreach my $fragment (@pieces) {
    push @fragment_stack, $fragment;
    push @fragment_stamps,
         a({ href => $self->{url_root} . (join '/', @fragment_stack) . '/',
             title => $fragment }, $fragment);
  }

  my $stamp = p({class => 'datestamp'}, join(" /\n", @fragment_stamps));
  my $tag_list = $self->entry_tag_list($entry);
  if ($tag_list) {
    $stamp = "\n" . p({class => 'tags'}, $tag_list) . $stamp;
  }

 view all matches for this distribution


App-Wax

 view release on metacpan or  search on metacpan

lib/App/Wax.pm  view on Meta::CPAN

    my $extension = '';
    my $split = $self->is_url($url);

    return $extension unless ($split);

    my ($scheme, $domain, $path, $query, $fragment) = @$split;
    my $content_type = $self->content_type($_url);

    return $extension unless ($content_type); # won't be defined if the URL is invalid

    if (INFER_EXTENSION->{$content_type}) {

lib/App/Wax.pm  view on Meta::CPAN


# return a truthy value (an arrayref containing the URL's components)
# if the supplied value can be parsed as a URL, or a falsey value otherwise
method is_url ($url) {
    if ($url =~ m{^[a-zA-Z][\w+]*://}) { # basic sanity check
        my ($scheme, $domain, $path, $query, $fragment) = uri_split($url);

        if ($scheme && ($domain || $path)) { # no domain for file:// URLs
            return [$scheme, $domain, $path, $query, $fragment];
        }
    }
}

# log a message to stderr if logging is enabled

 view all matches for this distribution


App-Yath-Script

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN


0.999009  2020-02-27 07:27:29-08:00 America/Los_Angeles (TRIAL RELEASE)

    - Fix sorting in ordering tests
    - Fix incorrect line numbers in plugin.t errors
    - Less fragile fork check in Makefile.PL

0.999008  2020-02-26 20:25:34-08:00 America/Los_Angeles (TRIAL RELEASE)

    - Only officially support systems with true fork().

 view all matches for this distribution


App-Zapzi

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

    desired output
  * Added -t command line switch to allow selection of transformers
  * Use UTF-8 to encode MOBI files
  * Bugfix for article test
  * Set Moo version dependency
  * Handle HTML fragments as HTML in files
  * Bugfix for HTML articles with no title
  * Handle HTML pages with two title tags and extra whitespace
  * Format title for text with leading whitespace and long lines
  * Added config table plus support for schema versioning and upgrades

 view all matches for this distribution


App-cloc

 view release on metacpan or  search on metacpan

bin/cloc  view on Meta::CPAN

			'vert'        => 'GLSL'                  ,
			'tesc'        => 'GLSL'                  ,
			'tese'        => 'GLSL'                  ,
			'geom'        => 'GLSL'                  ,
			'feature'     => 'Cucumber'              ,
			'frag'        => 'GLSL'                  ,
			'comp'        => 'GLSL'                  ,
            'g'           => 'ANTLR Grammar'         ,
            'g4'          => 'ANTLR Grammar'         ,
            'go'          => 'Go'                    ,
            'gsp'         => 'Grails'                ,

 view all matches for this distribution


App-cpanminus

 view release on metacpan or  search on metacpan

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

          'verify!'   => \$self->{verify},
          'q|quiet!'  => \$self->{quiet},
          'h|help'    => sub { $self->{action} = 'show_help' },
          'V|version' => sub { $self->{action} = 'show_version' },
          'perl=s'    => sub {
              $self->diag("--perl is deprecated since it's known to be fragile in figuring out dependencies. Run `$_[1] -S cpanm` instead.\n", 1);
              $self->{perl} = $_[1];
          },
          'l|local-lib=s' => sub { $self->{local_lib} = $self->maybe_abs($_[1]) },
          'L|local-lib-contained=s' => sub {
              $self->{local_lib} = $self->maybe_abs($_[1]);

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  
      JSON::PP::decode_json($json);
  }
  
  sub uri_escape {
      my($self, $fragment) = @_;
      $fragment =~ s/([^A-Za-z0-9\-\._~])/uc sprintf("%%%02X", ord($1))/eg;
      $fragment;
  }
  
  sub uri_params {
      my($self, @params) = @_;
      my @param_strings;

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

    }
    return $new_data;
  }
  
  sub _convert {
    my ($data, $spec, $to_version, $is_fragment) = @_;
  
    my $new_data = {};
    for my $key ( keys %$spec ) {
      next if $key eq ':custom' || $key eq ':drop';
      next unless my $fcn = $spec->{$key};
      if ( $is_fragment && $key eq 'generated_by' ) {
        $fcn = \&_keep;
      }
      die "spec for '$key' is not a coderef"
        unless ref $fcn && ref $fcn eq 'CODE';
      my $new_value = $fcn->($data->{$key}, $key, $data, $to_version);

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  );
  
  # for a given field in a spec version, what fields will it feed
  # into in the *latest* spec (i.e. v2); meta-spec omitted because
  # we always expect a meta-spec to be generated
  my %fragments_generate = (
    '2' => {
      'abstract'            =>   'abstract',
      'author'              =>   'author',
      'generated_by'        =>   'generated_by',
      'license'             =>   'license',

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

      'configure_requires'  => 'prereqs',
    },
  );
  # this is not quite true but will work well enough
  # as 1.4 is a superset of earlier ones
  $fragments_generate{$_} = $fragments_generate{'1.4'} for qw/1.3 1.2 1.1 1.0/;
  
  #--------------------------------------------------------------------------#
  # Code
  #--------------------------------------------------------------------------#
  

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  #pod
  #pod Optionally, you can provide a C<default_version> argument after C<$struct>:
  #pod
  #pod   my $cmc = CPAN::Meta::Converter->new( $struct, default_version => "1.4" );
  #pod
  #pod This is only needed when converting a metadata fragment that does not include a
  #pod C<meta-spec> field.
  #pod
  #pod =cut
  
  sub new {

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  sub convert {
    my ($self, %args) = @_;
    my $args = { %args };
  
    my $new_version = $args->{version} || $HIGHEST;
    my $is_fragment = $args->{is_fragment};
  
    my ($old_version) = $self->{spec};
    my $converted = _dclone($self->{data});
  
    if ( $old_version == $new_version ) {
      $converted = _convert( $converted, $cleanup{$old_version}, $old_version, $is_fragment );
      unless ( $args->{is_fragment} ) {
        my $cmv = CPAN::Meta::Validator->new( $converted );
        unless ( $cmv->is_valid ) {
          my $errs = join("\n", $cmv->errors);
          die "Failed to clean-up $old_version metadata. Errors:\n$errs\n";
        }

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

      my @vers = sort { $b <=> $a } keys %known_specs;
      for my $i ( 0 .. $#vers-1 ) {
        next if $vers[$i] > $old_version;
        last if $vers[$i+1] < $new_version;
        my $spec_string = "$vers[$i+1]-from-$vers[$i]";
        $converted = _convert( $converted, $down_convert{$spec_string}, $vers[$i+1], $is_fragment );
        unless ( $args->{is_fragment} ) {
          my $cmv = CPAN::Meta::Validator->new( $converted );
          unless ( $cmv->is_valid ) {
            my $errs = join("\n", $cmv->errors);
            die "Failed to downconvert metadata to $vers[$i+1]. Errors:\n$errs\n";
          }

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

      my @vers = sort { $a <=> $b } keys %known_specs;
      for my $i ( 0 .. $#vers-1 ) {
        next if $vers[$i] < $old_version;
        last if $vers[$i+1] > $new_version;
        my $spec_string = "$vers[$i+1]-from-$vers[$i]";
        $converted = _convert( $converted, $up_convert{$spec_string}, $vers[$i+1], $is_fragment );
        unless ( $args->{is_fragment} ) {
          my $cmv = CPAN::Meta::Validator->new( $converted );
          unless ( $cmv->is_valid ) {
            my $errs = join("\n", $cmv->errors);
            die "Failed to upconvert metadata to $vers[$i+1]. Errors:\n$errs\n";
          }

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

      }
      return $converted;
    }
  }
  
  #pod =method upgrade_fragment
  #pod
  #pod   my $new_struct = $cmc->upgrade_fragment;
  #pod
  #pod Returns a new hash reference with the metadata converted to the latest version
  #pod of the CPAN Meta Spec.  No validation is done on the result -- you must
  #pod validate after merging fragments into a complete metadata document.
  #pod
  #pod Available since version 2.141170.
  #pod
  #pod =cut
  
  sub upgrade_fragment {
    my ($self) = @_;
    my ($old_version) = $self->{spec};
    my %expected =
      map {; $_ => 1 }
      grep { defined }
      map { $fragments_generate{$old_version}{$_} }
      keys %{ $self->{data} };
    my $converted = $self->convert( version => $HIGHEST, is_fragment => 1 );
    for my $key ( keys %$converted ) {
      next if $key =~ /^x_/i || $key eq 'meta-spec';
      delete $converted->{$key} unless $expected{$key};
    }
    return $converted;

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  
  Optionally, you can provide a C<default_version> argument after C<$struct>:
  
    my $cmc = CPAN::Meta::Converter->new( $struct, default_version => "1.4" );
  
  This is only needed when converting a metadata fragment that does not include a
  C<meta-spec> field.
  
  =head2 convert
  
    my $new_struct = $cmc->convert( version => "2" );

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  
  license
  
  =back
  
  =head2 upgrade_fragment
  
    my $new_struct = $cmc->upgrade_fragment;
  
  Returns a new hash reference with the metadata converted to the latest version
  of the CPAN Meta Spec.  No validation is done on the result -- you must
  validate after merging fragments into a complete metadata document.
  
  Available since version 2.141170.
  
  =head1 BUGS
  

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

      }
      elsif ( ref($next) eq 'HASH' ) {
        my $cmc = CPAN::Meta::Converter->new(
          $next, default_version => $self->{default_version}
        );
        $next = $cmc->upgrade_fragment;
      }
      else {
        croak "Don't know how to merge '$next'";
      }
      $current = _merge($current, $next, $self->{mapping}, []);

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

    return $current;
  }
  
  1;
  
  # ABSTRACT: Merging CPAN Meta fragments
  
  
  # vim: ts=2 sts=2 sw=2 et :
  
  __END__

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  
  =encoding UTF-8
  
  =head1 NAME
  
  CPAN::Meta::Merge - Merging CPAN Meta fragments
  
  =head1 VERSION
  
  version 2.150005
  

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  This creates a CPAN::Meta::Merge object. It takes one mandatory named
  argument, C<version>, declaring the version of the meta-spec that must be
  used for the merge. It can optionally take an C<extra_mappings> argument
  that allows one to add additional merging functions for specific elements.
  
  =head2 merge(@fragments)
  
  Merge all C<@fragments> together. It will accept both CPAN::Meta objects and
  (possibly incomplete) hashrefs of metadata.
  
  =head1 AUTHORS
  
  =over 4

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  }
  
  sub url {
      my ($self,$key,$value) = @_;
      if(defined $value) {
        my ($scheme, $auth, $path, $query, $frag) = _uri_split($value);
        unless ( defined $scheme && length $scheme ) {
          $self->_error( "'$value' for '$key' does not have a URL scheme" );
          return 0;
        }
        unless ( defined $auth && length $auth ) {

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  This is the central parsing function. It can both append new text and
  extract objects from the stream accumulated so far (both of these
  functions are optional).
  
  If C<$string> is given, then this string is appended to the already
  existing JSON fragment stored in the C<$json> object.
  
  After that, if the function is called in void context, it will simply
  return without doing anything further. This can be used to add more text
  in as many chunks as you want.
  

lib/App/cpanminus/fatscript.pm  view on Meta::CPAN

  
  =head2 incr_text
  
      $lvalue_string = $json->incr_text
  
  This method returns the currently stored JSON fragment as an lvalue, that
  is, you can manipulate it. This I<only> works when a preceding call to
  C<incr_parse> in I<scalar context> successfully returned an object. Under
  all other circumstances you must not call this function (I mean it.
  although in simple tests it might actually work, it I<will> fail under
  real world conditions). As a special exception, you can also call this

 view all matches for this distribution


App-cpantimes

 view release on metacpan or  search on metacpan

bin/cpant  view on Meta::CPAN

  }
  
  sub url {
      my ($self,$key,$value) = @_;
      if(defined $value) {
        my ($scheme, $auth, $path, $query, $frag) = _uri_split($value);
        unless ( defined $scheme && length $scheme ) {
          $self->_error( "'$value' for '$key' does not have a URL scheme" );
          return 0;
        }
        unless ( defined $auth && length $auth ) {

 view all matches for this distribution


App-diceware

 view release on metacpan or  search on metacpan

share/wordlist_de.tsv  view on Meta::CPAN

25111	fr
25112	fracht
25113	frack
25114	fraese
25115	fraest
25116	frag
25121	frage
25122	fragen
25123	frager
25124	fragt
25125	fragte
25126	franko
25131	franse
25132	frass
25133	fratze
25134	frau

 view all matches for this distribution


App-genstopwords

 view release on metacpan or  search on metacpan

script/gen-stopwords  view on Meta::CPAN

            open my $fh, '<', $name
                or do { warn_ "WARNING: Cannot open $File::Find::name: $!"; return };

            while (my $line = <$fh>) {
                # Strip POD formatting codes entirely (E<gt>, L<...>, C<...>, etc.)
                # Removing the whole tag prevents fragments like 'gt' or 'Egt' appearing.
                $line =~ s/[A-Z]<[^>]+>//g;

                my $result = aspell_list($line, $lang);
                next unless $result;

 view all matches for this distribution


App-get_flash_videos

 view release on metacpan or  search on metacpan

lib/FlashVideo/Site/Videojug.pm  view on Meta::CPAN


  if ($browser->uri->as_string =~ m'/interview/'i) {
    $playlist_url =
      "http://www.videojug.com/views/interview/playlist.aspx?ar=16_9&id=";

    # Use the browser fragment (like #interview-question-here) to find out
    # which interview clip to download.
    $interview_clip = $browser->uri->fragment; 
  }

  # Get the video ID
  my $video_id;
  

lib/FlashVideo/Site/Videojug.pm  view on Meta::CPAN

sub get_prefix_and_title {
  my ($xml, $video_name) = @_;

  foreach my $media (@{ $xml->{Items}->{Media} }) {
    # This is frail, but try to go from the formatted video title to the
    # title in the same format as in the fragment.
    my $title = lc $media->{Title};
    $title =~ s/ /-/g;
    $title =~ s/[^a-z0-9\-]//g;

    if ($title eq $video_name) {

 view all matches for this distribution


App-gh

 view release on metacpan or  search on metacpan

inc/Module/AutoInstall.pm  view on Meta::CPAN

    return 1;
}

sub postamble {
    $PostambleUsed = 1;
    my $fragment;

    $fragment .= <<"AUTO_INSTALL" if !$InstallDepsTarget;

config :: installdeps
\t\$(NOECHO) \$(NOOP)
AUTO_INSTALL

    $fragment .= <<"END_MAKE";

checkdeps ::
\t\$(PERL) $0 --checkdeps

installdeps ::

inc/Module/AutoInstall.pm  view on Meta::CPAN

listalldeps ::
\t$PostambleActionsListAllDeps

END_MAKE

    return $fragment;
}

1;

__END__

 view all matches for this distribution


App-jsonvalidate

 view release on metacpan or  search on metacpan

scripts/jsonvalidate  view on Meta::CPAN

    $js->set_resolver(sub
    {
        my( $abs_uri ) = @_;
        my $orig_uri = $abs_uri;

        # Strip fragment for all decisions below
        my( $doc_uri, $fragment ) = ( $abs_uri =~ /^([^#]+)(#.*)?$/ );
        $doc_uri //= $abs_uri;
        my $has_fragment = defined( $fragment ) && length( $fragment );

        # First: exact $id match from any schema we were given on the command line
        if( exists( $by_id{ $abs_uri } ) || exists( $by_id{ $doc_uri } ) )
        {
            my $schema = $by_id{ $abs_uri } // $by_id{ $doc_uri };

scripts/jsonvalidate  view on Meta::CPAN


        # Only if user explicitly asked for remote fetching
        #    Can also be called as --allow_http. It is aliased to --remote_refs
        if( $doc_uri =~ m{^https?://}i )
        {
            # The specs say that, if there is a fragment, we should always fetch the remote document.
            my $should_fetch = $has_fragment || $opts->{remote_refs};
            if( $should_fetch )
            {
                _message( 5, "Resolver: fetching remote document $doc_uri (fragment=$has_fragment, remote-refs=", ( $opts->{remote_refs} // 0 ), ")" );
                my $doc = _fetch_http_json( $doc_uri, $json );
                return( $doc ) if( defined( $doc ) );
            }
            else
            {
                _message( 4, "Resolver: refusing to fetch remote $doc_uri (no fragment and --remote-refs not used)" );
                return;
            }
        }

        my $path = file( $doc_uri );

scripts/jsonvalidate  view on Meta::CPAN

        # Fail loudly with helpful message
        bailout( <<EOF );
    Cannot resolve \$ref "$orig_uri"

    Document URI: $doc_uri
    Fragment    : $fragment

    This is probably a fictional/internal \$id (very common and correct!).

    The validator will NOT auto-fetch such URIs by default (security + correctness).

    This looks like a reference to a remote document with a JSON Pointer fragment.
    Such references MUST be retrieved (per JSON Schema spec).

    Solutions:
      • Pass --remote-refs to allow HTTP(S) fetching
      • Provide the referenced schema via additional --schema arguments

 view all matches for this distribution


( run in 2.746 seconds using v1.01-cache-2.11-cpan-b16cb0d3907 )