New To Mac-Forums?

Welcome to our community! Join the discussion today by registering your FREE account. If you have any problems with the registration process, please contact us!

Get your questions answered by community gurus Advice and insight from world-class Apple enthusiasts Exclusive access to members-only contests, giveaways and deals

Join today!

 
Start a Discussion
 

Mac-Forums Brief

Subscribe to Mac-Forums Brief to receive special offers from Mac-Forums partners and sponsors

Join the conversation RSS
OS X - Operating System General OS operation information and support

Folder Content List


Post Reply New Thread Subscribe

 
Thread Tools
Sawday

 
Sawday's Avatar
 
Member Since: Nov 19, 2006
Location: York, UK
Posts: 1,042
Sawday is a jewel in the roughSawday is a jewel in the roughSawday is a jewel in the rough
Mac Specs: 24" Aluminium, 2.8 GHz, 4Gb RAM. iPad2, iPhone5s

Sawday is offline
Is there any way to export a folder (and ideally sub folders) content list to,say, a .CSV file. I would like the file names, creation date and size and I don't mind if all the sub folder contents are listed in one long list.

Happiness is not getting what you want, but wanting what you get.
QUOTE Thanks
Dysfunction

 
Dysfunction's Avatar
 
Member Since: Mar 17, 2008
Location: Tucson, AZ
Posts: 6,638
Dysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant future
Mac Specs: 2008 and 2011 15" mbps, late 11 iMac, iPhone 4s, and too many ipods and other stuff

Dysfunction is offline
If no one comes back with a way to do so from the GUI, I'll post a way to gain a text-file with this information from the command line.

mike
This machine kills fascists
Got # ? phear the command line!
QUOTE Thanks
vansmith

 
vansmith's Avatar
 
Member Since: Oct 19, 2008
Location: Toronto
Posts: 18,352
vansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond repute
Mac Specs: 2012 13" MBP (2.5 i5, 8GB)

vansmith is offline
So, I fooled around with Automator and can get you part of the way if you're looking for a GUI option:
Screen Shot 2011-08-17 at 1.55.01 PM.png
That won't give you the creation date or size but it will print the name of every file (recursively) to a text document on your Desktop called "Untitled.txt."

There is of course "ls -lhR" from the command line that will print the date, size and name of each file in a particular folder (this is the command line way). To be honest though, I'm not sure if the date printed is the modified date or the creation date. I'll have to defer to Dysfunction here.

Important Links: Community Guidelines : Use the reputation system if you've been helped.
M-F Blog :: Write for the blog
Writing a Quality Post
QUOTE Thanks
Sawday

 
Sawday's Avatar
 
Member Since: Nov 19, 2006
Location: York, UK
Posts: 1,042
Sawday is a jewel in the roughSawday is a jewel in the roughSawday is a jewel in the rough
Mac Specs: 24" Aluminium, 2.8 GHz, 4Gb RAM. iPad2, iPhone5s

Sawday is offline
Thanks guys. I've never managed to get Automator to do what I want but will try this if only for educational purposes. Dysfunction - do you have a command line option to go through the subfolders.
For what I need to do, I'm not too fussed exactly which date is picked up and having to do each subfolder in turn would not be a deal breaker - just a little time consuming.

Happiness is not getting what you want, but wanting what you get.
QUOTE Thanks
vansmith

 
vansmith's Avatar
 
Member Since: Oct 19, 2008
Location: Toronto
Posts: 18,352
vansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond repute
Mac Specs: 2012 13" MBP (2.5 i5, 8GB)

vansmith is offline
Would something like the following accomplish what you're looking for (I can always tweak it)?
Screen Shot 2011-08-18 at 9.47.07 AM.png

Important Links: Community Guidelines : Use the reputation system if you've been helped.
M-F Blog :: Write for the blog
Writing a Quality Post
QUOTE Thanks
Dysfunction

 
Dysfunction's Avatar
 
Member Since: Mar 17, 2008
Location: Tucson, AZ
Posts: 6,638
Dysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant future
Mac Specs: 2008 and 2011 15" mbps, late 11 iMac, iPhone 4s, and too many ipods and other stuff

Dysfunction is offline
find . -type d -exec ls -lh {} \; |cut -f6- -d ' ' would also work, depending on how you want it presented.

mikeMBP:testdir mike$ find . -type d -exec ls -lh {} \; |cut -f6- -d ' '

136B Aug 18 07:06 Live At The Whiskey A Go-Go
238B Aug 18 07:06 More Fun In The New World

3.1M Aug 18 07:06 X - Live At The Whiskey A Go-Go - Blue Spark.mp3
4.9M Aug 18 07:06 X - Live At The Whiskey A Go-Go - Johnny Hit And Run Pauline.mp3

