summaryrefslogtreecommitdiff
path: root/src/util.py
diff options
context:
space:
mode:
authordavidovski <git@davidovski.xyz>2021-11-10 12:13:01 +0000
committerdavidovski <git@davidovski.xyz>2021-11-10 12:13:01 +0000
commit0d72a2b411e66e656662a5287971b17856ea5a67 (patch)
tree4689828fe5b903ccfbaed3f91843207763d78d6a /src/util.py
parent1e84d95edd19519f5d8cedf82b376bb376178bef (diff)
added package info downloading
Diffstat (limited to 'src/util.py')
-rw-r--r--src/util.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/util.py b/src/util.py
index 3badca0..16df7bc 100644
--- a/src/util.py
+++ b/src/util.py
@@ -7,6 +7,9 @@ import os
DEFAULT_BAR_COLOR = colors.BLACK + colors.BG_CYAN
DEFAULT_BAR_COLOR_RESET = colors.BG_BLACK + colors.CYAN
+def add_path(a, b):
+ return a + (b if a[-1] == "/" else f"/{b}")
+
def loading_bar(completed, total, text,
unit="", color=DEFAULT_BAR_COLOR, reset=DEFAULT_BAR_COLOR_RESET):