source: flex_extract.git/run/run.sh @ ca867de

dev
Last change on this file since ca867de was ca867de, checked in by Anne Philipp <anne.philipp@…>, 12 months ago

refactored functions in EcFlexpart? and did some minor changes

  • Property mode set to 100755
File size: 2.1 KB
Line 
1#!/bin/bash
2#
3# @Author: Anne Philipp
4#
5# @Date: October, 4 2018
6#
7# @Description:
8#
9
10
11# -----------------------------------------------------------------
12# AVAILABLE COMMANDLINE ARGUMENTS TO SET
13#
14# THE USER HAS TO SPECIFY THESE PARAMETER
15#
16
17QUEUE=None
18START_DATE='20120908'
19END_DATE=None
20DATE_CHUNK=None
21BASETIME=None
22STEP=None
23LEVELIST=None
24AREA=None
25INPUTDIR='../../run/workspace/test'
26OUTPUTDIR=None
27FLEXPART_ROOT_SCRIPTS=None
28PP_ID=None
29JOB_TEMPLATE='job.temp' 
30CONTROLFILE='CONTROL.temp' 
31DEBUG=1 
32REQUEST=1
33
34# -----------------------------------------------------------------
35#
36# AFTER THIS LINE THE USER DOES NOT HAVE TO CHANGE ANYTHING !!!
37#
38# -----------------------------------------------------------------
39
40# PATH TO SUBMISSION SCRIPT
41pyscript=../source/python/submit.py
42
43# INITIALIZE EMPTY PARAMETERLIST
44parameterlist=""
45
46# CHECK FOR MORE PARAMETER
47if [ -n "$START_DATE" ]; then
48  parameterlist+=" --start_date=$START_DATE"
49fi
50if [ -n "$END_DATE" ]; then
51  parameterlist+=" --end_date=$END_DATE"
52fi
53if [ -n "$DATE_CHUNK" ]; then
54  parameterlist+=" --date_chunk=$DATE_CHUNK"
55fi
56if [ -n "$BASETIME" ]; then
57  parameterlist+=" --basetime=$BASETIME"
58fi
59if [ -n "$STEP" ]; then
60  parameterlist+=" --step=$STEP"
61fi
62if [ -n "$LEVELIST" ]; then
63  parameterlist+=" --levelist=$LEVELIST"
64fi
65if [ -n "$AREA" ]; then
66  parameterlist+=" --area=$AREA"
67fi
68if [ -n "$INPUTDIR" ]; then
69  parameterlist+=" --inputdir=$INPUTDIR"
70fi
71if [ -n "$OUTPUTDIR" ]; then
72  parameterlist+=" --outputdir=$OUTPUTDIR"
73fi
74if [ -n "$FLEXPART_ROOT_SCRIPTS" ]; then
75  parameterlist+=" --flexpart_root_scripts=$FLEXPART_ROOT_SCRIPTS"
76fi
77if [ -n "$PP_ID" ]; then
78  parameterlist+=" --ppid=$PP_ID"
79fi
80if [ -n "$JOB_TEMPLATE" ]; then
81  parameterlist+=" --job_template=$JOB_TEMPLATE"
82fi
83if [ -n "$QUEUE" ]; then
84  parameterlist+=" --queue=$QUEUE"
85fi
86if [ -n "$CONTROLFILE" ]; then
87  parameterlist+=" --controlfile=$CONTROLFILE"
88fi
89if [ -n "$DEBUG" ]; then
90  parameterlist+=" --debug=$DEBUG"
91fi
92if [ -n "$REQUEST" ]; then
93  parameterlist+=" --request=$REQUEST"
94fi
95
96# -----------------------------------------------------------------
97# CALL INSTALLATION SCRIPT WITH DETERMINED COMMANDLINE ARGUMENTS
98
99$pyscript $parameterlist
100
Note: See TracBrowser for help on using the repository browser.
hosted by ZAMG