Verified Commit 4dc89e3a authored by Laurent Heirendt's avatar Laurent Heirendt
Browse files

set folder named based on branch

parent 45f4a340
......@@ -9,11 +9,14 @@ echo $rootDir
rm -rf $rootDir/public
mkdir $rootDir/public
# create img folders
#mkdir $rootDir/public/img
#mkdir $rootDir/public/img/unstable
#mkdir $rootDir/public/img/latest
#mkdir $rootDir/public/img/stable
# define the branch
if [[ $CI_COMMIT_BRANCH == "develop" ]]; then
version="latest"
elif [[ $CI_COMMIT_BRANCH == "master" ]]; then
version="stable"
else
version="unstable"
fi
# loop through all the presentations
nBlades=0
......@@ -32,9 +35,7 @@ do
# create the required folders in public
mkdir $rootDir/public/$BLADE
#mkdir $rootDir/public/$BLADE/unstable
mkdir $rootDir/public/$BLADE/latest
#mkdir $rootDir/public/$BLADE/stable
mkdir $rootDir/public/$BLADE/$version
# change to the blade directory to be built
cd $BLADE
......@@ -53,7 +54,7 @@ do
yarn install
grunt dist
mv public/* $rootDir/public/$BLADE/latest/.
mv public/* $rootDir/public/$BLADE/$version/.
echo " > latest built for file set ${BLADE}"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment