Skip to content

Commit 028ab7c

Browse files
committed
srload: Cleanup when running outside buildtree
The original syntax did not work and the initial intention, that root is always required is also false.
1 parent cc03a59 commit 028ab7c

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

utils/srload

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,8 @@ source "$1"
1414
# optional env variable override
1515
if [ -n "$SYSREPOCTL_EXECUTABLE" ]; then
1616
SYSREPOCTL="$SYSREPOCTL_EXECUTABLE"
17-
elif [ "$(id -u)" -eq 0 ] && [ -n "$USER" ] && [ -n "$(command -v su)" ]; then
18-
SYSREPOCTL=$(command sysrepoctl -l "$USER")
1917
else
20-
SYSREPOCTL=$(command sysrepoctl)
18+
SYSREPOCTL=sysrepoctl
2119
fi
2220

2321
PERMS="660"
@@ -91,7 +89,6 @@ enable()
9189
fi
9290
}
9391

94-
9592
# Skip first 5 lines of header and last 3 lines of footer
9693
SCTL_MODULES=$($SYSREPOCTL -l |tail -n +5 |head -n -3)
9794

0 commit comments

Comments
 (0)