11 #include "eckit/config/Configuration.h" 13 #include "oops/util/abor1_cpp.h" 14 #include "oops/util/Logger.h" 26 oops::Log::trace() <<
"Staging fv3 input.nml and field_table" << std::endl;
32 if (world_rank == 0) {
34 std::remove(
"input.nml");
35 std::remove(
"field_table");
38 if (
conf.has(
"nml_file")) {
39 std::string nml_file =
conf.getString(
"nml_file");
40 symlink(nml_file.c_str(),
"./input.nml");
42 ABORT(
"input.nml not in configuration");
44 if (
conf.has(
"trc_file")) {
45 std::string trc_file =
conf.getString(
"trc_file");
46 symlink(trc_file.c_str(),
"./field_table");
48 ABORT(
"field_table not in configuration");
52 if (
conf.has(
"nml_file_pert")) {
53 oops::Log::trace() <<
"Also staging fv3 inputpert.nml" << std::endl;
54 std::remove(
"inputpert.nml");
55 std::string nml_file_pert =
conf.getString(
"nml_file_pert");
56 symlink(nml_file_pert.c_str(),
"./inputpert.nml");
67 oops::Log::trace() <<
"Staging fv3 input.nml" << std::endl;
73 if (world_rank == 0) {
75 std::remove(
"input.nml");
78 if (
conf.has(
"nml_file")) {
79 std::string nml_file =
conf.getString(
"nml_file");
80 symlink(nml_file.c_str(),
"./input.nml");
82 ABORT(
"input.nml not in configuration");
93 oops::Log::trace() <<
"Removing fv3 input.nml and field_table" << std::endl;
102 if (world_rank == 0) {
103 std::remove(
"input.nml");
104 std::remove(
"field_table");
107 std::remove(
"inputpert.nml");
114 oops::Log::trace() <<
"Removing fv3 input.nml" << std::endl;
123 if (world_rank == 0) {
124 std::remove(
"input.nml");
void stageFv3Files(const eckit::Configuration &conf)
const eckit::mpi::Comm & comm()
void stageFv3Input(const eckit::Configuration &conf)