Skip to content

Commit

Permalink
icm install: Install multiple packages
Browse files Browse the repository at this point in the history
  • Loading branch information
Obijuan committed Jun 26, 2024
1 parent 230ebfc commit 2af015d
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"type": "debugpy",
"request": "launch",
"program": "icm-run.py",
"args": ["install","iceK"],
"args": ["install","iceK", "iceWires"],
//"console": "internalConsole",
"console": "integratedTerminal",
"justMyCode": true,
Expand Down
3 changes: 1 addition & 2 deletions icm/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,7 @@ def info():


@cli.command()
@click.pass_context
@click.argument("coltag", nargs=1)
@click.argument("coltag", nargs=-1)
@click.option(
"-d", "--dev", is_flag=True, help="Install latest development version"
)
Expand Down
15 changes: 8 additions & 7 deletions icm/commands/cmd_install.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
from icm.commons import commons


def main(coltag: str, dev: bool) -> None:
def main(coltags: tuple, dev: bool) -> None:
"""ENTRY POINT: Install collections
* coltag: Nombre de la coleccion + tag opcional
Ex. iceK, [email protected]
* coltag: tupla de nombres de la coleccion + tag opcional
Ex. (iceK, [email protected])
* dev: Install development version
"""

Expand All @@ -20,14 +20,15 @@ def main(coltag: str, dev: bool) -> None:

print()

# -- Install the collection!
install_main(collection, coltag, dev)
# -- Install the collections!
for coltag in coltags:
install_collection(collection, coltag, dev)


def install_main(
def install_collection(
collection: commons.Collection, coltag: str, dev: bool = False
) -> None:
"""Main function for installing collections
"""Main function for installing only one collection
* collection: Collection class (context)
* coltag: name + version tag (Ex. [email protected])
* dev: Development flag
Expand Down

0 comments on commit 2af015d

Please sign in to comment.