|
Answer» Is there a way to use the MS-DOS dir command to echo back the containing folder?
So, if I run this: ( c:\dir /s|find "userenv" )
my search eventually locates the "userenv" FILE however I don't know which containing folder has this file. So the output looks like this: ( 03/05/2008 11:02 AM 387,856 userenv.log )
When I WOULD like to have output like this: ( C:\temp\subdirectory userenv.log )use the /b switch which will show the full path
dir /s /b | find "userenv"
I'm curious. Why are you PIPING this to the find command? I got exactly the same output (in the desired format) from:
Code: [SELECT]dir C:\userenv* /s /b as I did from:
Code: [Select]dir C:\ /s /b | find "userenv" and it's less keystrokes.
|