![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Advanced & Expert Users Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Can I know find syntax to find given date files | bache_gowda | Shell Programming and Scripting | 3 | 03-26-2008 06:37 AM |
| How can I find files by date or size from stout? | umen | UNIX for Dummies Questions & Answers | 2 | 01-13-2008 09:04 AM |
| find files by date | kani | Shell Programming and Scripting | 1 | 10-25-2007 06:51 AM |
| how to find files less than the current date | mallikarjuna | UNIX for Dummies Questions & Answers | 4 | 01-20-2006 01:49 PM |
| BASH : Find files by date and shred them | cbismuth | Shell Programming and Scripting | 2 | 06-13-2005 11:20 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Find all the files after the date?
Hi
I am using #!/bin/sh DATE="$1" FILE="$2" FLIST="" for f in $FILE do FDATE=$(ls -l $f | awk '{ print $6 }') if [ "$DATE" == "$FDATE" ];then FLIST="$FLIST $f" fi done [ "$FLIST" != "" ] && echo $FLIST || echo "Sorry no files found to match $DATE date." the below... need correction whne i execute the above date.sh "2006-01-01" "*.sh" /home/cvs ->date.sh 2006-01-01 "*.sh" date.sh[12]: ==: A test command parameter is not valid. date.sh[12]: ==: A test command parameter is not valid. date.sh[12]: ==: A test command parameter is not valid. date.sh[12]: ==: A test command parameter is not valid. date.sh[12]: ==: A test command parameter is not valid. date.sh[12]: ==: A test command parameter is not valid. Sorry no files found to match 2006-01-01 date. |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|