or Connect
AppleInsider › Forums › Software › Mac OS X › Copying file names
New Posts  All Forums:Forum Nav:

Copying file names

post #1 of 10
Thread Starter 
Is there an easy way to copy a list of file names (only) and paste the list of names into TextEdit, Excel, or ???
ADS
Reply
ADS
Reply
post #2 of 10
Use the Terminal:
  1. Type ls {path of file directory}.
  2. Copy list of files in Terminal window.
  3. Paste into text editor.
post #3 of 10
You can also drag the files straight into TextEdit and do a find/replace to get rid of the path or alt-drag the list and it will do a vertical selection of the paths, which should be the same length and you can delete that part leaving just the names.
post #4 of 10
Thread Starter 
Quote:
Originally Posted by Marvin View Post

You can also drag the files straight into TextEdit and do a find/replace to get rid of the path or alt-drag the list and it will do a vertical selection of the paths, which should be the same length and you can delete that part leaving just the names.

Either way, I get a horizontal row of icons but no file names.
ADS
Reply
ADS
Reply
post #5 of 10
Thread Starter 
Quote:
Originally Posted by Achim View Post

Select the file list in the finder, copy (Command-C) and paste (Command-P) into a TextEdit document. Ready.

Command P is for Print. If I use Command V, again, all I get is a horizontal row of icons and no file names.

I must be doing something wrong, but I don't know what. I have Snow Leopard. Is that supposed to work in SL?
ADS
Reply
ADS
Reply
post #6 of 10
Quote:
Originally Posted by Achim View Post

Select the file list in the finder, copy (Command-C) and paste (Command-P) into a TextEdit document. Ready.

That pastes that actual files into the text document, so you now have an unformatted newsletter of sorts containing every page and/or image of every document.

Not what I'd call a manageable list.
post #7 of 10
Thread Starter 
Quote:
Originally Posted by Achim View Post

In TextEdit, after you pasted the file list, in the menu bar goto Format > Make plain text... Tada!

And yes, Command-P should of course be Command-V. My mistake, sorry. And yes, it works in SL.

You da man~!!!! Thanks. Changing the text makes it happen. Now why didn't I think of that?
ADS
Reply
ADS
Reply
post #8 of 10
Quote:
Originally Posted by sequitur View Post

You da man~!!!! Thanks. Changing the text makes it happen. Now why didn't I think of that?

Nice!...also, if you change to text before pasting, it only pastes the list!
post #9 of 10
Thread Starter 
Quote:
Originally Posted by hilfiger View Post

You double click on the file but press once and after 2 second the other and copy the name and paste where ever you wanted.

That is not clear. Where do you double click on the file? The Name of the file? What do you press once? and what is the 'other' that you click after 2 seconds? What name do you copy and paste - the name of the file?

I have tried to do as you've suggested, but no joy.
ADS
Reply
ADS
Reply
post #10 of 10
Quote:
Originally Posted by Mr. Me View Post

Use the Terminal:
  1. Type ls {path of file directory}.
  2. Copy list of files in Terminal window.
  3. Paste into text editor.

Waste of time. Put the info directly where you want it.

ls > files.txt
(optional) open files.txt
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Mac OS X
AppleInsider › Forums › Software › Mac OS X › Copying file names