X-Git-Url: https://git.madduck.net/code/myrepos.git/blobdiff_plain/e660714cc8dc3848bc7c7386e7f0e64adf14dbd0..4b6f84321972510b5422bb80ef2f2d81f4b33a4c:/mr diff --git a/mr b/mr index be2bac6..dba54cc 100755 --- a/mr +++ b/mr @@ -152,6 +152,11 @@ C. You can retrieve the config file by other means and pass its B as C. +=item standard input + +If source C consists in a single dash C<->, config file is read from +standard input. + =back The directory will be created if it does not exist. If no directory is @@ -1715,6 +1720,10 @@ sub bootstrap { if $downloader[0] eq 'curl' && $status >> 8 == 60; die "mr bootstrap: download of $src failed\n" if $status != 0; } + elsif ($src eq '-') { + # Config file is read from stdin. + copy(\*STDIN, $tmpconfig) || die "stdin: $!"; + } else { # Config file is local. die "mr bootstrap: cannot read file '$src'"