summaryrefslogtreecommitdiff
path: root/src/backend/check.py
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-08-18 12:26:10 +0100
committerV3n3RiX <venerix@redcorelinux.org>2020-08-18 12:26:10 +0100
commita71ffe9cd09164182584bb01b3993881f7766dfd (patch)
tree3131c0ac94300b27d5983249f54769ec95a89689 /src/backend/check.py
parentf28b67f3d6910f71e20da86367205f3c3660ff72 (diff)
make sisyphus.check.root more portable, replace it everywhere
Diffstat (limited to 'src/backend/check.py')
-rw-r--r--src/backend/check.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/backend/check.py b/src/backend/check.py
index a129d36..fb760cc 100644
--- a/src/backend/check.py
+++ b/src/backend/check.py
@@ -1,13 +1,12 @@
#!/usr/bin/python3
import os
-import sys
import subprocess
import sisyphus.filesystem
def root():
- if not os.getuid() == 0:
- sys.exit("\nYou need root permissions to do this, exiting!\n")
+ if os.getuid() == 0:
+ return 0
def portage():
if os.path.isdir(os.path.join(sisyphus.filesystem.portageRepoDir, '.git')):