Coder Social home page Coder Social logo

module-manifest-skip-pm's Introduction

NAME

Module::Manifest::Skip - MANIFEST.SKIP Manangement for Modules

module-manifest-skip-pm module-manifest-skip-pm

SYNOPSIS

From the command line:

> perl -MModule::Manifest::Skip=create

From Perl:

use Module::Manifest::Skip;
use IO::All;

my $mms = Module::Manifest::Skip->new;
# optional add and removes:
$mms->add('^foo-bar$');
$mms->remove('^foo$');
$mms->remove(qr/\Q\bfoo\b/);
io('MANIFEST.SKIP')->print($mms->text);

DESCRIPTION

NOTE: This module is mostly intended for module packaging frameworks to share a common, up-to-date MANIFEST.SKIP base. For example, Module::Install::ManifestSkip, uses this module to get the actual SKIP content. However this module may be useful for any module author.

CPAN module authors use a MANIFEST.SKIP file to exclude certain well known files from getting put into a generated MANIFEST file, which would cause them to go into the final distribution package.

The packaging tools try to automatically skip things for you, but if you add one of your own entries, you have to add all the common ones yourself. This module attempts to make all of this boring process as simple and reliable as possible.

Module::Manifest::Skip can create or update a MANIFEST.SKIP file for you. You can add your own entries, and it will leave them alone. You can even tell it to not skip certain entries that it normally skips, although this is rarely needed.

USAGE

Usually this module is called by other packaging modules. If you want this to be used by Module::Install, then you would put this:

manifest_skip 'clean';

in your Makefile.PL, and everything would be taken care of for you.

If you want to simply create a MANIFEST.SKIP file from the command line, this handy syntax exists:

> perl -MModule::Manifest::Skip=create

BEHAVIOR

This module ships with a share file called share/MANIFEST.SKIP. This is the basis for all new MANIFEST.SKIP files. This module will look for an already existing MANIFEST.SKIP file and take all the text before the first blank line, and prepend it to the start of a new SKIP file. This allows you to put your own personal section at the top, that will not be overwritten later.

It will then look for lines beginning with a dash followed by a space. Like this:

- \bfoo\b
- ^bar/
- ^baz$

It will comment out each of these lines and any other lines that match the text (after the '- '). This allows you to override the default SKIPs.

AUTHOR

Ingy döt Net <[email protected]>

COPYRIGHT AND LICENSE

Copyright 2011-2014. Ingy döt Net.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

See http://www.perl.com/perl/misc/Artistic.html

module-manifest-skip-pm's People

Contributors

csjewell avatar ingydotnet avatar jjn1056 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

module-manifest-skip-pm's Issues

Looking for the share directory in the wrong location

See robrwo/Dist-Zilla-Plugin-Generate-ManifestSkip#1 (comment)

The problem seems to be caused by this line in Module::Manifest::Skip (@ingy FYI)

77: elsif ($path =~ s!(\S.?)[\/]?\blib\b.!$1! and -e "$path/share") {

If Module::Manifest::Skip is installed in a path which has a "lib" component, and if there's a "share" directory next to it, then this share directory will be used. This is often the wrong directory. For example, in my installations the Module::Manifest::Skip path looks like /usr/perl5.24.1p/lib/site_perl/5.24.1/Module/Manifest/Skip.pm. So if there's a /usr/perl5.24.1p/share directory (which is created by some CPAN distributions, e.g. spamassassin), then things fail.

Moo requirement should be stated

Module::Manifest::Skip uses Moo but it isn't specified as a requirement in Makefile.PL or META.yml. Installation will fail if Moo isn't already installed.

xo patch

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.