![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Need to get 4 Hrs back time and compare with successive time | maanik85 | UNIX for Dummies Questions & Answers | 2 | 07-15-2008 09:48 AM |
| Compare file time | pdr302 | Shell Programming and Scripting | 1 | 11-01-2007 07:14 PM |
| Compare Date And Time | Jamil Qadir | UNIX for Dummies Questions & Answers | 5 | 01-10-2007 11:22 AM |
| compare update time of files | dorilevy | UNIX for Dummies Questions & Answers | 8 | 05-27-2003 10:48 AM |
| compare files acess time | AkumaTay | UNIX for Dummies Questions & Answers | 2 | 05-19-2002 04:02 PM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Hi ...
Is there a possibility that timings from two files be compared?? If i have a set of files in a folder and i want to get the files only upto a particular time. eg: If i have the files staff 2388 Oct 3 04:33 x.ksh staff 3628 Oct 3 06:57 1.ksh staff 32383 Oct 3 06:57 files staff 280365 Oct 3 06:57 bakup staff 140770 Oct 3 20:54 satsub1 staff 123000 Oct 3 20:58 satsub2 I want the list of files which are present before or equal to time 20:54 Is that possible with time??? thanks, |
|
||||
|
Code:
touch -t 200810032054 dummy
find /path/to/files -type f ! -newer dummy -exec ls -l {} \;
rm -f dummy
put a timestamp on a dummy file, use that file with ! -newer - meaning "not" newer or older in a find command. If you have a file already has the correct timestamp you do not need to touch a dummy file |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|