From: Junio C Hamano Date: Sun, 17 May 2020 15:07:41 GMT Subject: Re: [PATCH v3] diff: add config option relative Message-ID: In-Reply-To: <92cb6302-09a8-6780-9398-890b1e766680@gmail.com> Phillip Wood writes: >> @@ -5494,6 +5501,9 @@ static void prep_parse_options(struct diff_options *options) >> N_("when run from subdir, exclude changes outside and show relative paths"), >> PARSE_OPT_NONEG | PARSE_OPT_OPTARG, >> diff_opt_relative), >> + OPT_SET_INT_F(0, "no-relative", &options->flags.relative_name, >> + N_("disable diff.relative config option"), >> + 0, PARSE_OPT_NONEG), > > Rather than adding a new option, it would be better to modify the > existing --relative option. If you remove PARSE_OPT_NONEG from the > declaration above it will support --no-relative. You will also need to > modify diff_opt_relative() to handle clearing the option. Excellent.