Thread (65 messages) 65 messages, 8 authors, 2022-04-06

Re: [PATCH v6 0/3] completion: sparse-checkout updates

From: Elijah Newren <hidden>
Date: 2022-02-04 06:06:11

Hi,

On Thu, Feb 3, 2022 at 7:26 PM Lessley Dennington via GitGitGadget
[off-list ref] wrote:
This change updates custom tab completion for the sparse-checkout command.
Specifically, it corrects the following issues with the current method:

 1. git sparse-checkout <TAB> results in an incomplete list of subcommands
    (it is missing reapply and add).
 2. Options for subcommands are not tab-completable.
 3. git sparse-checkout set <TAB> and git sparse-checkout add <TAB> show
    both file names and directory names. While this may be a less surprising
    behavior for non-cone mode, we want to only show directories in cone
    mode.

The first commit in this series is an intermediate step that fixes issues 1
and 2 above and introduces a simple fix for issue 3 with some performance
and unusual character-related caveats. The next commit adds a new
__gitcomp_directories method that fixes the performance-related caveat from
the first commit by completing just a single level of directories. The final
commit modifies __gitcomp_directories to handle unusual characters in
directory names.


Changes since V5
================

 * Fix incorrect conditional that was causing failure of non-cone mode test
   (and causing 'seen' CI to fail).
 * Remove __git_comp_directories indentation changes between the second and
   third commits.
This round looks good to me:

Reviewed-by: Elijah Newren <redacted>

Nice work!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help