Skip already installed package.

This commit is contained in:
Sleepy Monax 2023-02-17 21:19:27 +01:00
parent c5f66d6c9b
commit 1ac7390d5e

View file

@ -1,4 +1,5 @@
from typing import Callable, cast
import os
from osdk.args import Args
from osdk.context import contextFor
@ -174,6 +175,10 @@ def installCmd(args: Args):
extPath = f"{const.EXTERN_DIR}/{extSpec}"
if os.path.exists(extPath):
print(f"Skipping {extSpec}, already installed")
continue
print(f"Installing {extSpec}-{ext.tag} from {ext.git}...")
shell.popen("git", "clone", "--depth", "1", "--branch",
ext.tag, ext.git, extPath)