Skip to content

Commit

Permalink
fix install fixer
Browse files Browse the repository at this point in the history
  • Loading branch information
kiorky committed Jun 29, 2023
1 parent 1ad678c commit ca01772
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions bin/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1327,13 +1327,17 @@ reinstall_egg_path() {
install -U --force-reinstall --no-deps -e . )
}

try_fix_ansible() {
bs_log "Try to fix ansible tree"
local COPS_PYTHON=${COPS_PYTHON:-$(get_cops_python)}
try_fix_deps() {
if ! ( $COPS_PYTHON -m pip --version );then
log "Trying to install missing dependencies(fix)"
install_prerequisites || die "install prereqs(fix) failed"
DO_INSTALL_PREREQUISITES=y install_prerequisites || die "install prereqs(fix) failed"
fi
}

try_fix_ansible() {
bs_log "Try to fix ansible tree"
local COPS_PYTHON=${COPS_PYTHON:-$(get_cops_python)}
try_fix_deps
if ( noisy_test_ansible_state 2>&1| grep -iq pkg_resources.DistributionNotFound ) &&
[ -e "$(get_eggs_src_dir)/ansible/.git" ] && \
( $COPS_PYTHON -m pip --version >/dev/null 2>&1 );then
Expand Down

0 comments on commit ca01772

Please sign in to comment.