The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #4 (permalink)  
Old 05-26-2009
panyam panyam is offline Forum Advisor  
Registered User
  
 

Join Date: Sep 2008
Posts: 474

Code:
find . ! -name "a.dat" ! -name "rem.txt" -name "*.dat" |xargs  -i  cp {} DEST


When i executed the above command , all files except a.dat file copied to the DEST folder. Although (a.dat fall under *.dat , find still excludes tht file).

In your case exclude all the 4 files , by putting their filenames in the commnad above and try.