Skip to content

Commit

Permalink
get rid of single quoted 'enable:': when tweaking site modules.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexanderRichert-NOAA committed Oct 10, 2023
1 parent c6ca42a commit 0370f7b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/jcsda-emc/spack-stack/stack/stack_env.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import copy
import io
import logging
import os
import re
Expand Down Expand Up @@ -163,8 +164,12 @@ def _copy_site_includes(self):
current_config = site_modules_yaml["modules"]["default"][current_sys]
site_modules_yaml["modules"]["default"][lmod_or_tcl] = current_config
del site_modules_yaml["modules"]["default"][current_sys]
# Write file, and get rid of annoying single quotes
stream = io.StringIO()
syaml.dump_config(site_modules_yaml, stream)
with open(site_modules_yaml_path, "w") as f:
syaml.dump_config(site_modules_yaml, f)
f.write(stream.getvalue().replace("'enable:':", "enable::"))


def _copy_package_includes(self):
"""Overwrite base packages in environment common dir"""
Expand Down

0 comments on commit 0370f7b

Please sign in to comment.