mirror of
https://github.com/MaskRay/ccls.git
synced 2025-01-19 03:55:49 +00:00
[travis] Retry. (#221)
This commit is contained in:
parent
c8040a3b9e
commit
f23a79b01d
@ -32,7 +32,7 @@ os: linux
|
||||
cache:
|
||||
directories:
|
||||
- build/clang+llvm-5.0.1-x86_64-linux-gnu-ubuntu-14.04/
|
||||
- build/clang+llvm-5.0.1-final-x86_64-apple-darwin/
|
||||
- build/clang+llvm-5.0.1-x86_64-apple-darwin/
|
||||
|
||||
matrix:
|
||||
fast_finish: true
|
||||
@ -193,7 +193,7 @@ before_script:
|
||||
- ${CXX} --version
|
||||
|
||||
script:
|
||||
- ./waf configure
|
||||
- travis_retry ./waf configure
|
||||
- ./waf build
|
||||
- ./build/release/bin/cquery --log-all-to-stderr --test-unit
|
||||
- ./build/release/bin/cquery --log-all-to-stderr --test-index
|
||||
|
10
wscript
10
wscript
@ -2,9 +2,9 @@
|
||||
# encoding: utf-8
|
||||
|
||||
try:
|
||||
from urllib2 import urlopen, URLError # Python 2
|
||||
from urllib2 import urlopen # Python 2
|
||||
except ImportError:
|
||||
from urllib.request import urlopen, URLError # Python 3
|
||||
from urllib.request import urlopen # Python 3
|
||||
|
||||
import os.path
|
||||
import string
|
||||
@ -100,13 +100,7 @@ def download_and_extract(destdir, url, ext):
|
||||
print(' destination: {0}'.format(dest))
|
||||
print(' source: {0}'.format(url))
|
||||
# TODO: verify checksum
|
||||
for _ in range(5):
|
||||
try:
|
||||
response = urlopen(url, timeout=60)
|
||||
break
|
||||
except URLError:
|
||||
print('Retry')
|
||||
continue
|
||||
with open(dest, 'wb') as f:
|
||||
f.write(response.read())
|
||||
else:
|
||||
|
Loading…
Reference in New Issue
Block a user