Congratulations to AcaCandy on her 100,000th post!
There's no such thing as a stupid question, but they're the easiest to answer.
JoinTour
Login
 
Tag Cloud
acer black screen blue screen boot bsod computer connection crash css dell display drive driver drivers email error ethernet excel firefox firefox 3 game hard drive internet internet explorer itunes laptop linux malware monitor network networking nvidia outlook outlook 2003 outlook 2007 outlook express partition problem router slow software sound trojan usb video virus vista windows windows xp wireless
UNIX/Linux
Search
Search in:
 
Advanced Search
Tech Support Guy Forums > Operating Systems > UNIX/Linux >
Get "ls -l" to return with full dir path


HELLO AND WELCOME! Before you can post your question, you'll have to register -- it's completely free! Click here to join today! We highly recommend that you print a copy of our Guide for New Members. Enjoy!

Closed Thread
 
Thread Tools
littleIdiot's Avatar
Junior Member with 2 posts.
 
Join Date: Jan 2006
Experience: Advanced
11-Jan-2006, 10:03 AM #1
Get "ls -l" to return with full dir path
All I want is to have a full listing of my directory (and ideally those below it), and for the result to contai the full path of each file returned.

For example, I currently get the following (with some edits made) :

$ pwd
/home/nlthoa
$ ls -lart
-rw-rw---- 1 nlthoa u032144 36473021 Jan 11 15:32 file_01.txt
-rw-rw---- 1 nlthoa u032144 36552704 Jan 11 15:36 file_02.txt
-rw-rw---- 1 nlthoa u032144 5137 Jan 11 15:39 file_03.txt


and I want to see the following:

$ pwd
/home/nlthoa
$ [your clever little command here]
total 142985
/home/nlthoa/file_01.txt
/home/nlthoa/file_02.txt
/home/nlthoa/file_03.txt


Any ideas?

Thanks in advance,
lil'
AGCurry's Avatar
Senior Member with 431 posts.
 
Join Date: Jun 2005
Location: Kansas City area
Experience: advanced but learning
11-Jan-2006, 10:20 AM #2
The ls command is not the one you want.

Try:

find $(pwd) -depth
or
find `pwd` -depth

This command will print the directory names as well as regular files, but you can use the
"-type" option to find to only print files of a certain type.
littleIdiot's Avatar
Junior Member with 2 posts.
 
Join Date: Jan 2006
Experience: Advanced
11-Jan-2006, 10:24 AM #3
Superb - worked like a charm!
Thank you!

find $(pwd) -depth
Closed Thread

THIS THREAD HAS EXPIRED.
Are you having the same problem? We have volunteers ready to answer your question, but first you'll have to join for free. Need help getting started? Check out our Welcome Guide.


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
WELCOME TO TECH SUPPORT GUY! Are you looking for the solution to your computer problem? Join our site today to ask your question -- for free! Our site is run completely by volunteers who help people like you solve computer problems. See our Welcome Guide to get started.



Thread Tools


You Are Using:
Server ID
Advertisements do not imply our endorsement of that product or service.
All times are GMT -4. The time now is 03:42 AM.
Copyright © 1996 - 2008 TechGuy, Inc. All rights reserved.
Powered by vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Powered by Cermak Technologies, Inc.