Software to compose list of file folder NAMES!! HELP!!!!

Discussion in 'Mac Basics and Help' started by Swaver, Nov 20, 2011.

  1. Swaver macrumors newbie

    Joined:
    Nov 20, 2011
    #1
    hey all, just curious if there is any osx or pc software out there that will extract or copy JUST the file folder NAME and compose a list of it. i have a 3TB hdd with 2000+ movies on it and i backed my drive up onto another 3TB hdd so id have a back up, except i didn't copy the document with every title in alphabetical order, according to genre. and the main drive crashed not long ago. so now i am stuck either try find a software that will take the name from the enclosing folder and creat a list. or i can go thru my 2000+ titles and rewrite it from scratch, will take many many hours, or just go without the list.... Any help would be much appreciated thanks!

    Swaverrr
     
  2. jackrv macrumors 6502

    Joined:
    Jul 14, 2011
    #2
    From terminal, go to the directory and try this: $ ls -l | grep “^d” > filename.txt . I am on my phone right now but will see if it can work recursively as well when I get home and edit post to update. This should create a .txt file containing only directories.
     
  3. chown33, Nov 20, 2011
    Last edited: Nov 20, 2011

    chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #3
    Code:
    find . -type d -print | sort -f >alphabetical-listing.txt
    Or:
    Code:
     find . -type d -exec basename {} \; | sort -f >alphabetical-listing.txt
    
     
  4. Swaver thread starter macrumors newbie

    Joined:
    Nov 20, 2011
    #4
    i am kind of a noob when it comes to terminal but it didn't seem to work, it said command not found. thanks for the help and the patients!

    Swaver
     
  5. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #5
    Post exactly what you typed.
    Post the actual text of the error message.
    (Copy and paste both from your Terminal window.)


    Don't type in the $.
    Code:
    ls -l | grep "^d" > filename.txt
     
  6. Swaver thread starter macrumors newbie

    Joined:
    Nov 20, 2011
    #6
    alright so i am trying... hmm please bare with me this is what i tried... i tried everything

    Last login: Sun Nov 20 16:24:53 on ttys000
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ ls -l | grep "^d" > filename.txt
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ ls -l | grep "^d" > filename.txt
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ find ls -l | grep "^d" > filename.txtfind: -l: unknown option
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ ls -l | grep "^d" > filename.txt
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ ls -l | grep “^d” > filename.txt
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ ls -l | grep “^d” > filename.txt command not found
    grep: command: No such file or directory
    grep: not: No such file or directory
    grep: found: No such file or directory
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ command not found ls -l | grep “^d” > filename.txt
    -bash: not: command not found
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ removable hdd
    -bash: removable: command not found
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ ls -l | grep “^d” > filename.txt
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ >alphabetical-listing.txt
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ -l | grep "^d" > filename.txt
    -bash: -l: command not found
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ -l | grep "^d" > filename.txt
    -bash: -l: command not found
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ -type d -print | sort -f >alphabetical-listing.txt
    -bash: -type: command not found
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ -type d -print
    -bash: -type: command not found
    Corey-Johnsons-MacBook-Pro:~ coreyjohnson$ sort -f >alphabetical-listing.txt
    -type d -exec basename {} \;
    -f >alphabetical-listing.txt


    ls -l | grep "^d" > filename.txt



    sorry, dont feel obligated to help but i am not having much luck, hahah thanks.. also if this helps my hdd is catagorized as such, documentaries; movies; disneys; disney classics; tv series i really only want the movie folder and disney folder made into a list because between them they contain 2500 movie tittles and it would be nice to have it in list format again as well... thansk for any help!!


    Swaver
     
  7. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #7
    This is your first command-line. You don't realize it, but it actually did something.

    Look in the file "filename.txt" located in your home folder for the output it produced.

    If you open it in TextEdit.app and it's empty, then use that exact command again. And only that command. Do not randomly type or paste things into Terminal windows. And close filename.txt in TextEdit first.


    All the rest of the commands where it shows an error message are because you're randomly mixing together pieces of completely different commands. That's not going to work. For the same reason that bliffing quord wacknum with random words is not florping too pulticronous meaningful.
     
  8. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #8
    Here's a manual procedure to try.

    1. In Finder, open the folder you want to list. Example: disney.
    2. View as List from View menu.
    3. Select All (command A).
    4. Copy (command C).
    5. Open TextEdit.app.
    6. New (command N).
    7. Format menu, choose Make Plain Text.
    8. Paste (command V).

    After step 8, the TextEdit window should be a list consisting of every item you selected and copied from the Finder window. The "Make Plain Text" step is essential: it ensures that the text name is pasted in step 8.

    If the list is acceptable, save it as a plain text file. Or choose "Make Rich Text" from the Format menu and save that way.

    To experiment, simply select fewer folders in the Finder's list view window. Then copy (command C), switch to the TextEdit plain-text window, then paste.
     
  9. Swaver thread starter macrumors newbie

    Joined:
    Nov 20, 2011
    #9
    ooh how i thank you guys so much for helping me! this will save me hours of typing! take care!

    Swaver
     

Share This Page