Skip to content

Commit

Permalink
Merge pull request #68 from ESMCI/fix_nonfleximod_submodule_checkout
Browse files Browse the repository at this point in the history
if not fxtag is available tag=hash
  • Loading branch information
jedwards4b authored Dec 27, 2024
2 parents 50bd54c + 004194f commit 574d2b0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion git_fleximod/git_fleximod.py
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,8 @@ def init_submodule_from_gitmodules(gitmodules, name, root_dir, logger):
url = gitmodules.get(name, "url")
assert path and url, f"Malformed .gitmodules file {path} {url}"
tag = gitmodules.get(name, "fxtag")
if not tag:
tag = gitmodules.get(name, "hash")
fxurl = gitmodules.get(name, "fxDONOTUSEurl")
fxsparse = gitmodules.get(name, "fxsparse")
fxrequired = gitmodules.get(name, "fxrequired")
Expand Down Expand Up @@ -250,7 +252,6 @@ def submodules_update(gitmodules, root_dir, requiredlist, force):
newrequiredlist = ["AlwaysRequired"]
if optional:
newrequiredlist.append("AlwaysOptional")

submodules_update(gitsubmodules, repodir, newrequiredlist, force=force)

def local_mods_output():
Expand Down

0 comments on commit 574d2b0

Please sign in to comment.