Skip to content

Commit

Permalink
Merge pull request #301 from jedwards4b/shell_commands_delete
Browse files Browse the repository at this point in the history
Shell commands delete
  • Loading branch information
jgfouca authored Jul 27, 2016
2 parents 4ef656d + 2f78ec7 commit 1eb2a56
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 3 deletions.
45 changes: 45 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,5 +1,50 @@
======================================================================

Originator: Jim Edwards
Date: July 26, 2016
Tag: cime5.0.3
Answer Changes: None
Tests: scripts_regression_tests
Dependencies:

Brief Summary: fixes as a result of cesm2_alpha01b testing
print output from buildnml
improve mismatch argument to NAG compiler
fix memleak error if baseline not found
add support to create_test for ascii testfile
move pecount support from create_test to create_newcase
fix LII test, fix ERP test
reintroduce --verbose option

User interface changes: none

Modified files: git diff --name-status
M ChangeLog
M cime_config/acme/config_files.xml
M cime_config/cesm/machines/Makefile
M cime_config/cesm/machines/config_compilers.xml
A cime_config/cesm/machines/nag_mpi_argument.txt
M driver_cpl/cime_config/buildexe
M scripts/Tools/case.build
M scripts/Tools/code_checker
M scripts/Tools/component_compare_test.sh
M scripts/Tools/preview_namelists
M scripts/create_newcase
M scripts/create_test
M utils/python/CIME/SystemTests/erp.py
M utils/python/CIME/SystemTests/lii.py
M utils/python/CIME/SystemTests/system_tests_common.py
M utils/python/CIME/XML/env_batch.py
M utils/python/CIME/build.py
M utils/python/CIME/case.py
M utils/python/CIME/preview_namelists.py
M utils/python/CIME/system_test.py
M utils/python/CIME/utils.py
M utils/python/tests/scripts_regression_tests.py
M utils/python/update_acme_tests.py

======================================================================

Originator: Jim Edwards
Date: July 22, 2016
Tag: cime5.0.2
Expand Down
12 changes: 9 additions & 3 deletions utils/python/CIME/user_mod_support.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,15 @@ def apply_user_mods(caseroot, user_mods_path, ninst=None):
'''
Recursivlely apply user_mods to caseroot - this includes updating user_nl_xxx,
updating SourceMods and creating case_shel_commands and xmlchange_cmds files
First remove case shell_commands files if any already exist
'''
case_shell_command_files = [os.path.join(caseroot,"shell_commands"),
os.path.join(caseroot,"xmlchange_cmnds")]
for shell_command_file in case_shell_command_files:
if os.path.isfile(shell_command_file):
os.remove(shell_command_file)

include_dirs = build_include_dirs_list(user_mods_path)
for include_dir in include_dirs:

Expand Down Expand Up @@ -70,9 +78,7 @@ def apply_user_mods(caseroot, user_mods_path, ninst=None):
with open(case_shell_commands, "a") as fd:
fd.write(new_shell_commands)

shell_command_files = [os.path.join(caseroot,"shell_commands"),
os.path.join(caseroot,"xmlchange_cmnds")]
for shell_command_file in shell_command_files:
for shell_command_file in case_shell_command_files:
if os.path.isfile(shell_command_file):
os.chmod(shell_command_file, 0777)
run_cmd_no_fail(shell_command_file)
Expand Down

0 comments on commit 1eb2a56

Please sign in to comment.