Fix ssl error
This commit is contained in:
parent
2b9b42d5f7
commit
557286ff79
|
@ -23,7 +23,7 @@ if os.path.exists('../contrib/crowdin_api_key.txt'):
|
|||
crowdin_api_key = open('../contrib/crowdin_api_key.txt').read().strip()
|
||||
# Push to Crowdin
|
||||
print 'Push to Crowdin'
|
||||
url = ('http://api.crowdin.net/api/project/' + crowdin_identifier + '/update-file?key=' + crowdin_api_key)
|
||||
url = ('http://api.crowdin.com/api/project/' + crowdin_identifier + '/update-file?key=' + crowdin_api_key)
|
||||
c = pycurl.Curl()
|
||||
c.setopt(c.URL, url)
|
||||
c.setopt(c.POST, 1)
|
||||
|
@ -32,12 +32,12 @@ if os.path.exists('../contrib/crowdin_api_key.txt'):
|
|||
c.perform()
|
||||
# Build translations
|
||||
print 'Build translations'
|
||||
response = requests.request('GET', 'http://api.crowdin.net/api/project/' + crowdin_identifier + '/export?key=' + crowdin_api_key).content
|
||||
response = requests.request('GET', 'http://api.crowdin.com/api/project/' + crowdin_identifier + '/export?key=' + crowdin_api_key).content
|
||||
print response
|
||||
|
||||
# Download & unzip
|
||||
print 'Download translations'
|
||||
zfobj = zipfile.ZipFile(StringIO(requests.request('GET', 'http://crowdin.net/download/project/' + crowdin_identifier + '.zip').content))
|
||||
zfobj = zipfile.ZipFile(StringIO(requests.request('GET', 'http://crowdin.com/download/project/' + crowdin_identifier + '.zip').content))
|
||||
|
||||
print 'Unzip translations'
|
||||
for name in zfobj.namelist():
|
||||
|
|
Loading…
Reference in New Issue