Created
February 27, 2015 20:28
-
-
Save tonyxiao/cad2a0d550a2f1ce1b34 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from urlparse import urlparse, parse_qs | |
import urllib2 | |
import plistlib | |
import webbrowser | |
print 'Enter url copied from Crashlytics Beta iOS webpage' | |
print 'Should look like itms-services://?action=download-manifest&url=https%3A%2F%2Fapps.crashlytics.com%2Fprojects...' | |
itms_url = raw_input('Enter item-services url: ') | |
result = urlparse(itms_url) | |
params = parse_qs(result.query) | |
plist_url = params['url'][0] | |
plist_content = urllib2.urlopen(plist_url).read() | |
plist = plistlib.readPlistFromString(plist_content) | |
ipa_url = plist['items'][0]['assets'][0]['url'] | |
print 'IPA URL is' | |
print ipa_url | |
print 'Opening in default browser' | |
webbrowser.open(ipa_url) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment