2021.4.6 #25

Merged
edraft merged 57 commits from 2021.4.6 into 2021.4.post1 2021-04-11 15:54:38 +02:00
2 changed files with 6 additions and 5 deletions
Showing only changes of commit cfb6a84799 - Show all commits

View File

@ -120,6 +120,9 @@ class Configuration(ConfigurationABC):
if found and child_argument_type.name not in self._additional_arguments: if found and child_argument_type.name not in self._additional_arguments:
self._additional_arguments.append(child_argument_type.name) self._additional_arguments.append(child_argument_type.name)
if found:
break
if not found: if not found:
raise Exception(f'Invalid argument: {argument}') raise Exception(f'Invalid argument: {argument}')
@ -197,8 +200,7 @@ class Configuration(ConfigurationABC):
# ?new value # ?new value
found = False found = False
for alias in argument_type.aliases: for alias in argument_type.aliases:
alias = f' {alias} ' if alias == argument or f' {alias} ' == argument:
if alias in argument:
found = True found = True
if argument_type.name not in argument and not found: if argument_type.name not in argument and not found:
@ -212,6 +214,7 @@ class Configuration(ConfigurationABC):
value = '' value = ''
else: else:
value = next_arguments[0] value = next_arguments[0]
next_arguments.remove(value)
self._handled_args.append(value) self._handled_args.append(value)
if argument_type.token != '' and argument.startswith(argument_type.token): if argument_type.token != '' and argument.startswith(argument_type.token):
@ -237,7 +240,7 @@ class Configuration(ConfigurationABC):
self._additional_arguments.append(argument_type.name) self._additional_arguments.append(argument_type.name)
result = True result = True
if result and value == '': if result:
self._handled_args.append(argument) self._handled_args.append(argument)
if next_arguments is not None and len(next_arguments) > 0: if next_arguments is not None and len(next_arguments) > 0:
next_args = [] next_args = []

View File

@ -102,8 +102,6 @@ class GenerateService(CommandABC):
rel_path = '/'.join(parts[:-1]) rel_path = '/'.join(parts[:-1])
class_name = parts[len(parts) - 1] class_name = parts[len(parts) - 1]
Console.write_line(rel_path)
if 'src' not in rel_path: if 'src' not in rel_path:
rel_path = f'src/{rel_path}' rel_path = f'src/{rel_path}'