Skip to content

Commit

Permalink
add chown with os.environ
Browse files Browse the repository at this point in the history
  • Loading branch information
Niccolo Raspa committed Jul 12, 2023
1 parent 95b8890 commit 67caf59
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion installer.py
Original file line number Diff line number Diff line change
Expand Up @@ -658,7 +658,7 @@ def download_binary(network):

if platform.system() == "Linux":
subprocess.run(["sudo", "mv", "/tmp/osmosisd", binary_path], check=True)
subprocess.run(["sudo", "chown", f"{os.getlogin()}:{os.getlogin()}", binary_path], check=True)
subprocess.run(["sudo", "chown", f"{os.environ['USER']}:{os.environ['USER']}", binary_path], check=True)
subprocess.run(["sudo", "chmod", "+x", binary_path], check=True)
else:
subprocess.run(["mv", "/tmp/osmosisd", binary_path], check=True)
Expand Down

0 comments on commit 67caf59

Please sign in to comment.