Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Flex Extract
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Service Desk
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Flexpart
Flex Extract
Commits
fdfaf004
Commit
fdfaf004
authored
6 years ago
by
Anne Philipp
Browse files
Options
Downloads
Patches
Plain Diff
changed flexpart directory variable
parent
2fef1f20
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
source/python/install.py
+18
-18
18 additions, 18 deletions
source/python/install.py
with
18 additions
and
18 deletions
source/python/install.py
+
18
−
18
View file @
fdfaf004
...
...
@@ -116,7 +116,7 @@ def get_install_cmdline_arguments():
parser
.
add_argument
(
"
--destination
"
,
dest
=
"
destination
"
,
default
=
None
,
help
=
'
ecaccess destination, e.g. leo@genericSftp
'
)
parser
.
add_argument
(
"
--flexpart
_root_scripts
"
,
dest
=
"
flexpart
_root_scripts
"
,
parser
.
add_argument
(
"
--flexpart
dir
"
,
dest
=
"
flexpart
dir
"
,
default
=
None
,
help
=
"
FLEXPART root directory on ECMWF
\
servers (to find grib2flexpart and COMMAND file)
\n\
Normally flex_extract resides in the scripts directory
\
...
...
@@ -163,10 +163,10 @@ def install_via_gateway(c):
if
c
.
install_target
.
lower
()
!=
'
local
'
:
# ecgate or cca
mk_compilejob
(
c
.
makefile
,
c
.
install_target
,
c
.
ecuid
,
c
.
ecgid
,
c
.
flexpart
_root_scripts
)
c
.
flexpart
dir
)
mk_job_template
(
c
.
ecuid
,
c
.
ecgid
,
c
.
gateway
,
c
.
destination
,
c
.
flexpart
_root_scripts
)
c
.
destination
,
c
.
flexpart
dir
)
mk_env_vars
(
c
.
ecuid
,
c
.
ecgid
,
c
.
gateway
,
c
.
destination
)
...
...
@@ -182,35 +182,35 @@ def install_via_gateway(c):
silent_remove
(
tar_file
)
print
(
'
job compilation script has been submitted to ecgate for
'
+
'
installation in
'
+
c
.
flexpart
_root_scripts
+
'
installation in
'
+
c
.
flexpart
dir
+
'
/
'
+
target_dirname
)
print
(
'
You should get an email with subject
"
flexcompile
"
within
'
+
'
the next few minutes!
'
)
else
:
#local
if
c
.
flexpart
_root_scripts
==
_config
.
PATH_FLEXEXTRACT_DIR
:
print
(
'
WARNING: FLEXPART
_ROOT_SCRIPTS
has not been specified
'
)
if
c
.
flexpart
dir
==
_config
.
PATH_FLEXEXTRACT_DIR
:
print
(
'
WARNING: FLEXPART
DIR
has not been specified
'
)
print
(
'
flex_extract will be installed in here by compiling the
'
+
'
Fortran source in
'
+
_config
.
PATH_FORTRAN_SRC
)
os
.
chdir
(
_config
.
PATH_FORTRAN_SRC
)
else
:
# creates the target working directory for flex_extract
c
.
flexpart
_root_scripts
=
os
.
path
.
expandvars
(
os
.
path
.
expanduser
(
c
.
flexpart
_root_scripts
))
if
os
.
path
.
abspath
(
ecd
)
!=
os
.
path
.
abspath
(
c
.
flexpart
_root_scripts
):
c
.
flexpart
dir
=
os
.
path
.
expandvars
(
os
.
path
.
expanduser
(
c
.
flexpart
dir
))
if
os
.
path
.
abspath
(
ecd
)
!=
os
.
path
.
abspath
(
c
.
flexpart
dir
):
mk_tarball
(
tar_file
,
c
.
install_target
)
make_dir
(
os
.
path
.
join
(
c
.
flexpart
_root_scripts
,
make_dir
(
os
.
path
.
join
(
c
.
flexpart
dir
,
target_dirname
))
os
.
chdir
(
os
.
path
.
join
(
c
.
flexpart
_root_scripts
,
os
.
chdir
(
os
.
path
.
join
(
c
.
flexpart
dir
,
target_dirname
))
un_tarball
(
tar_file
)
os
.
chdir
(
os
.
path
.
join
(
c
.
flexpart
_root_scripts
,
os
.
chdir
(
os
.
path
.
join
(
c
.
flexpart
dir
,
target_dirname
,
_config
.
PATH_REL_FORTRAN_SRC
))
# Create Fortran executable - CONVERT2
print
(
'
Install
'
+
target_dirname
+
'
software at
'
+
c
.
install_target
+
'
in directory
'
+
os
.
path
.
abspath
(
c
.
flexpart
_root_scripts
)
+
'
\n
'
)
os
.
path
.
abspath
(
c
.
flexpart
dir
)
+
'
\n
'
)
delete_convert_build
(
'
.
'
)
make_convert_build
(
'
.
'
,
c
.
makefile
)
...
...
@@ -261,13 +261,13 @@ def check_install_conditions(c):
support for further details
'
)
sys
.
exit
(
1
)
if
not
c
.
flexpart
_root_scripts
:
c
.
flexpart
_root_scripts
=
'
${HOME}
'
if
not
c
.
flexpart
dir
:
c
.
flexpart
dir
=
'
${HOME}
'
else
:
c
.
flexpart
_root_scripts
=
c
.
flexpart_root_scripts
c
.
flexpart
dir
=
c
.
flexpartdir
else
:
# local
if
not
c
.
flexpart
_root_scripts
:
c
.
flexpart
_root_scripts
=
_config
.
PATH_FLEXEXTRACT_DIR
if
not
c
.
flexpart
dir
:
c
.
flexpart
dir
=
_config
.
PATH_FLEXEXTRACT_DIR
return
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment