Commit d0b29ff0 authored by Ryan Greenblatt's avatar Ryan Greenblatt Committed by Marc Cornellà
Browse files

pip: fix no such file or directory error (#7916)

Zsh may be configured such that ">>" will error if the file doesn't exist (`setopt noclobber`). 
parent 702a594d
...@@ -29,6 +29,7 @@ zsh-pip-cache-packages() { ...@@ -29,6 +29,7 @@ zsh-pip-cache-packages() {
if [[ ! -f $ZSH_PIP_CACHE_FILE ]]; then if [[ ! -f $ZSH_PIP_CACHE_FILE ]]; then
echo -n "(...caching package index...)" echo -n "(...caching package index...)"
tmp_cache=/tmp/zsh_tmp_cache tmp_cache=/tmp/zsh_tmp_cache
touch $tmp_cache
for index in $ZSH_PIP_INDEXES ; do for index in $ZSH_PIP_INDEXES ; do
# well... I've already got two problems # well... I've already got two problems
curl -L $index 2>/dev/null | \ curl -L $index 2>/dev/null | \
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment