Re: [PATCH v2 01/34] sequencer: support a new action: 'interactive rebase'
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Dec 14, 2016, 19:29 UTC
- Message-ID
- <xmqqy3ziwbpk.fsf@gitster.mtv.corp.google.com>
- In-Reply-To
- <297140020a7312af03136848dcdd0353ee3abdfe.1481642927.git.johannes.schindelin@gmx.de>
Johannes Schindelin <johannes.schindelin@gmx.de> writes:
Show 13 quoted lines
> -/* We will introduce the 'interactive rebase' mode later */
> static inline int is_rebase_i(const struct replay_opts *opts)
> {
> - return 0;
> + return opts->action == REPLAY_INTERACTIVE_REBASE;
> }
>
> static const char *get_dir(const struct replay_opts *opts)
> {
> + if (is_rebase_i(opts))
> + return rebase_path();
> return git_path_seq_dir();
> }This obviously makes the assumption made by 39784cd362 ("sequencer: remove useless get_dir() function", 2016-12-07) invalid, where the "remove useless" thought that the callers of this function wants a single answer that does not depend on opts.
I'll revert that commit from the sb/sequencer-abort-safety topic (as the topic is in 'next' already) to keep this one. Please holler if that is a mistaken decision.
Thanks.