CI combine file
Signed-off-by: shubhamchaudhary <shubham.chaudhary@mayadata.io>
This commit is contained in:
@@ -3,6 +3,7 @@ dist: xenial # ubuntu 16.04 distro
|
||||
script:
|
||||
# runs only when PR is merged
|
||||
- make versionmaker
|
||||
- make mergeExpCR
|
||||
after_success:
|
||||
# runs only when PR is merged and push the version file to master version
|
||||
- if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then make push; fi
|
||||
|
7
Makefile
7
Makefile
@@ -6,7 +6,12 @@ versionmaker:
|
||||
@echo "-----version maker-----"
|
||||
bash ./scripts/version_maker.sh
|
||||
|
||||
.PHONY: mergeExpCR
|
||||
push:
|
||||
@echo "--------merging experiment Crs-------"
|
||||
bash ./scripts/merge_all_cr.sh
|
||||
|
||||
.PHONY: push
|
||||
push:
|
||||
@echo "---------git push to master-------"
|
||||
bash ./scripts/push.sh
|
||||
bash ./scripts/push.sh
|
||||
|
12
scripts/merge_all_cr.sh
Normal file
12
scripts/merge_all_cr.sh
Normal file
@@ -0,0 +1,12 @@
|
||||
directories=$(ls -l ../charts/ | grep ^d | awk '{print $9}')
|
||||
for directory in $directories
|
||||
do
|
||||
echo -e "---\n" > ../charts/$directory/experiments.yaml
|
||||
subDirectories=$(ls -l ../charts/$directory | grep ^d | awk '{print $9}')
|
||||
for subDirectory in $subDirectories
|
||||
do
|
||||
cat ../charts/$directory/$subDirectory/experiment.yaml >> ../charts/$directory/experiments.yaml
|
||||
echo -e "\n---\n" >> ../charts/$directory/experiments.yaml
|
||||
done
|
||||
done
|
||||
|
Reference in New Issue
Block a user