Maybe Not So Hard Pdir Question

Feb 25, 2011
My almost dream directory listing is aliased as:

pdir /(-20.20fnq) /( dd-m-y th:m zc -i) * /D/K/M/Og/P

This gives both long filenames and descriptions. Don't like long names, but they are an unfortunate fact of life now.

Maybe someone can suggest a way to implement the following changes:

1) I'd like to separately left justify the filenames and prefixes, separated by space(s) and no dot. This functionality is available with /J in dir, but apparently not in pdir. And even if it was, /J uses shortened names. Undoubtedly there are TCC functions that parse filenames and put them back together in the desired format, but I have not mastered this arcane art.

2) When a long description wraps, the tail starts at the beginning of the next line. Is there a convenient way to line up the wrap with the first column of the description field?

Thanks in advance.
Jan 19, 2011
Norman, OK
Here are some parsing commands added to part 1) of your question.

Filenames and extensions will be truncated to 20 and 4 characters, respectively, if they are longer. In addition from my own testing, filenames longer than 19 characters with spaces in them will be truncated to 19 characters with a leading quote but no trailing quote.
pdir /(-20.20@quote[%%@name[*]]) /(-4.4@ext[*]) /( dd-m-y th:m zc -i) * /D/K/M/Og/P
Similar threads
Thread starter Title Forum Replies Date
G FOLDERMONITOR created also firing for delete (and maybe other events) Support 7
M Maybe Maybe I'm being stupid (again), but a simple question... Support 4
M Is this a restriction I wasn't aware of or something new (that maybe shouldn't be there)? Support 16
M How to do now or maybe a request for new functionality Support 3
R TCC IDE Tabs - inactive tabs hard to see Support 14
B Disk usage and hard links Support 16
C Attaching PowerShell changes its colors and makes it hard to read Support 15
S Hard links - detecting their presence Support 2
J Two hard to reproduce errors Support 0
Phileosophos PDIR to list filenames without extensions? Support 2
vefatica PDIR and streams Support 1
vefatica PDIR with fixed-width unqualified filename? Support 2
W pdir returns diff results between tcc and tcmd - one is an error msg Support 5
thedave pdir /s Support 2
Emilio III pdir /f switch Support 1
D pdir ignores pm Support 2
WadeHatler pdir broken in 19.1 for directories with spaces Support 1
M WAD PDir not working correctly... Support 5
vefatica WAD Nested variable expansion in PDIR's @function[*]? Support 13
mfarah More on pdir's options: /(fq) Support 5
mfarah How to? Getting pdir to display relative paths. Support 2
S PDIR and @LABEL questions Support 4
M How to? PDir on multiple wildcard patterns... Support 2
A pdir function usage Support 3
T How to? dir/pdir - 2nd level down only Support 7
JohnQSmith PDIR and descriptions Support 21
G WAD PDIR @IF bug, @WORD bug Support 8
S WAD PDIR: files with percent sign % in name cause not listing other files in directory Support 9
S WAD PDIR ignores exclusion ranges Support 1
M PDir format question... Support 3
M How to? "PDir" not working the way the I _thought _ the documentation said it does… Support 8
S WAD /Sn mishandled in DIR and PDIR, possibly elsewhere Support 15
S Fixed GPF in PDIR Support 3
S PDIR issue Support 1
M PDir causing Take Command/TCC to crash... Support 6
M A "PDir" issue... Support 16
M A simple question related to the "dir" (and "pdir") commands... Support 5
J pdir /b1 issue Support 20
M Missing PDir option... Support 5
S PDIR fails in 12.10.55 Support 3
J V12 PDIR failure Support 1
S PDIR command causes GPF Support 5
D pdir inconsistency Support 4
S PDIR has trouble processing filenames with embedded percent sign Support 3
P PDIR woes Support 0
gschizas pdir crashes horribly in one specific folder Support 5
S PDIR question Support 2
S pdir /(fq) not working Support 5
R Colored directory listing bug with pdir. Support 1
nickles Bias in PDIR Support 5

Similar threads