mirror of
https://github.com/pyenv/pyenv.git
synced 2024-11-07 20:31:01 -05:00
rehash: preserve existing $PYENV_REHASH_TIMEOUT semantics
Try for that long no matter what the sleep step available is.
This commit is contained in:
parent
c0ea15226d
commit
b938abdea1
1 changed files with 2 additions and 1 deletions
|
@ -40,7 +40,8 @@ if [ ! -w "$SHIM_PATH" ]; then
|
|||
fi
|
||||
|
||||
unset acquired
|
||||
for (( i=1; i<="${PYENV_REHASH_TIMEOUT:-60}"; i++ )); do
|
||||
start=$SECONDS
|
||||
while (( SECONDS <= start + ${PYENV_REHASH_TIMEOUT:-60} )); do
|
||||
if acquire_lock 2>/dev/null; then
|
||||
acquired=1
|
||||
break
|
||||
|
|
Loading…
Reference in a new issue