X-Git-Url: https://git.madduck.net/code/myrepos.git/blobdiff_plain/2f80d6c39305c42561d5c3a564cbe48d191ccd5c..deb8ddcf307273f8cbf7252e796f6769c83be427:/mr diff --git a/mr b/mr index 8de26f8..a431e8a 100755 --- a/mr +++ b/mr @@ -713,7 +713,7 @@ sub record { if ($interactive) { chdir($dir) unless $no_chdir; print STDERR "mr: Starting interactive shell. Exit shell to continue.\n"; - system((getpwuid($<))[8]); + system((getpwuid($<))[8], "-i"); } push @failed, $dir; print "\n"; @@ -1357,7 +1357,9 @@ sub bootstrap { print STDERR "mr: .mrconfig file already exists, not overwriting with $url\n"; } else { - rename($tmpconfig, ".mrconfig") || die "rename: $!"; + eval q{use File::Copy}; + die $@ if $@; + move($tmpconfig, ".mrconfig") || die "rename: $!"; } exec("mr $ENV{MR_SWITCHES} -c .mrconfig checkout"); @@ -1629,14 +1631,26 @@ hg_trusted_checkout = hg clone $url $repo darcs_trusted_checkout = darcs get $url $repo git_bare_trusted_checkout = git clone --bare $url $repo + help = + case `uname -s` in + SunOS) + SHOWMANFILE="man -f" + ;; + Darwin) + SHOWMANFILE="man" + ;; + *) + SHOWMANFILE="man -l" + ;; + esac if [ ! -e "$MR_PATH" ]; then error "cannot find program path" fi tmp=$(mktemp -t mr.XXXXXXXXXX) || error "mktemp failed" trap "rm -f $tmp" exit pod2man -c mr "$MR_PATH" > "$tmp" || error "pod2man failed" - man -l "$tmp" || error "man failed" + $SHOWMANFILE "$tmp" || error "man failed" list = true config = bootstrap =