You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-07-30 19:23:07 +03:00
feat(mcs): MCOL-5300 review/finetune log collection tools.
* chore(mcs, scripts): extra/columnstore_review.sh with scripts/columnstore_review.sh with 1.4.13 version * feat(mcs): add review command to the Tools section. It's the wrapper for columnstore_review.sh * feat(mcs): add review command implementation to tools.py file + constansts.py * chore(mcs): add separator argument to cook_sh_arg function * docs(mcs): updated README.md and mcs.1 man file
This commit is contained in:
committed by
Alan Mologorsky
parent
d245ef33b1
commit
2c0367ea2b
@ -2,13 +2,17 @@
|
||||
from typing import Optional, Union
|
||||
|
||||
|
||||
def cook_sh_arg(arg_name: str, value: Union[str, int, bool]) -> Optional[str]:
|
||||
def cook_sh_arg(
|
||||
arg_name: str, value: Union[str, int, bool], separator: str = ' '
|
||||
) -> Optional[str]:
|
||||
"""Convert argument and and value from function locals to bash argument.
|
||||
|
||||
:param arg_name: function argument name
|
||||
:type arg_name: str
|
||||
:param value: function argument value
|
||||
:type value: Union[str, int, bool]
|
||||
:param separator: separator between argument and value
|
||||
:type separator: str
|
||||
:return: bash argument string or None
|
||||
:rtype: Optional[str]
|
||||
"""
|
||||
@ -31,4 +35,4 @@ def cook_sh_arg(arg_name: str, value: Union[str, int, bool]) -> Optional[str]:
|
||||
return None
|
||||
# if True value presented just pass only arg name without value
|
||||
value = ''
|
||||
return f'-{arg_name} {value}' if value else f'-{arg_name}'
|
||||
return f'-{arg_name}{separator}{value}' if value else f'-{arg_name}'
|
||||
|
Reference in New Issue
Block a user