Skip to content
This repository has been archived by the owner on Jul 19, 2023. It is now read-only.

Commit

Permalink
Merge pull request #66 from keisukefukuda/change-yml-to-json
Browse files Browse the repository at this point in the history
changed from YAML to JSON
  • Loading branch information
keisukefukuda committed Jul 14, 2017
2 parents 05768a9 + 7dfea73 commit ad7e2a7
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions common.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import distutils.spawn
import glob
import json
import os.path
import re
import shutil
Expand All @@ -10,7 +11,6 @@
from subprocess import PIPE
from subprocess import Popen
import sys
import yaml

from mpienv.ompi import parse_ompi_info
from mpienv.py import MPI4Py
Expand Down Expand Up @@ -275,10 +275,10 @@ def _load_mpi_info(self):
self._installed[name] = info

def _load_config(self):
conf_yml = os.path.join(self._root_dir, "config.yml")
if os.path.exists(conf_yml):
with open(conf_yml) as f:
conf = yaml.load(f)
conf_json = os.path.join(self._root_dir, "config.json")
if os.path.exists(conf_json):
with open(conf_json) as f:
conf = json.load(f)
else:
sys.stderr.write("Warning: Cannot find config file\n")
conf = {}
Expand Down

0 comments on commit ad7e2a7

Please sign in to comment.