So I know how to do this on windows using the cmd, I am wondering if this is possible on mac to copy all the file paths within a folder / nested folders into a .txt file.
Asked
Active
Viewed 371 times
0
-
Possible duplicate of [How to recursively list all files and directories](http://stackoverflow.com/questions/501367/how-to-recursively-list-all-files-and-directories) – str Jan 20 '17 at 13:50
-
@str is that not refering to linux? – Nebbyyy Jan 20 '17 at 13:54
-
No not necessarily. The first answer works perfectly on Mac OS. – str Jan 20 '17 at 13:58
-
`find . -type d > result.txt` should do the trick – Jean-Baptiste Yunès Jan 20 '17 at 14:00
-
@Jean-BaptisteYunès would you mind just quickly explaining what each part does? – Nebbyyy Jan 20 '17 at 14:03
-
@Jean-BaptisteYunès any ideas how to narrow it to just one folder? – Nebbyyy Jan 20 '17 at 14:05
-
Hey wait a minute, it seems that you don't dig by yourself, so now read the manuals `man find` and have a look at shell redirections on internet. – Jean-Baptiste Yunès Jan 20 '17 at 14:06
-
@Jean-BaptisteYunès im new to mac, all i need is this this functionality for a customer then i wont be touching it again – Nebbyyy Jan 20 '17 at 14:07
-
This ain't a good reason, SO is not a "please, makes it for me" platform. I gave you hint-solution, now dig into it. – Jean-Baptiste Yunès Jan 20 '17 at 14:08
-
hence why i asked if you could explain what they meant so I could try figure it out – Nebbyyy Jan 20 '17 at 14:09
-
No worries got it – Nebbyyy Jan 20 '17 at 14:10
1 Answers
0
Issue solved using
find /Users/Allington/Desktop/Client -type f > result.txt
Returns
/Users/Allington/Desktop/Client/.DS_Store
/Users/Allington/Desktop/Client/Client account 1/Screen Shot 2016-12-14 at 16.07.34.png
/Users/Allington/Desktop/Client/Client account 1/Screen Shot 2017-01-10 at 12.13.32.png
/Users/Allington/Desktop/Client/Client account 1/Screen Shot 2017-01-10 at 15.15.27.png
/Users/Allington/Desktop/Client/Client account 1/Screen Shot 2017-01-10 at 15.15.42.png
/Users/Allington/Desktop/Client/Client Account 2/Screen Shot 2017-01-10 at 14.33.32.png
/Users/Allington/Desktop/Client/Client Account 2/Screen Shot 2017-01-10 at 14.33.40.png
/Users/Allington/Desktop/Client/Client Account 2/Screen Shot 2017-01-10 at 14.47.41.png
/Users/Allington/Desktop/Client/Client Account 2/Screen Shot 2017-01-10 at 15.15.51.png
/Users/Allington/Desktop/Client/Client Account 3/landingBannerimg.png
/Users/Allington/Desktop/Client/Client Account 3/Screen Shot 2017-01-10 at 14.57.14.png
/Users/Allington/Desktop/Client/Client Account 3/Screen Shot 2017-01-10 at 15.15.06.png
/Users/Allington/Desktop/Client/Client Account 3/Screen Shot 2017-01-12 at 13.03.57.png

Nebbyyy
- 358
- 4
- 20