開発時用のNodeモジュールをPerlでアップデートする

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
#!/usr/bin/env perl
use utf8;
use 5.012;

use JSON::XS qw(decode_json);
use Path::Tiny qw(path);

my $json = decode_json(path('package.json')->slurp);
my $modules = join(' ', keys $json->{devDependencies});
system(qq{npm install -D $modules});

Comments

comments powered by Disqus