mirror of
https://gitlab.com/JKANetwork/JKArch.git
synced 2026-02-19 03:31:32 +01:00
fixes..
This commit is contained in:
@@ -9,6 +9,14 @@
|
|||||||
## $5 -> Is a "various-sentence command"? (1 -> First / Not lastest, 2 -> Last )
|
## $5 -> Is a "various-sentence command"? (1 -> First / Not lastest, 2 -> Last )
|
||||||
function comm {
|
function comm {
|
||||||
local command
|
local command
|
||||||
|
local multic
|
||||||
|
# Do not permit that $5 is empty. For multicommand/multisentence checks
|
||||||
|
if [[ -z "$5" ]];then
|
||||||
|
multic="0"
|
||||||
|
else
|
||||||
|
multic=$5
|
||||||
|
fi
|
||||||
|
|
||||||
# First complete the command, if necessary
|
# First complete the command, if necessary
|
||||||
if [[ $3 == "chroot" ]];then
|
if [[ $3 == "chroot" ]];then
|
||||||
command="chroot /mnt /bin/bash -c \"$4\""
|
command="chroot /mnt /bin/bash -c \"$4\""
|
||||||
@@ -31,10 +39,10 @@ function comm {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Update multiSentence var
|
# Update multiSentence var
|
||||||
if [[ $5 == "1" ]];then
|
if [[ $multic == "1" ]];then
|
||||||
multiSentence="1"
|
multiSentence="1"
|
||||||
fi
|
fi
|
||||||
if [[ $5 == "2" ]];then
|
if [[ $multic == "2" ]];then
|
||||||
multiSentence="0"
|
multiSentence="0"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -44,7 +52,7 @@ function comm {
|
|||||||
echo "[ ERROR ] $1" >> /tmp/install.log
|
echo "[ ERROR ] $1" >> /tmp/install.log
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ $? == "0" ] && [ $5 != "1" ];then
|
if [ $? == "0" ] && [ $multic != "1" ];then
|
||||||
echo "[ OK ] $1"
|
echo "[ OK ] $1"
|
||||||
echo "[ OK ] $1" >> /tmp/install.log
|
echo "[ OK ] $1" >> /tmp/install.log
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user