🐛 Fix argparse again
All checks were successful
dl / lint (push) Successful in 1m11s
dl / docker (push) Successful in 39s

This commit is contained in:
Michel Roux 2024-02-23 11:39:06 +01:00
parent 2f6d543528
commit 53e8590da6

View File

@ -7,9 +7,9 @@ from subprocess import run
from requests import get
parser = ArgumentParser()
parser.add_argument("path", nargs=1, default=[Path.cwd()])
parser.add_argument("path", nargs="?", default=Path.cwd())
args = parser.parse_args()
path = Path(args.path[0])
path = Path(args.path)
if not path.is_dir():
print("Invalid path")