From: Claire Mouton Date: Wed, 2 Apr 2014 15:24:21 +0000 (+0200) Subject: Added a new installation mode : via git repository without authentification (option... X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=1c504ce22d2ad945d8ead7ee7df63284a9830a56;p=creaToolsTools.git Added a new installation mode : via git repository without authentification (option -git-read-only). Provides a read-only acceess. --- diff --git a/Linux/installscript b/Linux/installscript index c20e72e..8f9ae93 100755 --- a/Linux/installscript +++ b/Linux/installscript @@ -206,6 +206,7 @@ function usage { echo " -instprefix : creatools install prefix" echo " -instprefix3 : 3rd party library install prefix" echo " -git : get creatools from git (CREATIS user only)" + echo " -git-read-only : get creatools from git (anonymously, no write access)" echo " -build : build type Release, RelWithDebug or Debug (default RelWithDebug)" echo "" echo " experimental configure options (use at your own risk!!):" @@ -227,6 +228,8 @@ while [ $# -ge 1 ] ; do -instprefix3) installPrefixThird=$2; shift 2;; -doc) docgeneration=ON; shift 1;; -git) sourcesFrom=GIT; shift 1;; + -git-read-only) sourcesFrom=GIT-READ-ONLY; +shift 1;; -gdcm2) gdcmVersion=GDCM2; shift 1;; -itk4) ITKVersion=ITK4; shift 1;; -build) buildType=$2; shift 2;; diff --git a/Linux/scripts/CreaTools-load.sh b/Linux/scripts/CreaTools-load.sh index 60b38f5..2a52833 100644 --- a/Linux/scripts/CreaTools-load.sh +++ b/Linux/scripts/CreaTools-load.sh @@ -104,20 +104,20 @@ then #if [ true = false ] then # - if [ $sourcesFrom = GIT ] + if [ $sourcesFrom = GIT ] || [ $sourcesFrom = GIT-READ-ONLY ]; then - bash $scriptDir/gitclone.sh $creasource $generationdir - bash $scriptDir/gitclone.sh $bbtksource $generationdir - bash $scriptDir/gitclone.sh $creamaracassource $generationdir - bash $scriptDir/gitclone.sh $creaenvironmentsource $generationdir - bash $scriptDir/gitclone.sh $creabrukersource $generationdir - bash $scriptDir/gitclone.sh $creaimagesource $generationdir - bash $scriptDir/gitclone.sh $creacontourssource $generationdir - bash $scriptDir/gitclone.sh $crearigidregistrationssource $generationdir - bash $scriptDir/gitclone.sh $bbtkgeditorsource $generationdir - bash $scriptDir/gitclone.sh $creatoolssource $generationdir - bash $scriptDir/gitclone.sh $creaminitoolssource $generationdir - bash $scriptDir/gitclone.sh $creatoolstoolssource $generationdir + bash $scriptDir/gitclone.sh $creasource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $bbtksource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $creamaracassource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $creaenvironmentsource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $creabrukersource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $creaimagesource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $creacontourssource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $crearigidregistrationssource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $bbtkgeditorsource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $creatoolssource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $creaminitoolssource $generationdir $sourcesFrom + bash $scriptDir/gitclone.sh $creatoolstoolssource $generationdir $sourcesFrom # bash $scriptDir/cvscheckout.sh $libidosource-ESRF $generationdir $cvsUserName # mv $libidosource-ESRF $libidosource fi diff --git a/Linux/scripts/gitclone.sh b/Linux/scripts/gitclone.sh index 064c187..24bcb57 100644 --- a/Linux/scripts/gitclone.sh +++ b/Linux/scripts/gitclone.sh @@ -1,8 +1,17 @@ #$1 creasource #$2 generationdir +#$3 sourcesFrom (either GIT or GIT-READ-ONLY) - cd $2/creatools_source + +if [ $sourcesFrom = GIT ] +then git clone ssh://gitolite@git.creatis.insa-lyon.fr/$1 + +else # $sourcesFrom = GIT-READ-ONLY , anonymous access +git clone git://git.creatis.insa-lyon.fr/$1 + +fi + cd ..