The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
.
google unix.com



UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Display modified files in ascending order balareddy UNIX for Advanced & Expert Users 1 08-13-2008 05:48 AM
Ascending & Descending order numbers pravani1 Shell Programming and Scripting 6 06-03-2008 07:43 AM
list exe files modified before certain dates fremont UNIX for Dummies Questions & Answers 2 05-25-2007 09:29 AM
list last 10 days modified files arunkumar_mca UNIX for Dummies Questions & Answers 1 10-12-2006 04:09 AM
how to see disk usage in descending order asutoshch UNIX for Dummies Questions & Answers 8 09-18-2001 08:58 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rating: Thread Rating: 1 votes, 4.00 average. Display Modes
  #1 (permalink)  
Old 11-19-2008
TonySolarisAdmi TonySolarisAdmi is offline
Registered User
  
 

Join Date: Aug 2008
Posts: 11
Help - Find command with list of files modified descending Order

Hi,
I would like to know the command to get the files order in descending order with "FIND" command.

Appreciate your help

Thanks
  #2 (permalink)  
Old 11-20-2008
sysgate's Avatar
sysgate sysgate is offline Forum Advisor  
Unix based
  
 

Join Date: Nov 2006
Location: Bulgaria
Posts: 1,318
Quote:
files order in descending order
- based on what criteria ?
  #3 (permalink)  
Old 11-20-2008
TonySolarisAdmi TonySolarisAdmi is offline
Registered User
  
 

Join Date: Aug 2008
Posts: 11
files order in descending order based on TimeStamp

files order in descending order based on TimeStamp .
OS is Solaris 5.8
There is no maxdepth option in Find command
  #4 (permalink)  
Old 11-20-2008
jim mcnamara jim mcnamara is offline Forum Staff  
...@...
  
 

Join Date: Feb 2004
Location: NM
Posts: 5,715
Code:
filetime()
{
    perl  -e '
          use POSIX qw(strftime);
          $mtime = (stat $ARGV[0])[9];
          print strftime "%Y-%m-%d:%H:%M:%S ", localtime($mtime);
         ' $1
}
find . -name '*.shl' |\
while read filename
do
        echo "$(filetime $filename) $filename"
done | sort
  #5 (permalink)  
Old 11-20-2008
TonySolarisAdmi TonySolarisAdmi is offline
Registered User
  
 

Join Date: Aug 2008
Posts: 11
Thanks a lot jim mcnamara, With your help I am able to solve my problem.
Appreciate your help.
Sponsored Links
Closed Thread

Bookmarks

Tags
sort by file date

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On




All times are GMT -4. The time now is 12:06 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0