As was foretold, we've added advertisements to the forums! If you have questions, or if you encounter any bugs, please visit this thread: https://forums.penny-arcade.com/discussion/240191/forum-advertisement-faq-and-reports-thread/

Creating a Text List of Files From a Folder?

DarkWarriorDarkWarrior __BANNED USERS regular
I'm interested in creating some txt lists of files I have as I have a lot, mainly the music so that if anything ever happened to the HDD I'd have an idea of what I used to have and could replace them. Is there any program or bat.file code I could use to do this?

DarkWarrior on

Posts

  • ZxerolZxerol for the smaller pieces, my shovel wouldn't do so i took off my boot and used my shoeRegistered User regular
    edited September 2009
    Ultracheap method: "dir > file.txt" on the command line. Use the /s switch to list child subdirectories too if you want.

    Zxerol on
  • PeregrineFalconPeregrineFalcon Registered User regular
    edited September 2009
    dir /b /s > file.txt would work well, and give you just the filenames.

    "tree > file.txt" would give you a directory structure if you've got the music sorted by album/artist/etc, then you just have a list of albums.

    PeregrineFalcon on
    Looking for a DX:HR OnLive code for my kid brother.
    Can trade TF2 items or whatever else you're interested in. PM me.
  • TrentusTrentus Registered User regular
    edited September 2009
    "tree > file.txt" would give you a directory structure if you've got the music sorted by album/artist/etc, then you just have a list of albums.

    Chuck in the /f switch to get the files as well.

    Trentus on
  • PeregrineFalconPeregrineFalcon Registered User regular
    edited September 2009
    Trentus wrote: »
    "tree > file.txt" would give you a directory structure if you've got the music sorted by album/artist/etc, then you just have a list of albums.

    Chuck in the /f switch to get the files as well.

    If you've got a bunch of loose files (downloaded music or whatever) then sure, but artist + album should be enough for commercially ripped CDs.

    Also, good lord, what happened to my name there? D:

    PeregrineFalcon on
    Looking for a DX:HR OnLive code for my kid brother.
    Can trade TF2 items or whatever else you're interested in. PM me.
  • TrentusTrentus Registered User regular
    edited September 2009
    Trentus wrote: »
    "tree > file.txt" would give you a directory structure if you've got the music sorted by album/artist/etc, then you just have a list of albums.

    Chuck in the /f switch to get the files as well.

    If you've got a bunch of loose files (downloaded music or whatever) then sure, but artist + album should be enough for commercially ripped CDs.

    Also, good lord, what happened to my name there? D:

    Huh... I wonder if that'll happen this time... I mean, I guess it's possible that I screwed it up, but I don't know how. It's not like I had that url on my clipboard or anything and I don't recall typing it...

    Trentus on
  • SyphonBlueSyphonBlue The studying beaver That beaver sure loves studying!Registered User regular
    edited September 2009
    Hmmm...Is there any way to do this but not have the weird symbols in front of all the directories?

    Or is that just me?

    SyphonBlue on
    LxX6eco.jpg
    PSN/Steam/NNID: SyphonBlue | BNet: SyphonBlue#1126
  • TrentusTrentus Registered User regular
    edited September 2009
    Ah, right, use tree /a to tell it to print ascii characters.

    Trentus on
  • SyphonBlueSyphonBlue The studying beaver That beaver sure loves studying!Registered User regular
    edited September 2009
    :^:

    SyphonBlue on
    LxX6eco.jpg
    PSN/Steam/NNID: SyphonBlue | BNet: SyphonBlue#1126
  • DarkWarriorDarkWarrior __BANNED USERS regular
    edited September 2009
    Thanks guys.

    DarkWarrior on
  • DarkWarriorDarkWarrior __BANNED USERS regular
    edited September 2009
    What does it mean when it says "Too many parameters - /s"?

    EDIT: Nevermind was doing it wrong.

    Anyway, additional question, the best result seems to be dir /b /s which doesnt give me stuff i dont need like file size and date modified. But is there a way to get it to also ignore the file directory so I just get a solid list of names?

    The output I'm getting at the moment is this:


    D:\Music\Akon - Beautiful (Ft. Colby Odonis And Kardinal Offishall).mp3

    Compared to this:

    10/08/2009 17:27 7,350,021 Akon - Beautiful (Ft. Colby Odonis And Kardinal Offishall).mp3

    Although the second output for some reason ignores the album art which I like.

    DarkWarrior on
  • PeregrineFalconPeregrineFalcon Registered User regular
    edited September 2009
    Once it's in a text file, just Ctrl+H (find and replace) the "D:\Music\" bit with "" and you're golden.

    Also, if there's hidden files, you'll want dir /a /b /s > file.txt - the /a will give you hidden/system as well.

    PeregrineFalcon on
    Looking for a DX:HR OnLive code for my kid brother.
    Can trade TF2 items or whatever else you're interested in. PM me.
  • DarkWarriorDarkWarrior __BANNED USERS regular
    edited September 2009
    Ah ok so I want to leave out the /a and it'll skip the album art. Thanks guys, I knew there was a command but its been along while since I used DOS for anything but mass deletion.

    Thanks muchly.

    DarkWarrior on
Sign In or Register to comment.