x
authorJeff Davis <jdavis@sitka.bclibraries.ca>
Wed, 24 Jun 2015 22:08:21 +0000 (15:08 -0700)
committerJeff Davis <jdavis@sitka.bclibraries.ca>
Wed, 24 Jun 2015 22:08:21 +0000 (15:08 -0700)
deployment/install-osrf.sh

index 97f7e5d..9239fec 100755 (executable)
@@ -55,7 +55,7 @@ cd ${BUILDDIR} && make install
 useradd -m -s /bin/bash opensrf
 PATHFILES="/etc/profile /root/.bashrc /home/${DEFAULT_USER}/.bashrc /home/opensrf/.bashrc"
 for PATHFILE in ${PATHFILES} ; do
 useradd -m -s /bin/bash opensrf
 PATHFILES="/etc/profile /root/.bashrc /home/${DEFAULT_USER}/.bashrc /home/opensrf/.bashrc"
 for PATHFILE in ${PATHFILES} ; do
-  if [[ -e "${PATHFILE}" && ! `egrep "PATH=.*${INSTALLDIR}/bin" "${PATHFILE}"` ]] ; then 
+  if [[ ! -e "${PATHFILE}" || ! `egrep "PATH=.*${INSTALLDIR}/bin" "${PATHFILE}"` ]] ; then 
     echo "export PATH=${INSTALLDIR}/bin:\$PATH" >> ${PATHFILE}
   fi
 done
     echo "export PATH=${INSTALLDIR}/bin:\$PATH" >> ${PATHFILE}
   fi
 done