Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Build a module distribution from just .packlist?

by mpersico (Scribe)
on Aug 19, 2014 at 12:39 UTC ( #1097973=perlquestion: print w/replies, xml ) Need Help??
mpersico has asked for the wisdom of the Perl Monks concerning the following question:

Many of the references I've found to .packlist files are for maintaining them or finding the appropriate one for a module. What I am looking for (before I write it) is a script/module that will USE the .packlist to create a tarball of the already deployed module for further deployment.

Background: I have reference machines (one per OS) where I build Perl. Initial version builds on those machines are tarballed up, pushed out to production machines with no build tools - not even "make" - and untarballed. Currently, new and updated modules are added to these reference copies and the whole of the Perl reference copy is tarballed up and pushed. I'd prefer to be more granular if only from a psychological standpoint: pushing out a new module version is less intimidating-sounding than pushing out the whole distribution. So...

  • Does anyone know of such a beast?
  • If not, how about some namespace suggestions when I write it myself?
  • Thank you.

    • Comment on Build a module distribution from just .packlist?

    Replies are listed 'Best First'.
    Re: Build a module distribution from just .packlist?
    by RonW (Vicar) on Aug 19, 2014 at 16:37 UTC

      There is a huge advantage to "pushing out the whole distribution": You know that what it is on the production servers is exactly what you tested on the reference/staging servers.

      That said, a much easier way to accomplish a "just the new stuff" update would be to use rsync, which is a tool for making the files at the destination the same as the source. rsync will do all the dirty work for you.

      Otherwise, if you are customizing modules you got from CPAN, download the tar file from CPAN, extract, apply your changes to the freshly extracted package, run the tests, then install and do more testing. If everything works correctly, then you can repackage it. Read perlnewmod and related documents to learn more.

      Updated: Fixed a typo.

        1) Yes pushing all is more desirable but it's a psychological issue.

        2) rsync -Duh! Probably the right answer

        3) I'll check out perlnewmod


    Log In?

    What's my password?
    Create A New User
    Node Status?
    node history
    Node Type: perlquestion [id://1097973]
    Front-paged by Corion
    [choroba]: ovedpo15 Hard to tell without context. You probalby used $dir outside of its scope, which is the body of the "unless".
    [choroba]: if you use unless as a statement modifier, you can't use the variable declared in the modifier in the statement.

    How do I use this? | Other CB clients
    Other Users?
    Others taking refuge in the Monastery: (6)
    As of 2018-04-22 19:14 GMT
    Find Nodes?
      Voting Booth?