3.2M Aug 18 07:06 X - More Fun In The New World - Breathless.mp3
2.8M Aug 18 07:06 X - More Fun In The New World - I See Red.mp3
2.8M Aug 18 07:06 X - More Fun In The New World - Poor Girl.mp3
3.1M Aug 18 07:06 X - More Fun In The New World - The New World.mp3
2.9M Aug 18 07:06 X - More Fun In The New World - We-re Having Much More Fun.m

mike
This machine kills fascists
Got # ? phear the command line!
QUOTE Thanks
vansmith

 
vansmith's Avatar
 
Member Since: Oct 19, 2008
Location: Toronto
Posts: 18,352
vansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond repute
Mac Specs: 2012 13" MBP (2.5 i5, 8GB)

vansmith is offline
Mine is incorrect (according to your needs) - it should be the following:
Code:
ls -lH | awk '{print $3 "," $6 " " $7 " " $8 "," $9}'
which prints out the following:
Code:
,  ,
vansmith,21 Mar 23:20,main.py
To be honest, I wasn't sure how to get rid of the first line (which represents the file count printed back by the "-l" switch). If I did this with directories and attempted to do it recursively, I got the following:
Code:
,  ,
vansmith,20 Jul 13:50,src
vansmith,18 Aug 12:42,test.txt
,  ,
,  ,
,  ,
vansmith,21 Mar 23:20,main.py
In that case, test.txt and the "src" folder are at one level and the main.py file is in the src folder. After some fiddling, I have come up with the following:
Code:
ls -lHRh | awk '{if ($3 != "") print $3 "," $5 "," $6 " " $7 " " $8 "," $9}'
That outputs the following (as "user,size,modification date,file/folder"):
Code:
vansmith,102B,20 Jul 13:50,src
vansmith,0B,18 Aug 12:42,test.txt
vansmith,4.3K,21 Mar 23:20,main.py
The only final problem I see is that you have no way of telling what is in the src folder (as I noted, the "main.py" file is in that folder). If I figure that out, I'll report back.

Dysfunction's solution probably works better. I'm partly doing this for the learning now.

Important Links: Community Guidelines : Use the reputation system if you've been helped.
M-F Blog :: Write for the blog
Writing a Quality Post
QUOTE Thanks
Dysfunction

 
Dysfunction's Avatar
 
Member Since: Mar 17, 2008
Location: Tucson, AZ
Posts: 6,638
Dysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant futureDysfunction has a brilliant future
Mac Specs: 2008 and 2011 15" mbps, late 11 iMac, iPhone 4s, and too many ipods and other stuff

Dysfunction is offline
tree would be ideal for building this, too bad I do a 'which tree' and return null

mike
This machine kills fascists
Got # ? phear the command line!
QUOTE Thanks
vansmith

 
vansmith's Avatar
 
Member Since: Oct 19, 2008
Location: Toronto
Posts: 18,352
vansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond repute
Mac Specs: 2012 13" MBP (2.5 i5, 8GB)

vansmith is offline
Just for you. Built it here - the instructions worked perfectly.

Important Links: Community Guidelines : Use the reputation system if you've been helped.
M-F Blog :: Write for the blog
Writing a Quality Post
QUOTE Thanks
Sawday

 
Sawday's Avatar
 
Member Since: Nov 19, 2006
Location: York, UK
Posts: 1,042
Sawday is a jewel in the roughSawday is a jewel in the roughSawday is a jewel in the rough
Mac Specs: 24" Aluminium, 2.8 GHz, 4Gb RAM. iPad2, iPhone5s

Sawday is offline
Thanks everyone. For the record I found dydfunctions find command line did just what I wanted.

Happiness is not getting what you want, but wanting what you get.
QUOTE Thanks

Post Reply New Thread Subscribe


« Installed OSX Lion and lost network connection with media HD | Open Windows and running apps »
Thread Tools

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread
Thread Starter
Forum
Replies
Last Post
Accidentally changed "Home" folder name... confusing reprecussions... uli_kunkel OS X - Operating System 3 01-19-2010 07:34 PM
how to create new folder within folder in finder dancamp OS X - Operating System 5 01-15-2010 09:52 AM
Moving and replacing folder contents frisbeefodder OS X - Operating System 2 06-16-2008 03:13 AM
Deleting personal files from company computer Aisho Switcher Hangout 3 04-25-2008 02:24 AM
iTunes Tips And Tricks RJgamer iPod Hardware and Accessories 2 07-12-2007 12:59 PM

All times are GMT -4. The time now is 02:18 PM.

Powered by vBulletin
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
X

Welcome to Mac-Forums.com

Create your username to jump into the discussion!

New members like you have made this community the ultimate source for your Mac since 2003!


(4 digit year)

Already a member?