Changeset - fb70be1e6729
[Not reviewed]
default
0 1 0
Thomas De Schampheleire (patrickdp) - 5 years ago 2020-03-01 19:51:03
thomas.de.schampheleire@gmail.com
cli: fix '--full' option of index-create

The option '-f' or '--full' is actually a flag, but the current declaration
made click expect a value as argument.

Instead, follow the click convention to allow --full and --no-full, to
indicate it is a boolean flag, as we do in other places.
1 file changed with 1 insertions and 1 deletions:
0 comments (0 inline, 0 general) First comment
kallithea/bin/kallithea_cli_index.py
Show inline comments
 
@@ -36,7 +36,7 @@ from kallithea.model.repo import RepoMod
 
@click.option('--repo-location', help='Base path of repositories to index. Default: all')
 
@click.option('--index-only', help='Comma-separated list of repositories to build index on. Default: all')
 
@click.option('--update-only', help='Comma-separated list of repositories to re-build index on. Default: all')
 
@click.option('-f', '--full', 'full_index', help='Recreate the index from scratch')
 
@click.option('-f', '--full/--no-full', 'full_index', help='Recreate the index from scratch')
 
def index_create(repo_location, index_only, update_only, full_index):
 
    """Create or update full text search index"""
 

	
0 comments (0 inline, 0 general) First comment
You need to be logged in to comment. Login now