Skip to content

Commit

Permalink
change arg names of copy/migrate
Browse files Browse the repository at this point in the history
  • Loading branch information
sylvaingaudan committed Oct 24, 2024
1 parent 2efab48 commit ff432a2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions arlas/cli/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,24 +39,24 @@ def describe(

@indices.command(help="Clone an index and set its name")
def clone(
index: str = typer.Argument(help="Source index name"),
name: str = typer.Argument(help="Target cloned index name")
source: str = typer.Argument(help="Source index name"),
target: str = typer.Argument(help="Target cloned index name")
):
config = variables["arlas"]
indices = Service.clone_index(config, index, name)
indices = Service.clone_index(config, source, target)
tab = PrettyTable(indices[0], sortby="name", align="l")
tab.add_rows(indices[1:])
print(tab)


@indices.command(help="Migrate an index on another arlas configuration, and set the target index name")
def migrate(
index: str = typer.Argument(help="Source index name"),
source: str = typer.Argument(help="Source index name"),
arlas_target: str = typer.Argument(help="Target ARLAS Configuration name"),
name: str = typer.Argument(help="Target migrated index name")
target: str = typer.Argument(help="Target migrated index name")
):
config = variables["arlas"]
indices = Service.migrate_index(config, index, arlas_target, name)
indices = Service.migrate_index(config, source, arlas_target, target)
tab = PrettyTable(indices[0], sortby="name", align="l")
tab.add_rows(indices[1:])
print(tab)
Expand Down

0 comments on commit ff432a2

Please sign in to comment.