fix wrong complementary arguments

This commit is contained in:
Maximilian Keßler 2021-10-22 11:59:11 +02:00
parent a10709dd3b
commit 4dde7d2e11

View file

@ -9,7 +9,6 @@ from PyTeX.build.build.config import FILENAME_TYPE_RAW_NAME, FILENAME_TYPE_PREPE
def main(): def main():
parser = argparse.ArgumentParser(description='Incrementally build LatexPackages with PyTeX') parser = argparse.ArgumentParser(description='Incrementally build LatexPackages with PyTeX')
input_group = parser.add_mutually_exclusive_group(required=True) input_group = parser.add_mutually_exclusive_group(required=True)
output_group = parser.add_mutually_exclusive_group()
input_group.add_argument( input_group.add_argument(
'-s', '--source-dir', '-s', '--source-dir',
metavar='SRC_DIR', metavar='SRC_DIR',
@ -19,7 +18,7 @@ def main():
default='./src', default='./src',
dest='src_dir' dest='src_dir'
) )
output_group.add_argument( parser.add_argument(
'-b', '--build-dir', '-b', '--build-dir',
metavar='BUILD_DIR', metavar='BUILD_DIR',
help='Relativ or absolute path to output directory for processed packages and classes', help='Relativ or absolute path to output directory for processed packages and classes',
@ -41,7 +40,7 @@ def main():
type=pathlib.Path, type=pathlib.Path,
dest='input_file' dest='input_file'
) )
output_group.add_argument( parser.add_argument(
'-n', '--name', '-n', '--name',
help='Name of the package / class to be formatted.', help='Name of the package / class to be formatted.',
type=str, type=str,