File: Fdata

package info (click to toggle)
pyferret 7.6.5-10
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 138,136 kB
  • sloc: fortran: 240,609; ansic: 25,235; python: 24,026; sh: 1,618; makefile: 1,123; pascal: 569; csh: 307; awk: 18
file content (25 lines) | stat: -rwxr-xr-x 587 bytes parent folder | download | duplicates (13)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#! /bin/sh
# Fdata file_template
# determine if FERRET data files matching file_template are currently on-line by
# searching the paths in FER_DATA

if [ $# -ne 1 ]; then
   echo "usage: Fdata data_file_template"
   exit
fi

found=0
for subdir in ${FER_DATA} ; do
   filelist=`cd "${subdir}" ; find * -maxdepth 0 -type f -name \*"$1"\* -print`
   if [ -n "${filelist}" ]; then
      echo "* * * * * * * * in ${subdir}"
      ( cd "${subdir}" ; /bin/ls -l ${filelist} )
      found=1
      echo " " 
   fi
done

if [ ${found} -eq 0 ]; then
   echo "No files matching '$1' were found"
fi