tab completion with directory commands

  • This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.
May 26, 2008
484
4
#2
At the TCC prompt, type OPTIONS to bring up the options dialog.

Go to the Command Line tab and look in the Filename Completion frame.

In the Options text box, enter something like this:

Code:
cd md rd:DIRS;
This will cause the cd, md, and rd commands to only complete directories.
 
#4
I read the topic above, and my problem is that no matter what I do, I can't get my folders to appear in the unsorted order I want. I am looking at a network share to which I have mapped a drive, u:. When I enter dir u: /o:u, it always ends up with "VESTA Map" before VESTA. (I want VESTA completed first.) I've tried creating a new folder that lists after VESTA and then moving all of the contents of "VESTA Map" into that new folder, then deleting "VESTA Map" and finally renaming the new folder to "VESTA Map", and all of a sudden, dir u: /o:u lists "VESTA Map" first again.

Am I doing something wrong? Or is there some way to force its completion to go in alphabetical order (since a regular dir lists VESTA first)?
 
May 26, 2008
484
4
#5
Filename completion options being discussed in this thread have nothing to do with DIR sort order.

That being said, I too notice that *dir /o:u still seems to sort everything alphabetically on my system. Not sure if that's a functional change in the operating system APIs (I'm running on Windows 7) or what.
 

rconn

Administrator
Staff member
May 14, 2008
10,291
90
#6
Filename completion options being discussed in this thread have nothing to do with DIR sort order.

That being said, I too notice that *dir /o:u still seems to sort everything alphabetically on my system. Not sure if that's a functional change in the operating system APIs (I'm running on Windows 7) or what.
NTFS always keeps files in alphabetical order.
 

rconn

Administrator
Staff member
May 14, 2008
10,291
90
#7
I read the topic above, and my problem is that no matter what I do, I can't get my folders to appear in the unsorted order I want. I am looking at a network share to which I have mapped a drive, u:. When I enter dir u: /o:u, it always ends up with "VESTA Map" before VESTA. (I want VESTA completed first.) I've tried creating a new folder that lists after VESTA and then moving all of the contents of "VESTA Map" into that new folder, then deleting "VESTA Map" and finally renaming the new folder to "VESTA Map", and all of a sudden, dir u: /o:u lists "VESTA Map" first again.

Am I doing something wrong? Or is there some way to force its completion to go in alphabetical order (since a regular dir lists VESTA first)?
Filename / directory completion is always in the order the file system returns them (alphabetic on an NTFS drives; other file systems will vary). There is no sorting option.
 
May 26, 2008
484
4
#8
NTFS always keeps files in alphabetical order.
Ah. Personally I'm glad for this, and it probably means I no longer have to put DIRCMD=/O to get default sorting in cmd.exe any more! I had been doing that since MS-DOS 6...thru Windows 9x..etc.

Personally I don't understand why someone would want it unsorted.

Regarding Mickey's problem, I created a "VESTA" and "VESTA Map" folder and DIR showed them in the order I would expect: VESTA first.