mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-07 06:08:02 +02:00
makerepo: detect centpkg for CentOS Stream dist-git
This commit is contained in:
parent
8e8e2f5efd
commit
ac0742c7df
1 changed files with 8 additions and 3 deletions
|
|
@ -84,11 +84,16 @@ if [[ "x$(ls -1d ./*.spec 2>/dev/null)" == x || ! -f "./sources" ]]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ "$FEDPKG" == "" ]]; then
|
if [[ "$FEDPKG" == "" ]]; then
|
||||||
REMOTES="$(git remote -v 2>/dev/null)" || die "not inside dist-git repository? >>$PWD<<"
|
REMOTE="$(git config --get "branch.$(git branch --show-current).remote" 2>/dev/null)"
|
||||||
if echo "$REMOTES" | grep -q -F 'pkgs.devel.redhat.com' ; then
|
URL="$(git config --get "remote.$REMOTE.url")"
|
||||||
|
if [[ "$URL" = *'pkgs.devel.redhat.com'* ]]; then
|
||||||
FEDPKG=rhpkg
|
FEDPKG=rhpkg
|
||||||
else
|
elif [[ "$URL" = *'gitlab.com:redhat/centos-stream'* ]]; then
|
||||||
|
FEDPKG=centpkg
|
||||||
|
elif [[ "$URL" = *'pkgs.fedoraproject.org/'* ]]; then
|
||||||
FEDPKG=fedpkg
|
FEDPKG=fedpkg
|
||||||
|
else
|
||||||
|
die "not inside dist-git repository? Check out a branch that has the dist-git remote tracking branch >>$PWD<<"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue