File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed
Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change 22
33# This script sets up the edX theme in LMS and CMS.
44
5- REPO_URL=
" [email protected] :edx/edx-themes.git" 5+ REPO_URL_HTTPS=" https://github.com/edx/edx-themes.git"
6+ REPO_URL_SSH=
" [email protected] :edx/edx-themes.git" 67THEME_DIR=" /edx/src/edx-themes/edx-platform"
78DEVSTACK_FILE=" ./py_configuration_files/lms.py"
89
910# Clone the edx-themes repository into the src directory
10- cd ../src
11+ mkdir -p ${DEVSTACK_WORKSPACE} /src
12+ pushd ${DEVSTACK_WORKSPACE} /src
1113if [ ! -d " edx-themes" ]; then
12- git clone " $REPO_URL "
14+ # Make a best effort to use SSH, but if that doesn't work then fallback to HTTPS.
15+ # Also make a best effort to avoid terminal prompting which breaks automation.
16+ GIT_TERMINAL_PROMPT=0 GIT_SSH_COMMAND=" ssh -o StrictHostKeyChecking=accept-new" git clone --depth=1 " $REPO_URL_SSH "
17+ [[ ! -d " edx-themes" ]] && GIT_TERMINAL_PROMPT=0 git clone --depth=1 " $REPO_URL_HTTPS "
1318else
1419 echo " Directory 'edx-themes' already exists. Skipping clone."
1520fi
16- cd ../devstack
21+ popd
1722
1823# Uncomment relevant lines in the devstack.py file
1924sed -i ' ' " s|^# from .common import _make_mako_template_dirs|from .common import _make_mako_template_dirs|" " $DEVSTACK_FILE "
You can’t perform that action at this time.
0 commit comments