#!/bin/csh -f

set wrkdir = $1
set diagroot = $2
set PM_YPOPLOG = $3
set file_name = $4
set hsilogflag = $5
set lpath = $6
set dtpath = $7

setenv TOOLPATH $diagroot/tool_lib

if ($hsilogflag == 0) then
  setenv ocnlogpath $lpath
  setenv dtfilepath $dtpath
else
  setenv ocnlogpath $wrkdir
  setenv dtfilepath $wrkdir
endif

if ($PM_YPOPLOG == 1) then

  set current = $PWD
  cd $wrkdir

  ${TOOLPATH}/process_pop2_logfiles.globaldiag.awk $ocnlogpath/ocn.log.*
  ${TOOLPATH}/process_pop2_dtfiles.awk $dtfilepath/*.dt.*

  cd $current
endif

printf " This file was created as a placeholder" > $file_name

