Merge branch 'master' of git://gitorious.org/f-droid/fdroidserver

Conflicts:
	wp-fdroid/wp-fdroid.php
This commit is contained in:
Hans-Emil Skogh 2012-01-21 11:17:43 +01:00
commit 08c272b93d
19 changed files with 680 additions and 607 deletions

View file

@ -19,7 +19,7 @@
import glob, os, sys, re
import shutil
import subprocess
import time
def getvcs(vcstype, remote, local):
if vcstype == 'git':
@ -76,6 +76,8 @@ class vcs:
assert False # Must be defined in child
# Get new commits from the remote repository. Local must be clean.
# Fetch would really be a better name, as this doesn't necessarily
# (depending on the vcs) affect the local source tree or HEAD!
def pull(self):
assert False # Must be defined in child
@ -109,9 +111,6 @@ class vcs_git(vcs):
def pull(self):
self.checkrepo()
if subprocess.call(['git', 'pull', 'origin'],
cwd=self.local) != 0:
raise VCSException("Git pull failed")
# Might need tags that aren't on a branch.
if subprocess.call(['git', 'fetch', '--tags', 'origin'],
cwd=self.local) != 0:
@ -791,7 +790,10 @@ class KnownApks:
if os.path.exists(self.path):
for line in file( self.path):
t = line.rstrip().split(' ')
self.apks[t[0]] = t[1]
if len(t) == 2:
self.apks[t[0]] = (t[1], None)
else:
self.apks[t[0]] = (t[1], time.strptime(t[2], '%Y-%m-%d'))
self.changed = False
def writeifchanged(self):
@ -799,13 +801,20 @@ class KnownApks:
if not os.path.exists('stats'):
os.mkdir('stats')
f = open(self.path, 'w')
lst = []
for apk, app in self.apks.iteritems():
f.write(apk + ' ' + app + '\n')
appid, added = app
line = apk + ' ' + appid
if added:
line += ' ' + time.strftime('%Y-%m-%d', added)
lst.append(line)
for line in sorted(lst):
f.write(line + '\n')
f.close()
def recordapk(self, apk, app):
if not apk in self.apks:
self.apks[apk] = app
self.apks[apk] = (app, time.gmtime(time.time()))
self.changed = True
def getapp(self, apkname):

View file

@ -20,7 +20,9 @@ Build Version:1.9.2,78,v1.9.2
Build Version:1.9.3.1,80,v1.9.3.1
Build Version:1.9.5,82,v1.9.5
Build Version:1.9.6,83,v1.9.6
Build Version:1.9.7,84,v1.9.7,target=android-8
Market Version:1.9.6
Market Version Code:83
Update Check Mode:Market
Market Version:1.9.7
Market Version Code:84

View file

@ -14,7 +14,9 @@ Repo:http://www.beem-project.com/hg/trunk/
Build Version:0.1.5,7,0.1.5
Build Version:0.1.6,9,0.1.6
Build Version:0.1.7_rc1,10,0.1.7_rc1,target=android-8
Market Version:0.1.6
Market Version Code:9
Update Check Mode:Market
Market Version:0.1.7_rc1
Market Version Code:10

View file

@ -12,7 +12,8 @@ A git client - currently read-only.
Repo Type:git
Repo:https://github.com/rtyley/agit.git
Update Check Mode:Market
#No builds yet - another 'need to figure out how to make maven work' scenario
Market Version:1.25
Market Version Code:110900321
Market Version:1.27
Market Version Code:120101721

View file

@ -12,8 +12,9 @@ TODO/task management based on emacs org-mode files.
Repo Type:git
Repo:https://github.com/matburt/mobileorg-android.git
Update Check Mode:Market
#Needs dropbox consumer key
#Build Version:0.5.2,51,38dfe967ee99c71b12b8
Market Version:0.7.1
Market Version Code:71
Market Version:0.7.2
Market Version Code:72

View file

@ -5,10 +5,12 @@ Source Code:http://gitorious.org/acal
Issue Tracker:
Donate:http://acal.me/wiki/Donating
Summary:Calendar - CalDAV client
Summary:CalDAV Calendar & Tasks client
Description:
A CalDAV client, allowing you to directly access a calendar on a CalDAV
server.
server. aCal includes support for VEVENT & VTODO (Events and Tasks) and
can also synchronize your contacts from an addressbook collection on a
CardDAV server.
.
Repo Type:git
@ -27,7 +29,9 @@ Build Version:1.32,34,r1.32,target=android-8
Build Version:1.33,35,r1.33,target=android-8
Build Version:1.34,36,r1.34,target=android-8
Build Version:1.35,37,r1.35,target=android-8
Build Version:1.36,38,r1.36,target=android-8
Market Version:1.35
Market Version Code:37
Update Check Mode:Market
Market Version:1.36
Market Version Code:38

View file

@ -9,6 +9,7 @@ Description:
Internet Relay Chat client with a twin-pane view.
.
Market Version:2011.0622.1
Market Version Code:201106221
Update Check Mode:Market
Market Version:2012.0117.1
Market Version Code:201201171

View file

@ -19,7 +19,9 @@ Build Version:0.2.5,40,!source has wrong version code at r442,prebuild=mv lib/ l
Build Version:0.2.11,46,614,prebuild=mv lib/ libs/
#Still guessing, see previous comment
Build Version:0.3.1,48,659,prebuild=mv lib/ libs/
Build Version:0.4.4,54,957,prebuild=mv lib/ libs/
Market Version:0.4.3
Market Version Code:53
Update Check Mode:Market
Market Version:0.4.4
Market Version Code:54

View file

@ -21,8 +21,9 @@ Build Version:1.18,19,0b9985398b9eef7baf6aadd0dbb12002bc199d2e,subdir=org_adaway
Build Version:1.19,20,ab27f4dab5f3ea5e228cfb4a6b0e1fbf53695f22,subdir=org_adaway/,buildjni=yes,patch=defprop.patch
Build Version:1.20,21,695e3801e4081026c8f7213a2345fc451d5eb89c,subdir=org_adaway/,buildjni=yes,patch=defprop.patch
Build Version:1.21,22,65138c11cc8b6affd28b68e125fbc1dff0886a4e,subdir=org_adaway/,buildjni=yes,patch=defprop.patch
Build Version:1.23,24,!no source in repo
Market Version:1.21
Market Version Code:22
Update Check Mode:Market
Market Version:1.23
Market Version Code:24

View file

@ -54,8 +54,9 @@ Build Version:3.0.54-38,308,cr3.0.54-38,subdir=android,rm=android/build.properti
Build Version:3.0.54-47,447,cr3.0.54-47,subdir=android,rm=android/build.properties,buildjni=yes
Build Version:3.0.55-5,505,cr3.0.55-5,subdir=android,rm=android/build.properties,buildjni=yes
Build Version:3.0.55-9,509,cr3.0.55-9,subdir=android,rm=android/build.properties,buildjni=yes
Build Version:3.0.55-14,514,cr3.0.55-14,subdir=android,rm=android/build.properties,buildjni=yes
Update Check Mode:Market
Market Version:3.0.55-9
Market Version Code:509
Market Version:3.0.55-14
Market Version Code:514

View file

@ -3,7 +3,6 @@ License:GPLv3
Web Site:http://code.google.com/p/notification-plus/
Source Code:https://code.google.com/p/notification-plus/source/browse/
Issue Tracker:https://code.google.com/p/notification-plus/issues/list
Donate:
Summary:Recurring acoustic notifications
Description:
@ -17,3 +16,7 @@ Repo:https://code.google.com/p/notification-plus/
Build Version:1.1,2,396686558905
Update Check Mode:Market
Market Version:1.1
Market Version Code:2

View file

@ -16,7 +16,9 @@ Repo:http://daap-client.googlecode.com/svn/trunk
Build Version:.9.1,30,62
Build Version:.9.2,31,!Repo code is missing at least one file update - the manifest
Build Version:.9.6.2,38,!No corresponding source in repo
Build Version:.9.6.5,39,89
Market Version:.9.6.2
Market Version Code:38
Update Check Mode:Market
Market Version:.9.6.5
Market Version Code:39

View file

@ -35,7 +35,10 @@ Build Version:1.07,1075,1.07 (4),subdir=ttrss-reader,target=android-8
#Build Version:1.08,1080,1.08,subdir=ttrss-reader,target=android-8
Build Version:1.21,1210,1.21,subdir=ttrss-reader,target=android-8
Build Version:1.22,1220,1.22,subdir=ttrss-reader,target=android-8
#The 1.23 tag is wrong...
Build Version:1.23,1230,1e255c7e32ae,subdir=ttrss-reader,target=android-8
Market Version:1.22
Market Version Code:1220
Update Check Mode:Market
Market Version:1.23
Market Version Code:1230

