Skip to content

Commit

Permalink
Deal with case of missing PATH
Browse files Browse the repository at this point in the history
  • Loading branch information
m3nu committed Dec 11, 2024
1 parent f186589 commit cf60b16
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/vorta/borg/borg_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,8 @@ def prepare_bin(cls):
# More info at https://github.com/borgbase/vorta/issues/2100
# Set the path to also find homebrew installs of Borg, and avoid falling back to the embedded binary.
if sys.platform == 'darwin':
os.environ["PATH"] += ":/opt/homebrew/bin:/usr/local/bin"
current_path = os.environ.get("PATH", "")
os.environ["PATH"] = f"{current_path}:/opt/homebrew/bin:/usr/local/bin"
# Now continue looking for the borg binary to use
borg_in_path = shutil.which('borg')

Expand Down

0 comments on commit cf60b16

Please sign in to comment.