Skip to content

Commit 708b8cc

Browse files
committed
am -i: fix "v"iew
The 'v'iew subcommand of the interactive mode of "git am -i" was broken by the rewrite to C we did at around 2.6.0 timeframe at 7ff2683 (builtin-am: implement -i/--interactive, 2015-08-04); we used to spawn the pager via the shell, accepting things like PAGER='less -S' in the environment, but the rewrite forgot and tried to directly spawn a command whose name is the entire string. The previous refactoring of the new helper function makes it easier for us to do the right thing. Signed-off-by: Junio C Hamano <[email protected]>
1 parent 3e3a4a4 commit 708b8cc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

builtin/am.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1740,7 +1740,7 @@ static int do_interactive(struct am_state *state)
17401740

17411741
if (!pager)
17421742
pager = "cat";
1743-
argv_array_push(&cp.args, pager);
1743+
prepare_pager_args(&cp, pager);
17441744
argv_array_push(&cp.args, am_path(state, "patch"));
17451745
run_command(&cp);
17461746
}

0 commit comments

Comments
 (0)