generated from GrafeasGroup/template-repo
-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Labels
enhancementNew feature or requestNew feature or request
Description
We can factor out this logic into a separate function and reuse it:
Bubbles/bubbles/commands/update_and_restart.py
Lines 115 to 123 in 6888e73
| # spawn a new child that is separate from the parent process so that it doesn't | |
| # die immediately as we respawn the parent | |
| # https://stackoverflow.com/a/16928558 | |
| subprocess.Popen( | |
| shlex.split(f"sudo systemctl restart {USERNAME}"), | |
| stdout=open("/dev/null", "w"), | |
| stderr=open("logfile.log", "a"), | |
| preexec_fn=os.setpgrp, | |
| ) |
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request