summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2012-04-24 09:01:59 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2012-04-24 09:01:59 +0000
commitbf0b28da6b4d69a653cb76e9e45618cccb2e0889 (patch)
tree2098e54bda4aa1b10283135adaaf8895afa42490
parent41e28f11ba2d0367375858fa754519a66f2e056a (diff)
downloadabuild-bf0b28da6b4d69a653cb76e9e45618cccb2e0889.tar.gz
abuild-bf0b28da6b4d69a653cb76e9e45618cccb2e0889.tar.bz2
abuild-bf0b28da6b4d69a653cb76e9e45618cccb2e0889.tar.xz
abuild-bf0b28da6b4d69a653cb76e9e45618cccb2e0889.zip
abuild: create group before user
-rwxr-xr-xabuild.in12
1 files changed, 6 insertions, 6 deletions
diff --git a/abuild.in b/abuild.in
index c460ad4..2780d2e 100755
--- a/abuild.in
+++ b/abuild.in
@@ -486,6 +486,12 @@ cleanoldpkg() {
mkusers() {
local i
+ for i in $pkggroups; do
+ if ! getent group $i >/dev/null; then
+ msg "Creating group $i"
+ $ADDGROUP -S $i || return 1
+ fi
+ done
for i in $pkgusers; do
if ! getent passwd $i >/dev/null; then
local gopt=
@@ -496,12 +502,6 @@ mkusers() {
$ADDUSER -S -D -H $gopt $i || return 1
fi
done
- for i in $pkggroups; do
- if ! getent group $i >/dev/null; then
- msg "Creating group $i"
- $ADDGROUP -S $i || return 1
- fi
- done
}