Apache Solr open-source search software
SOLR-682: Add free bsd support to scripts
Grant Ingersoll954abed4b250
diff --git a/CHANGES.txt b/CHANGES.txtindex 0a6912d2726..55476a3ce92 100644--- a/CHANGES.txt+++ b/CHANGES.txt@@ -583,6 +583,8 @@ Other Changeslinks more resilient to configs loaded via an InputStream(Lars Kotthoff, hossman)+21. SOLR-682: Scripts now support FreeBSD (Richard Trey Hyde via gsingers)+Build1. SOLR-411. Changed the names of the Solr JARs to use the defacto standard JAR names based onproject-name-version.jar. This yields, for example:diff --git a/src/scripts/abc b/src/scripts/abcindex 285f7291402..64e85733d75 100755--- a/src/scripts/abc+++ b/src/scripts/abc@@ -175,7 +175,7 @@ trap 'echo cleaning up, please wait ...;/bin/rm -rf ${data_dir}/${name} ${data_d# make a backup using hard links into temporary location# then move it into place atomically-if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" ]]+if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" || "${OS}" == "FreeBSD" ]]thenorig_dir=$(pwd)mkdir ${data_dir}/${temp}diff --git a/src/scripts/abo b/src/scripts/aboindex 03c1b44b0c4..a42f7c47e7a 100755--- a/src/scripts/abo+++ b/src/scripts/abo@@ -175,7 +175,7 @@ trap 'echo cleaning up, please wait ...;/bin/rm -rf ${data_dir}/${name} ${data_d# make a backup using hard links into temporary location# then move it into place atomically-if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" ]]+if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" || "${OS}" == "FreeBSD"]]thenorig_dir=$(pwd)mkdir ${data_dir}/${temp}diff --git a/src/scripts/backup b/src/scripts/backupindex 89ee5f667bd..7584028d8da 100755--- a/src/scripts/backup+++ b/src/scripts/backup@@ -101,7 +101,7 @@ logMessage making backup ${data_dir}/${name}# make a backup using hard links into temporary location# then move it into place atomically-if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" ]]+if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" || "${OS}" == "FreeBSD" ]]thenorig_dir=$(pwd)mkdir ${data_dir}/${temp}diff --git a/src/scripts/snapcleaner b/src/scripts/snapcleanerindex 0111c2c1d89..8c1cae62c3e 100755--- a/src/scripts/snapcleaner+++ b/src/scripts/snapcleaner@@ -91,7 +91,7 @@ fifunction remove{- if [[ "${OS}" == "Darwin" ]]+ if [[ "${OS}" == "Darwin" || "${OS}" == "FreeBSD" ]]thensyncing=`ps -www -U ${user} |grep -w rsync|grep -v grep|grep -w $1`elsediff --git a/src/scripts/snapinstaller b/src/scripts/snapinstallerindex 67f0229889d..ec94201e299 100755--- a/src/scripts/snapinstaller+++ b/src/scripts/snapinstaller@@ -141,7 +141,7 @@ fi# install using hard links into temporary directory# remove original index and then atomically copy new one into placelogMessage installing snapshot ${name}-if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" ]]+if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" || "${OS}" == "FreeBSD" ]]thenorig_dir=$(pwd)mkdir ${data_dir}/index.tmp$$ && \diff --git a/src/scripts/snappuller b/src/scripts/snappullerindex 4b6b98abffb..fd081ca31f4 100755--- a/src/scripts/snappuller+++ b/src/scripts/snappuller@@ -200,7 +200,7 @@ fi# take a snapshot of current index so that only modified files will be rsync-ed# put the snapshot in the 'work-in-progress" directory to prevent it from# being installed while the copying is still in progress-if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" ]]+if [[ "${OS}" == "SunOS" || "${OS}" == "Darwin" || "${OS}" == "FreeBSD" ]]thenorig_dir=$(pwd)mkdir ${data_dir}/${name}-wip