{"id":32214260,"url":"https://github.com/rlauer6/make-cpan-dist","last_synced_at":"2026-02-18T22:36:51.554Z","repository":{"id":37499642,"uuid":"160285387","full_name":"rlauer6/make-cpan-dist","owner":"rlauer6","description":"Creates a CPAN distribution","archived":false,"fork":false,"pushed_at":"2025-10-06T13:00:16.000Z","size":242,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-22T07:08:58.124Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"M4","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rlauer6.png","metadata":{"files":{"readme":"README.md","changelog":"ChangeLog","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2018-12-04T02:37:52.000Z","updated_at":"2025-10-06T13:00:13.000Z","dependencies_parsed_at":"2023-11-19T16:25:33.068Z","dependency_job_id":"6598c9fb-ebbe-44fa-b71e-dbf075b1c609","html_url":"https://github.com/rlauer6/make-cpan-dist","commit_stats":null,"previous_names":[],"tags_count":30,"template":false,"template_full_name":null,"purl":"pkg:github/rlauer6/make-cpan-dist","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rlauer6%2Fmake-cpan-dist","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rlauer6%2Fmake-cpan-dist/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rlauer6%2Fmake-cpan-dist/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rlauer6%2Fmake-cpan-dist/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rlauer6","download_url":"https://codeload.github.com/rlauer6/make-cpan-dist/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rlauer6%2Fmake-cpan-dist/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29597270,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-18T22:25:43.180Z","status":"ssl_error","status_checked_at":"2026-02-18T22:25:42.766Z","response_time":162,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-10-22T07:02:02.947Z","updated_at":"2026-02-18T22:36:51.531Z","avatar_url":"https://github.com/rlauer6.png","language":"M4","funding_links":[],"categories":[],"sub_categories":[],"readme":"# README\n\n![badge](https://github.com/rlauer6/make-cpan-dist/actions/workflows/build.yml/badge.svg)\n\nThis project is yet another attempt to create a repeatable, __easy to\nuse__ script for creating CPAN distributions.\n\n# Table of Contents\n\n* [README](#readme)\n* [Overview](#overview)\n* [Quick Start](#quick-start)\n* [More Details](#more-details)\n* [Perl Dependencies](#perl-dependencies)\n* [What Next?](#what-next)\n* [Creating a CPAN Distribution](#creating-a-cpan-distribution)\n  * [The Easy Way](#the-easy-way)\n    * [Additional Build Specification Options](#additional-build-specification-options)\n  * [The Harder Way](#the-harder-way)\n  * [The Hardest Way](#the-hardest-way)\n* [FAQ](#faq)\n  * [Why is this easier than just building a `Makefile.PL` by using `ExtUtils::MakeMaker`?](#why-is-this-easier-than-just-building-a-makefilepl-by-using-extutilsmakemaker)\n  * [Why is there a bash script AND a Perl script](#why-is-there-a-bash-script-and-a-perl-script)\n  * [Why did you _autoconfiscate_ a project that has just 1 Perl script and 1 bash script](#why-did-you-autoconfiscate-a-project-that-has-just-1-perl-script-and-1-bash-script)\n  * [Where do files in the `extra_files` section end up?](#where-do-files-in-the-extrafiles-section-end-up)\n  * [How can I add some post installation operations?](#how-can-i-add-some-post-installation-operations)\n* [Module Versions](#module-versions)\n* [Finally](#finally)\n* [Author](#author)\n\n# Overview\n\nHistorically, because I have been using the Redhat Package Manager to\ncreate RPMs of Perl modules I install as part of my\napplication stacks, I don't bother with the creation of CPAN\ndistributions.\n\nIn order to possibly share some of these modules and to use a more\nmodern Perl toolchain (`cpanm`) to vendor libraries, I've needed a\nquick and easy CPAN distribution creation utility compatible with my\nexisting toolchain.  Hence this project.\n\nYou can read more about this utility\n[here](src/main/perl/lib/README.md). Or after installing the project:\n\n```\nmake-cpan-dist.pl -h\nperldoc CPAN::Maker\n```\n\n[Back to Table of Contents](#table-of-contents)\n\n# Quick Start\n\n```\ncpanm -v CPAN::Maker\nmake-cpan-dist.pl -h\n```\n\nIf you want to install this by building the project make sure you have\nthe `autotools` toolchain installed (`autoconf` and `automake`). If\nyou are using a RedHat derived Linux distribution, install the\n`autoconf` and `automake` packages using `yum`. If you are using a\nDebian based system then you may have success using `apt` to install\nthe necessary dependencies. There are also some Perl module\ndependencies that are checked when you run `./configure`.\n\nThe `build` script in the root directory attempts to build the\nsoftware for several different Linux distro flavors.\n\n```\ngit clone https://github.com/rlauer6/make-cpan-dist\ncd make-cpan-dist\n./build\n```\n\nIf you want to do this in pieces take a look at the [build\nscript](build).\n\nThe build script essentially does the following after installing\ndependencies:\n\n```\n./bootstrap\n./configure\nmake \u0026 make install\n```\n\n\u003e HINT: If you want to install locally, set `--prefix` during the\n\u003e configure process or update the `build` script.\n\n```\n./configure --prefix=$HOME/local\nmake \u0026\u0026 make install\n```\n\n[Back to Table of Contents](#table-of-contents)\n\n# More Details\n\nThe goal of the project is to take a set of Perl modules, scripts and\npossibly (hopefully) tests and _automatically_ create a CPAN\ndistribution.  The _automatic_ part is key, as I'd like this to simply\nbe part of a CI/CD pipeline for various projects. The idea would be to\ncreate and include in the project a build specification file for\ncreating CPAN distributions.\n\nTo be clear, __this utility will not do everything you can do by using\n`ExtUtils::MakeMaker` and passing it all of the appropriate\narguments.__  It does enough though to be a very useful\ntool for automating your builds and creating a CPAN tarball.\n\nIf you run into limitations or bugs I'd appreciate an issue being opened\nto let me know why and possibly how I might add new features to make\nit more applicable to a wider set of scenarios.  As the kids say,\n_pull requests are welcome too_.\n\n# Perl Dependencies\n\nOne of the challenging aspects of developing Perl applications is\npackaging and deploying your code.  Part of that process involves\nidentifying all of the Perl modules you've installed from CPAN to use\nin your application.  Once you've identified all of the artifacts\nnecessary to include in your package (so your application will run\nsomewhere other than your laptop) you need to package those up\nsomehow. At the very least you need to create a manifest that\ncan be used when your application is installed.\n\nIdentifying non-core Perl modules required by your application can be\ndone manually by:\n\n* inspecting each Perl module and finding where you `use` or `require` a module.\n* determining the version of that module that has been tested with your\napplication\n* determining if that module version was core in the Perl version your\napplication will running on or it needs to be installed\n\n\u003e `perl` provides a utility (`corelist`) which will report the version\n\u003e of `perl` that a particlular module was added or removed from core.\n\u003e Make sure you have an updated version of `corelist` installed!\n\nThis project uses the `scandeps-static.pl` utility to resolve\ndependencies. this utility is distributed with the\n[Module::ScanDeps::Static](https://metacpan.org/pod/Module::ScanDeps::Static)\nPerl module. It is a rewrite of `perl.req` found in RedHat systems.\n\nI've found it to do a better job than `scandeps.pl` or any of the\nother dependency resolvers you might stumble across.  That's not to\nsay that it is fool proof or even the best dependency checker for\nPerl.  That is a subject of a long blog post I think I should write\nsome day. Oh wait I did...\n\n[Perl Dependency Checking](http://blogs.perl.org/users/rlauer/2019/01/perl-dependency-checking.html)\n\nIf you don't want to use that utility but have another favorite Perl\nmodule dependency resolver then you're free to use that by providing\nit on the command line (-r) of the `bash` helper script\n(`make-cpan-dist`) or in the build specification. The function you\nspecify should simply provide a list of Perl modules one per line and\noutput that to STDOUT.\n\nYou can replace the use of `scandeps-static.pl` with `scandeps.pl` by\nspecifying the `-s` option to the helper script.\n\nOther competing dependency checkers include:\n\n* `Devel::Modlist`\n* `Perl::PrereqScanner`\n\n...all of which will give about the same results as `scandeps.pl`\n\nIf you use any of those other checkers, wrap them in a script to make\nsure they output the list in the correct format.\n\n```\ncat \u003c\u003ceof \u003e dep_resolver\n#!/bin/bash\n\nperl -MDevel::Modlist=nocore \\$1.pm 2\u003e\u00261 | awk '{ print \\$1}'\neof\n\nchmod +x dep_resolver\nmake-cpan-dist -a 'Rob Lauer \u003crlauer6@comcast.net\u003e' \\\n   -m MyFunc -R no -l . -d \"my function\" \\\n   -r dep_resolver\n```\n\n[Back to Table of Contents](#table-of-contents)\n\n# What Next?\n\nAfter successfully building and installing the project you will have\navailable two utilities that are used together to build a CPAN\ndistribution.\n\n* `make-cpan-dist`\n* `make-cpan-dist.pl`\n\nWhen using a buildspec file you need only be concerned with\n`make-cpan-dist.pl` and simply pass the buildspec file as a parameter.\n\n```\nmake-cpan-dist.pl -b buildspec.yml\n```\n\n[Back to Table of Contents](#table-of-contents)\n\n# Creating a CPAN Distribution\n\nThere are three possible ways to create a CPAN distribution using the\nutiities contained in this project, each with varying degrees of\nsimplicity and flexibility.  As a reminder, the point of these\nutilities is to provide a __simple__ solution right?  So the\n_simplest_ thing you can do is run the utility against a\n`buildspec.yml` file that describes the distribution you would like to\ncreate.\n\n[Back to Table of Contents](#table-of-contents)\n\n## The Easy Way\n\nCreate a `buildspec.yml` file that looks something like this:\n\n```\nproject:\n  git: https://github.com/rlauer6/perl-Amazon-Credentials.git \n  description: \"AWS credentials discoverer\"\n  author:\n    name: Rob Lauer\n    mailto: rlauer6@comcast.net\npm_module: Amazon::Credentials\npath:\n  pm_module: src/main/perl/lib\n  tests: src/main/perl/t\n  exe_files: src/main/perl/bin\n```\n\nYou specify some project metadata in the `project:` section and\npossibly a pointer to the project in a git repository that will be\ncloned.\n\nYou must also provide the name of the Perl module to package\n(`pm_module`) and include a `path:` section that will point to the\nmodules and artifacts to be packaged.\n\nThe `path` attributes specify the path to the module, the path to the\ntests and the path to executable scripts which will be included in\nthe distribution.  All files with an extension of `.t` are assumed to\nbe included in the package if you have specified a test path.\n\nIf your project includes other Perl modules somewhere in the\nPerl module path then they will be packaged as well.  Paths are relative\nto the root of the project or your current working directory if you\nare not specifying a git repository as the source of your\npackage.\n\nIf your project includes Perl scripts, you can add those to your\ndistribution by setting the path to those with the `exe_files` and\n`scripts` subsection of `path`.  These will be packaged and installed\nin the `bin` directory (INSTALLBIN).\n\nSo, assuming you have created an appropriate\n`buildspec.yml` file, the easy way boils down to this:\n\n```\nmake-cpan-dist.pl -b buildspec.yml\n```\n\nAfter executing that statement, you should have a tar ball in your\ncurrent working directory.\n\n[Back to Table of Contents](#table-of-contents)\n\n### Additional Build Specification Options\n\nThe build specification file can contain some additional options to\ncontrol what and how things get packaged.\n\n* use the `recurse` option to add additional Perl modules from your\n  project path. If you want to add additional Perl modules to the\n  distribution, just make sure they are under the directory path of\n  your core module and the `recurse` option is set to `yes`. _Actually\n  this is the default.  If you don't want to recurse, set this to\n  *no*._\n\n   ```\n   path:\n     recurse: yes\n   ```\n\n* to use a different module dependency checker than the default\n  (`scandeps-static.pl`) set the `resolver` option under the\n  `dependencies` section. A value of `scandeps` will use `scandeps.pl`\n  or set the name of an executable that will simply output\n  a list of Perl module names.\n\n  ```\n  dependencies:\n    resolver: scandeps\n  ```\n\n* to manually specify a list of dependencies, set the `requires` option\n  under the `dependencies` section to the path to a file that contains\n  a list of Perl modules. If the name of the file is `cpanfile` then\n  it is assumed to be a `cpanfile` formatted list, otherwise the list\n  should be a simple listing of module names optionally followed by a\n  version (e.g. `List::Util 1.5`). By default core modules will be\n  filtered from the list of modules.\n  \n  Include the option `core_modules` with a value of _yes_ if you do\n  not want to filter out core modules.\n\n  ```\n  min_perl_version: 5.16.3\n  dependencies:\n    requires: requires\n    core_modules: yes\n  ```\n\n  If you filter out core modules be aware that you may still require a\n  specific version of a module that is core. Take `List::Util` for\n  example.  This module has been in core since v5.7.3, however the\n  functions `zip` and `mesh` were not added until March of 2021. If\n  you were running on a system that installed only the core modules\n  for v5.16.3 you would find that the version of `List::Util` is 1.27\n  and does not include those functions.\n  \n  So, if you want to filter out core modules but need to include a\n  core module with a specific version, place a + in front of the\n  module name (e.g. `+List::Util 1.5`) in your `requires` file.\n\n  You should also include the minimum version of `perl` that is going to\n  be used to determine if a module is core.  The default is\n  $PERL_VERSION (the version of perl in your environment) which may\n  not be the same version as your target deployment environment!\n\n[Back to Table of Contents](#table-of-contents)\n\n## The Harder Way\n\nA slighly harder way is to call the helper bash script directly with\nspecific options to create the distribution.\n\n```\nusage: make-cpan-dist Options\n\nUtility to create a CPAN distribution. See 'man make-cpan-dist'\n\nOptions\n-------\n-a author      - author (ex: Anonymouse \u003canonymouse@example.org\u003e)\n-b buildspec   - use a buildspec file instead of options\n-d description - description to be included CPAN\n-D file        - use file as the dependency list\n-e path        - path for extra .pl files to package\n-h             - help\n-f file        - file containing a list of extra files to include\n-l path        - path to Perl modules\n-m name        - module name\n-o dir         - output directory (default: current directory)\n-p             - preserve Makefile.PL\n-P file        - file that contains a list of modules to be packaged\n-r pgm         - script or program to list dependencies\n-s             - use scandeps.pl to find dependncies\n-R yes/no      - recurse directories for files to package (default: yes)\n-t path        - path to test files\n-v             - more verbose output\n-V             - version from\n-x             - do not cleanup files\n\nNOCLEANUP=1, PRESERVE_MAKEFILE=1 can also be passed as environment variables.\n```\n\nExample:\n\nAssuming your source tree looks something like this:\n\n```\n.\nlib/\nlib/Foo\nlib/Foo/Bar.pm\nt/\n```\n\n...then...\n\n```\nmake-cpan-dist -l lib -t t -m Foo::Bar\n```\n\nSo far, neither of these methods is particularly hard and can be used\ninterchangeably as part of your deployment pipeline.  The key to the\n\"easiness\" part, at least for me, is the fact that the `bash` script\nwill try to resolve dependencies using the selected dependency resolver\nand find the Perl module version for each of those\ndependencies.  The __dependency resolver is not perfect__,\nspecifically it may get tripped up on some ways your clever Perl\nmodule utilizes other resources.  In general though, _it's good\nenough_.  You you can always ask the script to preserve (`-p`) the\n`Makefile.PL` that is generated and start tweaking that yourself. You\ncould also open an issue and I'll try to tackle it. You could also\nmake a pull request. ;-)\n\n[Back to Table of Contents](#table-of-contents)\n\n## The Hardest Way\n\nThe hardest way to create a CPAN distribution using this utility is to\nprovide the dependency files for your module by creating them yourself\nand then calling `make-cpan-dist.pl` directly to create a\n`Makefile.PL` file that you can then modify.\n\nThe dependency files list the module name and their version (or 0).\nFor example:\n\n```\nAmazon::Signature4 1.02\n```\n\nAt this point you have pretty much decided to roll your own\n`Makefile.PL` so have fun with [`ExtUtils::MakeMaker`](https://metacpan.org/pod/ExtUtils::MakeMaker).\n\nTo summarize what the `bash` helper script does, all of which you can\nof course do manually, the script will:\n\n1. iterate over all of the `.pm` files in your source tree\n   1. run a dependency checker and save the output\n1. sort the list and get the unique dependencies\n1. separate out the dependencies from the modules provided by your project\n1. iterate over the sorted list of dependencies\n   1. retrieve the version number of each module\n   1. save the module and version number to the dependency file\n1. repeat for each test (*.t) in the test directory\n1. repeat for the each script in your script directory\n\nThe result of the above operation is a set of files:\n* `requires`\n* `test-requires`\n* `provides`\n\nThese files are eventually used by the `make-cpan-dist.pl` script to\ncreate your final `Makefile.PL`.\n\n[Back to Table of Contents](#table-of-contents)\n\n# FAQ\n\n## Why is this easier than just building a `Makefile.PL` by using `ExtUtils::MakeMaker`?\n\nWell, to be upfront about it, __maybe it's not__, especially for\nsmaller projects. Using the buildspec approach does make it\nparticulary easy though. And as your project grows modifying the\nbuildspec file is probably easier than remembering how\n`ExtUtils::MakeMaker` works.  \n\nMoreover, I feel this approach makes automation easier. I alway find\nit best to take a bunch of steps I will seldom remember and package\nthem into self-contained utilities that can be forgotten about.  This\napproach works for me, but as always YMMV. As I mentioned, I'm also\nusing this utility as a component of a CI/CD pipeline. Here's an\n[example](cpan/Makefile.am) of using this utility with a [buildspec\nfile](cpan/buildspec.yml) in a `Makefile`.\n\nFor a real simple project whose file hierarchy looks like this:\n\n```\nChangeLog\nREADME.md\nlib/Foo/Bar.pm\nlib/Foo/Bar/Baz.pm\nbin/foo.pl\nt/00-foo.t\n```\n\n...your buildspec file might look like this:\n\n```\nproject:\n  description: \"My awesome project\"\n  author:\n    name: Your Name\n    mailto: anonymouse@example.org\npm_module: Foo::Bar\nextra-files:\n  - README.md\n  - ChangeLog\npath:\n  pm_module: lib\n  tests: t\n  exe_files: bin\n```\n\n..and your `Makefile` like this:\n\n```\nVERSION := $(shell perl -I lib -MFoo::Bar -e 'print \"$$Foo::Bar::VERSION\";')\n\nPROJECT=Foo-Bar-$(VERSION).tar.gz\n\nMODULES = \\\n   lib/Foo/Bar.pm \\\n   lib/Foo/Bar/Baz.pm\n\nSCRIPTS = \\\n   bin/foo.pl\n\n$(PROJECT): buildspec.yml $(MODULES) $(SCRIPTS)\n\tmake-cpan-dist.pl -b $\u003c\n\nCLEANFILES = \\\n    $(PROJECT)\n\nclean:\n\tfor a in $(CLEANFILES); do \\\n\t  rm -f \"$(PROJECT)\"; \\\n\tdone\n```\n\n...which could also be accomplished from the command line:\n\n```\nmake-cpan-dist -l lib -S bin -t t -m Foo::Bar\n```\n\nBy creating a `Makefile` recipe, whenever I update the buildspec or\nany of the modules or scripts and run `make`, I'll automatically\ncreate a new distribution.\n\n[Back to Table of Contents](#table-of-contents)\n\n## Why is there a bash script AND a Perl script\n\nIf you find yourself scratching your head and wondering if\nindeed the `bash` script calls the Perl script and vice versa, you are\ncorrect.\n\nThe Perl script has two purposes:\n\n1. parse the buildspec into options that are sent to the bash script \n1. write a `Makefile.PL` based on the options sent to it by the bash\n  script\n  \nThe bash script finds your artifacts to be packaged, Perl module\ndependencies and calls the Perl script to write the `Makefile.PL`. In\nthe beginning I think I created a bash script that did all of the\nheavy lifting but later found I needed a more powerful environment for\nenhancing the script.\n\n[Back to Table of Contents](#table-of-contents)\n\n## Why did you _autoconfiscate_ a project that has just 1 Perl script and 1 bash script\n\nBefore we go any further, I'll bet I need to answer that question.\nSo, in no particular order...\n\n* Habit\n* Automation malleability\n* Familiarity with the toolchain\n* Standardization of my development process\n* Flexibility to add more automation with `make` as a project organically matures\n* Ubiquity of the toolchain\n* Potential portability (nothing is 100% portable, but we can try)\n\nI also leverage _autoconfiscation_ templates to create things like man\npages from Perl scripts and of course the installation process is made\nsimpler when you can rely on some degree of portability and\nstandardization of your toolchain. Many disagree and hate `autoconf` -\nI get it - but it's not a holy war.\n\nTake a look at\n[autoconf-template-perl](https://github.com/rlauer6/autoconf-template-perl)\nif you are curious about how to _autoconfiscate_ a Perl project.\n\n[Back to Table of Contents](#table-of-contents)\n\n## Where do files in the `extra_files` section end up?\n\nFiles in the `extra-files` section of the `buildspec.yml` file or in\nthe `extra-files` file are packaged as part of the distribution\ntarball but will not be installed _unless you add them to the `share:`\nsection beneath `extra-files`.  In that case they will be installed\nrelative to the distribution's share directory.\n\n```\nextra-files:\n  - share:\n    - ChangeLog\n    - README.md\n```\n\nYou can find out where the distribution's share directory is as shown\nbelow.\n\n```\nperl -MFile::ShareDir=dist_dir -e 'print dist_dir(\"Foo\"),\"\\n\";'\n```\n\n[Back to Table of Contents](#table-of-contents)\n\n## How can I add some post installation operations?\n\n[ExtUtils::MakeMaker](https://metacpan.org/pod/ExtUtils::MakeMaker)\nprovides the capability to add an additional step to your build or\ninstallation process by providing a `postamble`\nsection. `make-cpan-dist.pl` supports this by allowing you to add a\nsection to your `buildspec.yml` file which specifies the name of a\nfile containing the extra `make` instructions that will be executed\nafter the build and before the installation. A typical postamble file\nmight look like this:\n\n```\n postamble ::\n \n .PHONY: FOO\n FOO:\n    echo \"Thanks for using FOO!\"\n\ninstall:: FOO\n```\n\n[Back to Table of Contents](#table-of-contents)\n\n# Module Versions\n\nIt's sometimes convenient to keep a project's version in a file other\nthan main Perl module. You might do this for example if you have\nseveral modules in the distribution and you want them all to reflect\nthe same version number. If you decid to keep your project's version\nin a file other than the main module, you can specify the `-V` option\nto the bash script or add `version_from:` in your buildspec.\n\n```\npackage Foo::Bar::VERSION;\n\nour $VERSION = '1.0.1';\n\n1;\n```\n\n```\npackage Foo::Bar;'\n\nrequire Foo:Bar::VERSION;\n\n1;\n```\n\n...then\n\n```\nmake-cpan-dist -l lib -t t -S bin -m Foo::Bar -V Foo::Bar::VERSION\n```\n\n[Back to Table of Contents](#table-of-contents)\n\n# Finally\n\nI hope you find this useful. If I can make it more useful, let me\nknow.\n\n# Author\n\nRob Lauer \u003crlauer6@comcast.net\u003e\n\n[Back to Table of Contents](#table-of-contents)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frlauer6%2Fmake-cpan-dist","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frlauer6%2Fmake-cpan-dist","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frlauer6%2Fmake-cpan-dist/lists"}