Use URL-encoded PIP_FIND_LINKS to support spaces in paths

This commit is contained in:
Richard Berger
2021-04-30 18:18:58 -04:00
parent ee0e48ff86
commit dfa9f15817
2 changed files with 4 additions and 3 deletions

View File

@ -7,8 +7,10 @@ then
exit 1
fi
URL_ENCODED_PATH="$(python3 -c "import urllib.parse; print(urllib.parse.quote(input()))" <<< "$PIP_CACHE_DIR")"
export PIP_NO_INDEX=1
export PIP_FIND_LINKS="$PIP_CACHE_DIR"
export PIP_FIND_LINKS="file://$URL_ENCODED_PATH"
echo "Disabling pip index and use local cache directory..."