diff --git a/bin/chroot-run.in b/bin/chroot-run.in index d650b94..ca669e2 100644 --- a/bin/chroot-run.in +++ b/bin/chroot-run.in @@ -83,13 +83,13 @@ copy_hostconf () { if [[ -n ${build_mirror} ]];then build_mirror=${build_mirror}'/$repo/$arch' if ${keep_mirrors}; then - source $1/etc/pacman-mirrors.conf + Branch=$(cat "$1/etc/pacman-mirrors.conf" | grep '^Branch = ' | sed 's/Branch = \s*//g') sed -e "s|/stable|/${Branch}|g" -i "$1/etc/pacman.d/mirrorlist" else echo "Server = ${build_mirror}" > "$1/etc/pacman.d/mirrorlist" fi else - source $1/etc/pacman-mirrors.conf + Branch=$(cat "$1/etc/pacman-mirrors.conf" | grep '^Branch = ' | sed 's/Branch = \s*//g') sed -e "s|/stable|/${Branch}|g" -i "$1/etc/pacman.d/mirrorlist" fi diff --git a/data/pacman-mirrors-stable.conf b/data/pacman-mirrors-stable.conf index 6b66971..4a8d615 100644 --- a/data/pacman-mirrors-stable.conf +++ b/data/pacman-mirrors-stable.conf @@ -3,7 +3,7 @@ ## ## Branch Pacman should use (stable, testing, unstable) -# Branch = stable +Branch = stable ## Generation method ## 1) rank - rank mirrors depending on their access time @@ -25,4 +25,4 @@ ## pacman-mirrors is invoked with the --no-update argument. ## Useful if you don't want the mirrorlist regenerated after a ## pacman-mirrors package upgrade. -# NoUpdate = False \ No newline at end of file +# NoUpdate = False