-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrelink_model.sh
More file actions
executable file
·38 lines (32 loc) · 888 Bytes
/
relink_model.sh
File metadata and controls
executable file
·38 lines (32 loc) · 888 Bytes
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
# relink_model.sh
# Links
#
# * stan_pwa/src/model_def.hpp
# * stan_pwa/src/model.cpp
# * stan_pwa/src/model_inst.hpp
#
# to
#
# * <PWD>/src/model_def.hpp
# * <PWD>/src/model.cpp
# * <PWD>/src/model_inst.hpp
###### FUNCTIONS
function cd_stan_pwa
{
while [[ $PWD != '/' && ${PWD##*/} != 'stan_pwa' ]]; do cd ..; done
}
###### MAIN
# Define model directory and meson_deca directory
MODEL_DIR=$(pwd)
cd_stan_pwa
MDECA_DIR=$(pwd)
cd $MODEL_DIR
rm $MDECA_DIR/src/model_def.hpp
rm $MDECA_DIR/src/model.cpp
rm $MDECA_DIR/src/model_inst.hpp
rm $MDECA_DIR/src/model_wrapper.hpp
ln -s $MODEL_DIR/src/model_def.hpp $MDECA_DIR/src/model_def.hpp
#ln -s $MODEL_DIR/src/model.cpp $MDECA_DIR/src/model.cpp
ln -s $MODEL_DIR/src/model_inst.hpp $MDECA_DIR/src/model_inst.hpp
ln -s $MODEL_DIR/src/model_wrapper.hpp $MDECA_DIR/src/model_wrapper.hpp