diff options
author | Thierry Vignaud <thierry.vignaud@gmail.com> | 2014-09-15 14:35:21 +0200 |
---|---|---|
committer | Thomas Backlund <tmb@mageia.org> | 2014-09-15 18:20:59 +0300 |
commit | 5df8882f69673744a2dc20124e898037b1e824da (patch) | |
tree | dbb23d5bc697956084696e49c37f926884904020 /perl.req-from-meta | |
parent | 2680d325941a26981f766e6c879ce3dc64a9db4f (diff) | |
download | rpm-setup-5df8882f69673744a2dc20124e898037b1e824da.tar rpm-setup-5df8882f69673744a2dc20124e898037b1e824da.tar.gz rpm-setup-5df8882f69673744a2dc20124e898037b1e824da.tar.bz2 rpm-setup-5df8882f69673744a2dc20124e898037b1e824da.tar.xz rpm-setup-5df8882f69673744a2dc20124e898037b1e824da.zip |
retrieve file name from stdin
Diffstat (limited to 'perl.req-from-meta')
-rwxr-xr-x | perl.req-from-meta | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/perl.req-from-meta b/perl.req-from-meta index 3105259..a38244a 100755 --- a/perl.req-from-meta +++ b/perl.req-from-meta @@ -7,7 +7,8 @@ use JSON qw{ from_json }; use YAML qw{ Load }; # slurp the file -my $path = shift; +my $path = <>; +chomp($path); open my $fh, '<', $path or die "can't open $path: $!"; my $data = do { local $/; <$fh> }; close $fh; |