Skip to content

Commit

Permalink
Disable default debug mode in the installer and check for X session p…
Browse files Browse the repository at this point in the history
  • Loading branch information
strasharo committed Oct 3, 2016
1 parent 30e071d commit 184a26e
Showing 1 changed file with 18 additions and 3 deletions.
21 changes: 18 additions & 3 deletions Installer.sh
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
#!/bin/bash

INSTALLER_DEBUG=1
########## DEBUG Mode ##########
## ##
if [ -z ${INSTALLER_DEBUG+x} ]; then INSTALLER_DEBUG=0
else INSTALLER_DEBUG=1
fi
## ##
################################

#Config
version=2
revision=5
revision=6
#Colors
red='\e[1;31m'
blue='\e[1;34m'
Expand Down Expand Up @@ -39,6 +46,14 @@ fi

clear

#Check for X display

if [ -z "${DISPLAY:-}" ]; then
echo -e "\e[1;31mThe script should be executed inside a X (graphical) session."$transparent""
exit 1
fi



function mostrarheader(){

Expand Down Expand Up @@ -274,7 +289,7 @@ else
fi
sleep 0.025
##############################
echo -ne "Php5-cgi........"
echo -ne "Php-cgi........"
if ! hash php-cgi 2>/dev/null; then
echo -e "\e[1;31mInstalling ..."$transparent""
xterm $HOLD -title "Installing Php5-cgi" $TOPLEFTBIG -bg "#FFFFFF" -fg "#000000" -e apt-get --yes install php-cgi
Expand Down

0 comments on commit 184a26e

Please sign in to comment.