bin/setup-cpan-faves

changeset 786
63160e727e37
parent 708
3c51616458c8
child 816
f058603b86b6
--- a/bin/setup-cpan-faves
+++ b/bin/setup-cpan-faves
@@ -1,11 +1,7 @@
-#!/usr/bin/env perl
-use warnings;
-use strict;
+#!/bin/bash
+set -eu -o pipefail
 
-exec cpanm => -nq => qw(
-  App::cpanminus
-  Carton
-
+dists=(
   Perl::Tidy
   Pod::Cpandoc
 
@@ -23,4 +19,9 @@ exec cpanm => -nq => qw(
 
   Path::Tiny
   Getopt::Long::Descriptive
-);
+)
+
+command -v cpm &>/dev/null ||
+  cpanm App::cpm
+
+exec cpm install -g "${dists[@]}"

mercurial