Windows File List

Viewing a list of all file in a directory on windows without all the timestamps etc was a pain in the arse untill I looked into it.
dir /b /a-D > filelist.txt
Job Done :)

3 Comments

  1. Frank
    Posted October 3, 2005 at 1:17 pm | Permalink

    Then it seems plain to me that you did not know what a computer was before Windows 95.

    Any Dos junkie worth his salt would had that done for ya in seconds!!!

  2. Posted October 3, 2005 at 5:07 pm | Permalink

    True, I should have known this. I just could’t remember all the flags that could be passed. I could do it in Linux in a second though

    find * -type f -maxdepth 0 > filelist.txt

    or

    ls -1 -p | grep -v “/” > filelist.txt

    I tell a lie, I had to look that up too :(

  3. Posted October 24, 2005 at 10:30 am | Permalink

    Also to just list the directories

    ls -l | grep “^d”

    and

    ls -d */

Post a Comment

Your email is never published nor shared. Required fields are marked *
*
*