Jpp  18.3.1
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Functions | Variables
getArchive.sh File Reference

Go to the source code of this file.

Functions

then fatal Invalid path $argv[1]
fi setopt extendedglob typeset
Z8 ID function 
archive ()
 
 if (($#==1))
 
return fi if (($ID==0))
 
then fatal Invalid detector
identifier $argv[2] fi 
if (($#==2))
 
return fi if (($RUN==0))
 
then fatal Invalid run $argv[3] fi if (($#==3))
 
do archive $BUFFER done fi if (($# >=4))
 

Variables

 script
 
then usage $script< path >[
< detector identifier >[< run >[
< type >[version]]]] nUtility
script to list files in
archive fi case set_variable
VERSION 
$argv [5]
 
&let RUN =" $argv[3]"
 
&let ID =" $argv[2]"
 
*fatal Wrong number of
arguments esac 
if [[!-d $DIR]]
 
then ls $DIR egrep {ANY}
 
then ls $DIR $ID
 
then eval ls $DIR $ID *_
****dev null while read 
BUFFER
 
then eval ls $DIR $ID $TYPE _ {VERSION}/\*/\*/\* 2> /dev/null | while read BUFFER
 

Function Documentation

then fatal Invalid path $argv [1] fi setopt extendedglob typeset Z8 ID function archive ( )

Definition at line 42 of file getArchive.sh.

43 {
44  typeset -T BUFFER ARRAY /
45 
46  BUFFER=$1
47 
48  set_variable A_ID ${ARRAY[-6]}
49  set_variable A_TYPE ${ARRAY[-5]}
50  set_variable A_VERSION ${ARRAY[-4]#_}
51  let A_MINRUN=" ${ARRAY[-3]}"
52  let A_MAXRUN=" ${ARRAY[-2]}"
53  set_variable A_FILENAME ${ARRAY[-1]}
54 
55  let A_COUNTER="${A_FILENAME:r}"
56 
57  if (( $RUN >= $A_MINRUN && $RUN <= $A_MAXRUN )); then
58 
59  ls -l --author $BUFFER
60 
61  if (( $DEBUG >= 3 )); then
62  echo "identifier: $(($A_ID))"
63  echo "type: $A_TYPE"
64  echo "version: $A_VERSION"
65  echo "minimal run: $(($A_MINRUN))"
66  echo "maximal run: $(($A_MAXRUN))"
67  echo
68  fi
69  fi
70 
71 }
esac done BUFFER
Definition: JMakePDF.sh:83
then
Definition: datalogs.sh:31
do set_variable A_ID
Definition: getFile.sh:53
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable
Definition: JAcoustics.sh:21
do set_variable OUTPUT_DIRECTORY $WORKDIR T
then eval ls $DIR $ID $TYPE _
Definition: getArchive.sh:104
then echo
Definition: JQAQC.sh:90
if ( ($#==1)  )
return fi if ( ($ID==0)  )
then fatal Invalid detector identifier $argv [2] fi if ( ($#==2)  )
return fi if ( ($RUN==0)  )
then fatal Invalid run $argv [3] fi if ( ($#==3)  )
do archive $BUFFER done fi if ( ($# >=4)  )

Variable Documentation

script
Initial value:
=${0##*/}
source ${0%${script}}ulib.sh
set_variable: DEBUG ARCHIVE_DEBUG 2
if do_usage $*
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable
Definition: JAcoustics.sh:21
#define VERSION
Definition: elog-version.h:27
script
Definition: JAcoustics.sh:2
#define DEBUG(A)
Message macros.
Definition: JMessage.hh:62

Definition at line 5 of file getArchive.sh.

& set_variable DIR $argv[1]

Definition at line 18 of file getArchive.sh.

& let RUN =" $argv[3]"

Definition at line 20 of file getArchive.sh.

& let ID =" $argv[2]"

Definition at line 21 of file getArchive.sh.

* fatal Wrong number of arguments esac if[[!-d $DIR]]

Definition at line 22 of file getArchive.sh.

then ls $DIR egrep {ANY}

Definition at line 75 of file getArchive.sh.

then ls $DIR $ID

Definition at line 85 of file getArchive.sh.

then eval ls $DIR $ID* _* * * * dev null while read BUFFER

Definition at line 96 of file getArchive.sh.

then eval ls $DIR $ID $TYPE _ {VERSION}/\*/\*/\* 2> /dev/null | while read BUFFER

Definition at line 104 of file getArchive.sh.