.hgtags
author Daniel Kobras <kobras@debian.org>
Thu, 15 Dec 2005 15:40:14 +0100
changeset 1587 851bc33ff545
parent 1266 703783bc09c4
child 1666 0fc1b588976f
permissions -rw-r--r--
Less annoying directory completion (see http://bugs.debian.org/343458) The current bash completion script is quite painful in conjuntion with deep directory trees because it adds a space after each successful directory completion. Eg. "hg clone /ho<tab>" is completed to "hg clone /home " when what you really want is "hg clone /home/" (assuming the complete path to the repository looks like /home/foo/hg...). That's because the 'complete' command does not know about the type of completion it receives from the _hg shell function. When only a single completion is returned, it assumes completion is complete and tells readline to add a trailing space. This behaviour is usually wanted, but not in the case of directory completion. I've attached a patch that circumvents this problem by only returning successful completions for directories that contain a .hg subdirectory. If no repositories are found, no completions are returned either, and bash falls back to ordinary (filename) completion. I find this behaviour a lot less annoying than the current one. Alternative: Use option nospace for the 'complete' command and let _hg itself take care of adding a trailing space where appropriate. That's a far more intrusive change, though.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
66
5ec8b2ed858f Beginnings of changelog tagging
mpm@selenic.com
parents:
diff changeset
     1
d40cc5aacc31ed673d9b5b24f98bee78c283062c 0.4f
5ec8b2ed858f Beginnings of changelog tagging
mpm@selenic.com
parents:
diff changeset
     2
1c590d34bf61e2ea12c71738e5a746cd74586157 0.4e
5ec8b2ed858f Beginnings of changelog tagging
mpm@selenic.com
parents:
diff changeset
     3
7eca4cfa8aad5fce9a04f7d8acadcd0452e2f34e 0.4d
5ec8b2ed858f Beginnings of changelog tagging
mpm@selenic.com
parents:
diff changeset
     4
b4d0c3786ad3e47beacf8412157326a32b6d25a4 0.4c
189
37625132fe37 Add tag for 0.5
mpm@selenic.com
parents: 66
diff changeset
     5
f40273b0ad7b3a6d3012fd37736d0611f41ecf54 0.5
194
4ec26766be83 Update tags
mpm@selenic.com
parents: 189
diff changeset
     6
0a28dfe59f8fab54a5118c5be4f40da34a53cdb7 0.5b
458
ff8fbf99cd64 Added tag 0.6 for changeset 12e0fdbc57a0be78f0e817fd1d170a3615cd35da
mpm@selenic.com
parents: 194
diff changeset
     7
12e0fdbc57a0be78f0e817fd1d170a3615cd35da 0.6
685
79fb7032739f Added tag 0.6b for changeset 4ccf3de52989b14c3d84e1097f59e39a992e00bd
Matt Mackall <mpm@selenic.com>
parents: 458
diff changeset
     8
4ccf3de52989b14c3d84e1097f59e39a992e00bd 0.6b
972
0bc72d91aeda Added tag 0.6c for changeset eac9c8efcd9bd8244e72fb6821f769f450457a32
mpm@selenic.com
parents: 685
diff changeset
     9
eac9c8efcd9bd8244e72fb6821f769f450457a32 0.6c
1266
703783bc09c4 Added tag 0.7 for changeset 979c049974485125e1f9357f6bbe9c1b548a64c3
mpm@selenic.com
parents: 981
diff changeset
    10
979c049974485125e1f9357f6bbe9c1b548a64c3 0.7