forked from exoplanet-dev/exoplanet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun_notebooks.sh
executable file
·38 lines (27 loc) · 1.04 KB
/
run_notebooks.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/bin/bash
__conda_setup="$('conda' 'shell.bash' 'hook' 2> /dev/null)"
eval "$__conda_setup"
unset __conda_setup
cd /mnt/home/dforeman/research/projects/exoplanet-dev/exoplanet_auto
conda activate autoexoplanet
CACHEDIR=/mnt/home/dforeman/research/projects/exoplanet-dev/exoplanet_auto/theano_cache
rm -rf $CACHEDIR
export THEANO_FLAGS=base_compiledir=$CACHEDIR
git checkout master
git pull origin master
python setup.py develop
git branch -D auto_notebooks
git checkout -b auto_notebooks master
cd docs
conda env export > auto_environment.yml
python run_notebooks.py $*
cp notebooks/notebook_setup.py _static/notebooks/notebook_setup.py
git add _static/notebooks/notebook_setup.py
git add _static/notebooks/*.ipynb
git -c user.name='exoplanetbot' -c user.email='exoplanetbot' commit -am "updating notebooks [ci skip]"
git push -q -f https://dfm:`cat .github_api_key`@github.com/exoplanet-dev/exoplanet.git auto_notebooks
cd ..
git checkout master
mail -s "autoexoplanet finished" "[email protected]" <<EOF
run_notebooks finished running
EOF