Skip to content

Commit

Permalink
update warmup.py
Browse files Browse the repository at this point in the history
  • Loading branch information
ryichsecondary committed Nov 29, 2024
1 parent 7d6221c commit 43e437e
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions warmup.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,15 +129,10 @@ def install_oh_my_zsh():


def run(command, cwd="/tmp"):
pardir = os.path.dirname(os.getcwd())
if pardir == "/" or pardir == "/root":
if not os.path.exists("warmup.py"):
print("Please run this script in the same directory as warmup.py")
sys.exit(1)
subprocess.run(command, shell=True, cwd=cwd)
else:
print("Please run this script in the parent directory of root")
if not os.path.exists("warmup.py"):
print("Please run this script in the same directory as warmup.py")
sys.exit(1)
subprocess.run(command, shell=True, cwd=cwd)


def setup():
Expand Down

0 comments on commit 43e437e

Please sign in to comment.