From: Chris Sharp Date: Mon, 24 Feb 2014 13:00:33 +0000 (-0500) Subject: adding a script to ease the installation of Dyrcona's evergreen utilities X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=a077240ca38eed70e86b05e077a82c58a3f835cd;p=contrib%2Fpines.git adding a script to ease the installation of Dyrcona's evergreen utilities --- diff --git a/setup_evergreen_utilities.sh b/setup_evergreen_utilities.sh new file mode 100755 index 0000000..e4e43ad --- /dev/null +++ b/setup_evergreen_utilities.sh @@ -0,0 +1,64 @@ +#!/bin/bash + +# A program to quickly download and configure Jason Stephenson's evergreen_utilities repo. + +EG_USER="admin" +EG_PASS="gamma4pines" +EG_WORKSTATION="STATELIB-L-csharp-desktop" +APT_TOOL="/usr/bin/apt-get" +GIT_USER="opensrf" +GIT_HOME="/home/$GIT_USER" +REPO_LIST="evergreen_utilities backstage JSONPrefs" +BIN_DIR="$GIT_HOME/bin" +LIB_DIR="$GIT_HOME/lib/perl" +PREFS_DIR="$GIT_HOME/myprefs.d" +DIR_LIST="$BIN_DIR $LIB_DIR $PREFS_DIR" +EXPORT_PATH="export PATH=$PATH:$BIN_DIR" +EXPORT_PERL5LIB="export PERL5LIB=$PERL5LIB:$LIBDIR" +read -d '' EG_JSON < $PREFS_DIR/evergreen.json" + +for line in $EXPORT_PATH $EXPORT_PERL5LIB; do + su - $GIT_USER -C "echo $line >> ~/.bashrc" +done; +echo "As the $GIT_USER user, please 'source ~/.bashrc' after this script is completed."