vpu.sh: re-read restricted config after writing it
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -40,7 +40,7 @@ function checkSetup() {
|
||||
# Check Dependencies and handle admin rights method
|
||||
|
||||
local setAllowRestricted="XBPS_ALLOW_RESTRICTED=yes"
|
||||
local checkAllowRestricted=$(cat ${repoPath}/etc/conf)
|
||||
local checkAllowRestricted=$(cat ${repoPath}/etc/conf 2>/dev/null)
|
||||
|
||||
|
||||
if [ -f /usr/bin/sudo ];then
|
||||
@@ -100,9 +100,10 @@ function checkSetup() {
|
||||
|
||||
if [ "${checkAllowRestricted}" != "${setAllowRestricted}" ];then
|
||||
echo "${setAllowRestricted}" > ${repoPath}/etc/conf
|
||||
checkAllowRestricted=$(cat ${repoPath}/etc/conf 2>/dev/null)
|
||||
|
||||
if [ "${checkAllowRestricted}" != "${setAllowRestricted}" ];then
|
||||
printf "${LRED} Could enable restricted software building...[check failed]${NC}\n"
|
||||
printf "${LRED}Could not enable restricted software building...[check failed]${NC}\n"
|
||||
restrictedCheck="Failed"
|
||||
fi
|
||||
|
||||
@@ -188,7 +189,7 @@ case "${1}" in
|
||||
${adminCmd} xbps-install -R ${repoPath}/hostdir/binpkgs ${package}
|
||||
;;
|
||||
|
||||
install-nonfree|-inf|-inf)
|
||||
install-nonfree|-inf|inf)
|
||||
${repoPath}/xbps-src pkg ${package}
|
||||
if [ -f /usr/bin/sudo ];then
|
||||
adminCmd="sudo"
|
||||
|
||||
Reference in New Issue
Block a user