Skip to content

Commit

Permalink
Update avalon core and forwards CLI commands to load correctly.
Browse files Browse the repository at this point in the history
  • Loading branch information
tokejepsen committed May 21, 2018
1 parent 45c7860 commit b66db78
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 5 deletions.
20 changes: 16 additions & 4 deletions avalon.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ def main():
parser.add_argument("--init", action="store_true",
help="Establish a new project in the "
"current working directory")
parser.add_argument("--load", action="store_true",
parser.add_argument("--load", nargs="?", default=False,
help="Load project at the current working directory")
parser.add_argument("--save", action="store_true",
help="Save project from the current working directory")
Expand Down Expand Up @@ -281,9 +281,21 @@ def main():
"avalon.inventory", "--init"])

elif kwargs.load:
returncode = forward([
sys.executable, "-u", "-m",
"avalon.inventory", "--load"])
returncode = forward(
[
sys.executable,
"-u",
"-m",
"avalon.inventory",
"--load",
kwargs.load
]
)

elif kwargs.load is None:
returncode = forward(
[sys.executable, "-u", "-m", "avalon.inventory", "--load"]
)

elif kwargs.save:
returncode = forward([
Expand Down
2 changes: 1 addition & 1 deletion git/avalon-core
Submodule avalon-core updated 105 files

0 comments on commit b66db78

Please sign in to comment.