baffeled with find command failure

Karl Auer kauer at biplane.com.au
Sun Sep 14 15:08:18 UTC 2014


On Sun, 2014-09-14 at 07:02 -0700, Rajeev Prasad wrote:
> this fails:
> fileloc='/var/adm/logs/morelogs'
> filename=' -name "*.user"'
> fileList="$(find "$fileloc"/* -type f -prune "$filename" -print)"

Try this:

#!/bin/sh
fileloc="/var/adm/logs/morelogs"
filename="*.user"
filelist="$(find $fileloc -type f -name "$filename" -print)"

Regards, K.

-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Karl Auer (kauer at biplane.com.au)
http://www.biplane.com.au/kauer
http://twitter.com/kauer389

GPG fingerprint: EC67 61E2 C2F6 EB55 884B E129 072B 0AF0 72AA 9882
Old fingerprint: B862 FB15 FE96 4961 BC62 1A40 6239 1208 9865 5F9A






More information about the ubuntu-users mailing list