This file is indexed.

/usr/bin/mkdist is in libmodule-package-rdf-perl 0.014-1.

This file is owned by root:root, with mode 0o755.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
#!/usr/bin/perl

eval 'exec /usr/bin/perl  -S $0 ${1+"$@"}'
    if 0; # not running under some shell

use Getopt::ArgvFile
	home => 1,
	current => 1,
	resolveEnvVars => 1;
use Getopt::Long qw[:config permute bundling no_ignore_case no_auto_abbrev];

my %options;

GetOptions(\%options,
	'abstract|A=s',
	'author|a=s%',
	'backpan=s',
	'copyright|c=s%',
	'destination|d=s',
	'dist_maker|D=s',
	'help|usage|h',
	'licence_class|l=s',
	'package_flavour=s',
	'use|M=s@',
	'version|v',
);

$options{dist_maker} = 'App::mkdist';

if ($options{help} || !@ARGV)
{
	print <<'HELP' and exit(1);
mkdist [options] dist_name1 dist_name2 ...

Options:

	--abstract=S, -A=S       Short description for distribution
	--author k=v, -a k=v     Set author data.
	--backpan=S              URL for archives.
	--copyright k=v, -c k=v  Set copyright data.
	--destination=S, -d=S    Output directory.
	--dist_maker=S, -D=S     Class to use to create distribution.
	--help, -h               Show this help.
	--licence_class=S, -l=S  Perl class with licensing data.
	--package_flavour=S      use Module::Package::RDF::$flavour.
	--use S, -M=S            Distribution should use these modules.
	--version=S, -v=S        Initial version number.

Author data keys:

	cpanid            Author's CPAN ID
	mbox              Author's email address
	name              Author's full name

Copyright data keys:

	holder            Copyright holder
	year              Copyright year

The values of "use" are interpreted thusly:

	* 'boolean' avoids defining constants for true and false.
	* 'common_sense' uses common::sense instead of strict/warnings.
	* 'namespace_clean' uses namespace::clean.
	* 'moose' (lowercase) uses Moose and namespace::clean.
	* Other values are interpreted as the names of modules to use.
	* Perl version defaults to 5.010.

license_class defaults to "Software::License::Perl_5".

dist_maker defaults to "App::mkdist", but any package that provides the same
API should work.

package_flavour defaults to 'standard'.

Example:

	mkdist \
		--author name="Toby Inkster" \
		--author cpanid="tobyink" \
		--copyright year=2010 \
		--abstract="does something useful" \
		--use autodie \
		--use boolean \
		--use common_sense \
		--use DateTime \
		--use 5.008003 \
		"Local::Example::Useful"

Frequently used settings can be kept in ~/.mkdist

HELP
}

my $class = delete $options{dist_maker};
eval "use $class 0 qw(); 1;"
	or die "Could not use '$class'.\n";
$class->import;

while (my $dist = shift @ARGV)
{
	$class->create($dist, %options);
}