View file

@ -21,6 +21,7 @@ Repo:http://android.svn.wordpress.org/trunk/
Build Version:1.3.9,31,202,prebuild=mkdir libs && mv *.jar libs && sed -i "s@checkStats(accounts.size());@// MY PRIVACY > YOUR STATS@" src/org/wordpress/android/wpAndroid.java,encoding=utf-8
Build Version:1.4.1,33,228,prebuild=mkdir libs && mv *.jar libs && sed -i "s@checkStats(accounts.size());@// MY PRIVACY > YOUR STATS@" src/org/wordpress/android/wpAndroid.java,encoding=utf-8
Market Version:2.0.3
Market Version Code:42
Update Check Mode:Market
Market Version:2.0.4
Market Version Code:43

View file

@ -20,8 +20,9 @@ Personal finance manager
Repo Type:bzr
Repo:lp:financisto
Market Version:1.5.4u1
Market Version Code:59
Update Check Mode:Market
Market Version:1.5.5
Market Version Code:60
# Build fails, wrong path to GreenDroid library
#Build Version:1.5.4,57,303,target=android-4

File diff suppressed because it is too large Load diff

View file

@ -27,6 +27,7 @@ import zipfile
import hashlib
from xml.dom.minidom import Document
from optparse import OptionParser
import time
#Read configuration...
repo_name = None
@ -79,6 +80,9 @@ apks = []
for apkfile in glob.glob(os.path.join('repo','*.apk')):
apkfilename = apkfile[5:]
if apkfilename.find(' ') != -1:
print "No spaces in APK filenames!"
sys.exit(1)
srcfilename = apkfilename[:-4] + "_src.tar.gz"
if not options.quiet:
@ -464,6 +468,32 @@ shutil.copyfile(repo_icon, iconfilename)
knownapks = common.KnownApks()
for apk in apks:
knownapks.recordapk(apk['apkname'], apk['id'])
app, added = knownapks.getapp(apk['apkname'])
if not added:
print 'Need a date for ' + apk['apkname']
p = subprocess.Popen('git log --format="%ci" metadata/' + apk['id'] + '.txt | tail -n 1',
shell=True, stdout = subprocess.PIPE)
d = p.communicate()[0][:10]
if len(d) == 0:
print "...didn't find a metadata commit"
else:
print '...metadata committed:' + d
if apk['apkname'].startswith(apk['id']):
vercode = int(apk['apkname'][len(apk['id'])+1:-4])
print '...built vercode:' + str(vercode)
expr = 'Build Version:[^,]+,' + str(vercode) + ',.*'
p = subprocess.Popen('git log --format="%ci" -S"' + expr + '" --pickaxe-regex metadata/' + apk['id'] + '.txt | tail -n 1',
shell=True, stdout = subprocess.PIPE)
d = p.communicate()[0][:10]
if len(d) > 0:
print '...build line added:' + d
print '...using that!'
knownapks.apks[apk['apkname']] = (apk['id'], time.strptime(d, '%Y-%m-%d'))
knownapks.changed = True
else:
print "...didn't find addition of build line"
knownapks.writeifchanged()
print "Finished."

View file

@ -112,10 +112,11 @@ for logfile in glob.glob(os.path.join(logsdir,'access-*.log')):
_, apkname = os.path.split(uri)
app = knownapks.getapp(apkname)
if app:
if app in apps:
apps[app] += 1
appid, _ = app
if appid in apps:
apps[appid] += 1
else:
apps[app] = 1
apps[appid] = 1
else:
if not apkname in unknownapks:
unknownapks.append(apkname)

View file

@ -103,7 +103,9 @@ class FDroid
function get_app($query_vars) {
global $permissions_data;
$permissions_object = new AndroidPermissions($this->site_path.'/repo/AndroidManifest.xml', $this->site_path.'/repo/strings.xml', $this->site_path.'/repo/android-permissions.cache');
$permissions_object = new AndroidPermissions($this->site_path.'/wp-content/plugins/wp-fdroid/AndroidManifest.xml',
$this->site_path.'/wp-content/plugins/wp-fdroid/strings.xml',
sys_get_temp_dir().'/android-permissions.cache');
$permissions_data = $permissions_object->get_permissions_array();
$xml = simplexml_load_file($this->site_path.'/repo/index.xml');