On Fri, May 3, 2013 at 9:06 PM, Jiang Xin <worldhello....@gmail.com> wrote:
> 2013/5/3 Eric Sunshine <sunsh...@sunshineco.com>:
>> More generally, is this sort of modal edit mode desirable and
>> convenient? Can the edit operation be combined with the top-level
>> prompt? For example:
>>
>>   % git clean -i
>>   file1 file2 file3
>>   file4 file5 file6
>>   Remove ([y]es, [n]o, [p]rompt, exclusion-list)? file[4-6]
>>   file1 file2 file3
>>   Remove ([y]es, [n]o, [p]rompt, exclusion-list)? p
>>   file1 (y/n/q/!)? y
>>   file2 (y/n/q/!)? n
>>   file3 (y/n/q/!)? y
>
> What If there is a file named 'y', and the user want to exclude it,
> and press 'y' as a pattern.

The pattern [y] will match file named 'y'. It probably is unusual for
files named 'y', 'n', etc. to exist in the top-level directory, but
the gitignore patterns already provide an escape hatch for these
unusual cases. (That is not to say that this is the perfect example or
solution, but only that it may be worth considering such options when
designing the user-interface for convenience.)
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to