This commit is contained in:
Kload 2013-10-24 12:06:40 +02:00
parent 16da07772d
commit f136823b26
2 changed files with 18 additions and 14 deletions

View file

@ -31,7 +31,7 @@ fi
echo "Check dependencies" echo "Check dependencies"
apt-get update -qq apt-get update -qq
for i in lsb-release wget whiptail for i in lsb-release wget dialog whiptail
do do
dpkg -l | grep -q $i dpkg -l | grep -q $i
if [[ $? -eq 1 ]] if [[ $? -eq 1 ]]
@ -88,12 +88,14 @@ then
echo "deb http://repo.yunohost.org/ megusta main" >> $CUSTOMAPT echo "deb http://repo.yunohost.org/ megusta main" >> $CUSTOMAPT
fi fi
if [[ "$1" == "test" ]]; then if [ $# -gt 0 ]; then
grep -qri "test" $CUSTOMAPT if [[ "$1" == "test" ]]; then
if [ $# -eq 1 ]; then grep -qri "test" $CUSTOMAPT
echo "deb http://repo.yunohost.org/ test main" >> $CUSTOMAPT if [ $# -eq 1 ]; then
fi echo "deb http://repo.yunohost.org/ test main" >> $CUSTOMAPT
fi fi
fi
fi
#Get gpg key #Get gpg key
wget -O- http://repo.yunohost.org/yunohost.asc -q | apt-key add - -qq wget -O- http://repo.yunohost.org/yunohost.asc -q | apt-key add - -qq

View file

@ -32,7 +32,7 @@ echo "======== YunoHost Installation ========"
echo "======== Check dependences ========" echo "======== Check dependences ========"
apt-get update -qq apt-get update -qq
for i in lsb-release wget whiptail for i in lsb-release wget dialog whiptail
do do
dpkg -l | grep -q $i dpkg -l | grep -q $i
if [[ $? -eq 1 ]] if [[ $? -eq 1 ]]
@ -90,12 +90,14 @@ then
echo "deb http://repo.yunohost.org/ megusta main" >> $CUSTOMAPT echo "deb http://repo.yunohost.org/ megusta main" >> $CUSTOMAPT
fi fi
if [[ "$1" == "test" ]]; then if [ $# -gt 0 ]; then
grep -qri "test" $CUSTOMAPT if [[ "$1" == "test" ]]; then
if [ $# -eq 1 ]; then grep -qri "test" $CUSTOMAPT
echo "deb http://repo.yunohost.org/ test main" >> $CUSTOMAPT if [ $# -eq 1 ]; then
fi echo "deb http://repo.yunohost.org/ test main" >> $CUSTOMAPT
fi fi
fi
fi
#Get gpg key #Get gpg key
wget -O- http://repo.yunohost.org/yunohost.asc -q | apt-key add - -qq wget -O- http://repo.yunohost.org/yunohost.asc -q | apt-key add - -qq