1
0
mirror of https://gitlab.com/fdroid/fdroidserver.git synced 2024-11-14 11:00:10 +01:00
Commit Graph

299 Commits

Author SHA1 Message Date
Ciaran Gultnieks
b2f1cedb40 Fix update, broken in 7ac0c5abb2 2014-08-08 12:34:37 +01:00
Ciaran Gultnieks
1c5d5c0bce Improve 'no sdk version found' output 2014-08-08 12:34:16 +01:00
Daniel Martí
7ac0c5abb2 update: use sets for permissions and features to avoid duplicates 2014-08-05 23:04:21 +02:00
Ciaran Gultnieks
f5890646e6 Put lastbuild log on wiki by vercode (with redirect) 2014-07-17 14:05:16 +01:00
Daniel Martí
d110c24eff Find aapt as part of the main config initialisation 2014-07-03 00:31:07 +02:00
Daniel Martí
e8284225c9 Improve some log levels 2014-07-01 20:32:49 +02:00
Daniel Martí
1a1bdfc3d9 Merge branch 'bug-fixes-for-v0.2.1' of https://gitlab.com/eighthave/fdroidserver 2014-07-01 18:13:00 +02:00
Daniel Martí
8888962ace Rename PopenResult.stdout to output since it also contains stderr 2014-07-01 18:04:41 +02:00
Hans-Christoph Steiner
d0c767ce5e only move GPG signature if APK exists
The .asc moving code just needed to be indented so it only runs when
'srcname' exists in apk[], otherwise it just throws a KeyError
2014-06-30 23:01:48 -04:00
Hans-Christoph Steiner
3dbe503071 check repo icons exist now before running through all of fdroid update
Before, if repo_icon or archive_icon pointed to a non-existent file, then
`fdroid update` would run through the whole process of building a repo,
then fail at the very end because of the non-existent file.  On the next
run, `fdroid update` then starts from the beginning.

This just checks for those files at the beginning, and exits with an error
if they are not found.
2014-06-30 23:01:47 -04:00
Ciaran Gultnieks
1a11982897 Move gpg signatures to archive along with the other files 2014-06-30 22:53:02 +01:00
Daniel Martí
c750b02a6c Always run aapt with SilentPopen 2014-06-30 16:15:14 +02:00
Ciaran Gultnieks
95d8f29479 Fix nasty problem caused by 7c2e61a4 2014-06-25 11:43:44 +01:00
Daniel Martí
14f865a5b1 Don't use logging.info with verbose ifs 2014-06-22 21:28:33 +02:00
Hans-Christoph Steiner
13baea9558 some APKs do not have a name, like system APKs
It is not necessarily a good idea to try to distribute system APKs via
FDroid, but `fdroid update` should just ignore APKs it cannot handle rather
than die and prevent a repo from being fully created.  This is necessary to
handle the automatic creation of repos, like for debug builds from a
Jenkins server.
2014-06-04 22:01:25 -04:00
Hans-Christoph Steiner
c81ff764a3 update: improve warning about APKs set to be debuggable
This uses the actual XML code used to set this flag making the warning
message easily searchable on the interwebs.
2014-06-04 22:01:25 -04:00
Hans-Christoph Steiner
d68830418b apps with no <uses-sdk> get strange values of minSdkVersion
Using this example app which does not have <uses-sdk>:
https://android.googlesource.com/platform/development/+log/master/samples/ApiDemos/assets/HelloActivity.apk

aapt then returns "sdkVersion:'IceCreamSandwich'".  minSdkVersion is only
ever supposed to be an integer, so this is a bizarre APK.  It is included
only as a binary in the git repo for Android sample code.  But who knows
what else is out there, so report and error and carry on with the update
process.
2014-06-04 22:01:25 -04:00
Hans-Christoph Steiner
57a4e03277 update: skip APKs that cannot be parsed instead of exiting
Some APKs can be corrupt or some system APKs do not have all the normal
info.  Instead of quitting, `fdroid update` skips the non-parsable APKs and
optionally deletes them if --delete-unknown is specified.
2014-06-04 22:01:25 -04:00
Hans-Christoph Steiner
ed73db65ae make FDroidPopen output based on --verbose
FDroidPopen outputs by default, this should be controlled by the --verbose
flag so that most of the time, only meaningful messages are shown like
errors and such.  For command output that should be shown everytime,
output=True can be set.
2014-06-04 22:01:25 -04:00
Hans-Christoph Steiner
c6d946ed54 update: remove overly verbose message about icon sizing being correct
This seems like purely a debug message, I can't see why its useful in general
2014-06-04 22:01:25 -04:00
Hans-Christoph Steiner
78d5ebf26c use 'metadata' name throughout: --createmeta to --create-metadata
To keep the naming used within fdroid consistent, I renamed this long flag
to use the whole word 'metadata' since that is what is used everywhere else
2014-06-04 21:54:56 -04:00
Daniel Martí
3d72c30fe5 Use ordered dicts for defaults in apps and builds 2014-05-31 23:54:50 +02:00
Hans-Christoph Steiner
6839f9a9ed fixes #12: make fdroid update -c do complete update like fdroid update
Since the new metadata created by -c is added after the existing metadata
was already parsed, `fdroid update -c` was not doing a complete update of
the repo.  This moves the metadata creation as early as possible, then
reruns the metadata parsing if new metadata was created.

refs #12 https://gitlab.com/fdroid/fdroidserver/issues/12
2014-05-29 15:29:57 -04:00
Hans-Christoph Steiner
af22962572 Fixes #8: if unknown APKs found, prompt to use -c or use --delete-unknown
This adds the option --delete-unknown for the current default behavior of
`fdroid update`: to delete any unknown APKs.  Instead, it just outputs a
warning about the unknown APKs and suggests -c for adding it.

Fixes #8 https://gitlab.com/fdroid/fdroidserver/issues/8
2014-05-29 13:40:06 -04:00
Daniel Martí
0f0ccdb1e1 Fix some more pep8 warnings 2014-05-28 09:33:14 +02:00
Daniel Martí
93a56e4f51 Fall back to launchable-activity label if application has none
This fixes apps like MiniZip not having a name
2014-05-23 09:47:11 +02:00
Daniel Martí
17a4f5c00f A few more PEP8 fixes 2014-05-07 16:17:46 +02:00
Hans-Christoph Steiner
37d6d87ff7 fix PEP8 "E226 missing whitespace around arithmetic operator" 2014-05-06 14:36:33 -04:00
Hans-Christoph Steiner
0e00b36db5 fix PEP8 E124/E125/126/127/128 indentation issues
* E124 closing bracket does not match visual indentation
* E125 continuation line does not distinguish itself from next logical line
* E126 continuation line over-indented for hanging indent
* E127 continuation line over-indented for visual indent
* E128 continuation line under-indented for visual indent
2014-05-06 14:36:33 -04:00
Hans-Christoph Steiner
aa5f317c26 fix PEP8 "W391 blank line at end of file" 2014-05-06 11:45:03 -04:00
Hans-Christoph Steiner
16dc3b27d6 fix PEP8 "E303 too many blank lines (2)" 2014-05-06 11:45:03 -04:00
Hans-Christoph Steiner
69989d4758 fix PEP8 "E302 expected 1 blank lines, found 0" 2014-05-06 11:45:03 -04:00
Hans-Christoph Steiner
3f4f7a544b fix PEP8 "E302 expected 2 blank lines, found 1" 2014-05-06 11:45:03 -04:00
Hans-Christoph Steiner
2f2618e06c fix PEP8 "E401 multiple imports on one line" 2014-05-06 11:45:03 -04:00
Hans-Christoph Steiner
7e17fafc14 fix PEP8 "E225 missing whitespace around operator" 2014-05-06 11:45:03 -04:00
Hans-Christoph Steiner
c54cabe741 fix PEP8 "E228 missing whitespace around modulo operator" 2014-05-06 11:45:03 -04:00
Hans-Christoph Steiner
58a484e74e fix PEP8 "W291 trailing whitespace" 2014-05-06 11:45:02 -04:00
Hans-Christoph Steiner
998011d535 fix PEP8 "E231 missing whitespace after ','" 2014-05-06 11:45:02 -04:00
Hans-Christoph Steiner
f1812d5935 fix PEP8 "E203 whitespace before ':' or ','" 2014-05-06 11:45:02 -04:00
Hans-Christoph Steiner
5e93b6c80b update: report signing key fingerprint in same format as client
fdroidclient now uses SHA256 fingerprints internally, and they are shown in
the repo details view.  This changes the digest algorithm to SHA256 and
changes the format to match what is shown in the repo details view.
2014-04-25 21:07:47 -04:00
Hans-Christoph Steiner
1ca7949bb1 if using crypto smartcard, remind user to plug it in 2014-04-22 22:59:27 -04:00
Ciaran Gultnieks
81e6fb8eb5 Point wiki current/history links to gitlab 2014-04-11 16:44:33 +01:00
Hans-Christoph Steiner
3829d37d34 support repo signing with a key on a smartcard
This assumes that the smartcard is already setup with a signing key.  init
does not generate a key on the smartcard, and skips genkey() if things are
configured to use a smartcard.

This also does not touch APK signing because that is a much more elaborate
question, since each app is signed by its own key.
2014-04-07 16:00:18 -04:00
Hans-Christoph Steiner
2bd62239f7 'smartcardoptions' config item for setting up HSMs with fdroid
These options are needed to configure Java's keytool and jarsigner to use
a Hardware Security Module aka HSM aka smartcard.  The defaults provided
are meant to make things work as easily as possible.
2014-04-07 16:00:18 -04:00
Hans-Christoph Steiner
0950cdac09 make repo_keyalias like a config option: leave it commented out
Before, the code relies on repo_keyalias being None, which does not feel
conffile-like.  Now, its commented out if its not set.
2014-04-07 16:00:18 -04:00
Hans-Christoph Steiner
e53092cffa fix genkey key listing in fdroid init
FDroidPopen() does not have a way to send to stdin, so we will use the
password file for now.  In the long run, at least the keypass should always
be sent via stdin rather than via a file.  Ideally, storepass would be too,
but if they are different, then storepass is less important.
2014-04-01 18:04:36 -04:00
Hans-Christoph Steiner
525759b235 stop passing passphrases via args, instead use prepared files
Any process can read the process table, and can therefore see the entire
command line of any other process.  That means its a bad idea to ever put
passwords as part of a command line.  Python is executing keytool and
jarsigner command lines here, so now instead of putting the password on the
command line, a file is passed instead with suitable file permissions.
This should reduce the exposure a lot.  But still, sensitive passwords
should not be written to any text file.

This change requires OpenJDK-7 since the :file option to -storepass and
-keypass was only added in Java 7's keytool and jarsigner.
2014-03-31 21:02:42 -04:00
Daniel Martí
6c6a9c4bb2 Revert "Wrap maintainer notes in <pre> to keep newlines and formatting"
This reverts commit 94bb9d9355.
2014-03-25 09:41:55 +01:00
Daniel Martí
94bb9d9355 Wrap maintainer notes in <pre> to keep newlines and formatting 2014-03-24 15:11:05 +01:00
Ciaran Gultnieks
78bee1990c Remove apks with no metadata (unless told to create it) 2014-03-04 23:36:50 +00:00
Ciaran Gultnieks
cb92ea1598 Fixed some logging levels for wiki update, apk cache, etc 2014-02-22 10:00:29 +00:00
Ciaran Gultnieks
37dda9414c Add --quiet option, restricting output to warnings/errors 2014-02-22 09:46:24 +00:00
Daniel Martí
8888cd6339 Add support for maxSdkVersion, bump index version integer 2014-02-19 17:30:06 +01:00
Daniel Martí
3483bad392 Make app['Categories'] a list, get unique categories via a set 2014-02-19 10:27:38 +01:00
Daniel Martí
d192b40687 Can't update an app if there is no CV 2014-02-17 16:51:22 +01:00
Daniel Martí
ec0de6b370 Do some warnings properly 2014-02-07 21:38:28 +01:00
Daniel Martí
0b6faa5f22 Try to fix some TypeErrors 2014-02-07 21:36:19 +01:00
Daniel Martí
7bf74d47bb Typo 2014-02-03 14:07:01 +01:00
Daniel Martí
8b26f4b319 Merge branch 'master' into logging 2014-01-31 09:14:03 +01:00
Hans-Christoph Steiner
2d6f3f8cec use https URI for f-droid.org everywhere and avoid redirects
Now that f-droid.org defaults to https, use only https URIs to save
redirects and leak less info.
2014-01-30 20:32:38 -05:00
Daniel Martí
2f93ba9bd6 Merge branch 'master' into logging
Conflicts:
	fdroidserver/common.py
2014-01-28 14:14:59 +01:00
Daniel Martí
3687147997 Update my own copyright notices 2014-01-28 14:07:19 +01:00
Daniel Martí
e20fa9d7f4 Half-way done switching prints for logs 2014-01-27 21:49:01 +01:00
Daniel Martí
62c3663df3 Lots more FDroidPopen replacements 2014-01-27 21:48:22 +01:00
Daniel Martí
f277ba6b33 Avoid more possible crashes when invalid icons are present 2014-01-24 12:55:43 +01:00
Ciaran Gultnieks
5ac41e7ca7 Lose some spurious 'apps to update' entries from wiki 2014-01-20 11:50:48 +00:00
Ciaran Gultnieks
450685fe2f Resolve some missing wiki category issues 2014-01-16 08:58:49 +00:00
Daniel Martí
a7f259e7cc Don't crash if the app icons are wrong 2014-01-14 10:28:23 +01:00
Ciaran Gultnieks
5f736e1410 Transfer apk info when archiving
Just dropping this apk entry temporarily caused an old version of the
app to appear on the wiki as a failing build. (only for one cycle after
the archiving happened). Moving it to the archived apks list ought to
resolve that problem.
2014-01-09 12:35:26 +00:00
Daniel Martí
afcadf2e6a Fix: Re-add <icon> element to index 2014-01-07 19:22:07 +01:00
Daniel Martí
71db41b869 Bump index version to 11, add index version changelog 2014-01-07 17:59:02 +01:00
Daniel Martí
f37d00507b Avoid possible crashes
* No 160 dpi icon available
* Trying to resize a non-existing icon
* Non-dpi icon being lower density than ldpi
2014-01-07 17:05:04 +01:00
Daniel Martí
77b6974303 Support application and launchable-activity icons as fallback 2014-01-07 17:01:51 +01:00
Daniel Martí
5d5a4df7d1 Create icons dicts like the rest 2014-01-07 16:34:24 +01:00
Daniel Martí
729f457f0b Don't print twice as many lines when resizing icons 2014-01-07 16:25:29 +01:00
Daniel Martí
f82207ec60 Keep the same ZipFile instance to retrieve all the icons 2014-01-07 16:18:25 +01:00
Daniel Martí
d6810bfaf7 Use application: and launchable-activity: icons as fallback 2014-01-07 16:18:25 +01:00
Daniel Martí
242de2368a Add 640 dpi icons dir 2014-01-07 16:18:24 +01:00
Ciaran Gultnieks
3ecf0e4373 Use app categories as wiki categories 2014-01-07 13:40:02 +00:00
Daniel Martí
8ea114114f Uncomment verbose messages, fix -I 2014-01-07 12:24:15 +01:00
Daniel Martí
0799462c11 Finish TODO; Fill missing icon densities the best we can 2014-01-07 12:20:24 +01:00
Daniel Martí
e1ed4099a7 Rewrite: Do icons per density, /icons being mdpi by default 2014-01-07 12:11:30 +01:00
Daniel Martí
b5c0db9ecc Add icon helper functions for later use 2014-01-07 11:16:58 +01:00
Daniel Martí
cf852012ed Start publishing indexes with index version "10" 2014-01-03 20:49:20 +01:00
Daniel Martí
4d668e4ed6 Add Dogecoin support, some None fixes 2013-12-31 11:57:35 +01:00
Daniel Martí
4935496f48 New field: Provides 2013-12-31 10:47:50 +01:00
Daniel Martí
0765f14c9d Remove trailing spaces and tabs 2013-12-30 17:05:25 +01:00
Daniel Martí
2757ec60c8 Only add AF xml element if there actually are AFs 2013-12-23 12:04:50 +01:00
Daniel Martí
99b5d5e387 Get rid of more unnecessary finds 2013-12-20 09:42:10 +01:00
Ciaran Gultnieks
34470eaa2b Add timestamp to index 2013-12-11 11:22:12 +00:00
Ciaran Gultnieks
92fda57112 Don't push UpstreamNonFree to index (yet) 2013-11-27 10:39:36 +00:00
Ciaran Gultnieks
ee769bedee Calculate added dates correctly when archive in use
This fixes what's new, amongst other things.
2013-11-27 09:35:43 +00:00
Ciaran Gultnieks
7cc21fe89a Allow definition of index max age in repo config 2013-11-26 22:07:47 +00:00
Ciaran Gultnieks
62e03f84f7 Some more kivy wip 2013-11-26 22:04:40 +00:00
Ciaran Gultnieks
53781f913b Some more kivy wip 2013-11-26 22:02:33 +00:00
Daniel Martí
9f6f76c1ad MetaDataException comes from metadata.py 2013-11-22 11:15:08 +01:00
Daniel Martí
fb38eb6b8c First metadata checks rewrite; New metadata.py module 2013-11-19 15:35:16 +01:00
Ciaran Gultnieks
e081a83757 Correction to a5fafe6 2013-11-17 12:16:24 +00:00
Ciaran Gultnieks
a5fafe6c05 Use individual antifeature template on wiki 2013-11-17 12:05:02 +00:00
Paul Sokolovsky
57c53125d0 Check that getsig.class exists, give user hints how to make it. 2013-11-16 19:06:41 +02:00
Ciaran Gultnieks
67b6106a55 Always include Maintainer Notes, even if only for auto-generated parts 2013-11-15 10:00:04 +00:00
Ciaran Gultnieks
17f6e4d169 A couple of wiki improvements 2013-11-13 14:56:58 +00:00
Ciaran Gultnieks
356f12ab2f Write maintainer notes to wiki 2013-11-05 16:40:23 +00:00
Daniel Martí
5b613292c3 Merge branch 'master' into verbose-rewrite 2013-11-02 22:36:55 +01:00
Daniel Martí
e069da3562 Don't accept empty icons; Don't add <icon> xml element if none is present 2013-11-02 22:14:32 +01:00
Daniel Martí
8bab7a06ce Fix: use -cp (classpath) to fix problems with java getsig 2013-11-02 22:01:50 +01:00
Daniel Martí
67b8825560 Merge branch 'master' into verbose-rewrite 2013-11-02 19:56:31 +01:00
Daniel Martí
79a24e3e11 Fixes to categories in update.py 2013-11-02 16:04:50 +01:00
Daniel Martí
ee759a3a0e Start doing multiple categories as comma separated lists
Don't drop support for old clients (only one category) yet
2013-11-02 01:14:01 +01:00
Daniel Martí
c3be06fb1d Start rewriting options and config as common.py globals 2013-11-01 13:55:38 +01:00
Ciaran Gultnieks
0ac058c244 Avoid pyflakes error 2013-11-01 13:55:38 +01:00
Ciaran Gultnieks
f878f55c19 Fix mistake in 08287a1f 2013-11-01 13:55:37 +01:00
Ciaran Gultnieks
4bd64de501 Avoid pyflakes error 2013-10-31 22:16:05 +00:00
Ciaran Gultnieks
e080bb3983 Fix mistake in 08287a1f 2013-10-31 16:42:42 +00:00
Ciaran Gultnieks
a762a0cb04 Tidied up some unused junk 2013-10-31 15:46:32 +00:00
Ciaran Gultnieks
08287a1fa8 Handle repo config in a more sensible way 2013-10-31 15:37:39 +00:00
Daniel Martí
2c804ef88a Switch all shebangs to 'env python2' 2013-10-31 13:27:24 +01:00
Ciaran Gultnieks
ba96af1a78 Wiki update code for disabled builds can be simplified now 2013-10-29 17:39:05 +00:00
Ciaran Gultnieks
ccdea798fc Don't need legacy disabled build handling everywhere now 2013-10-27 14:40:02 +00:00
Ciaran Gultnieks
715035a707 Introduce disable= as a better way of disabling a build
Prefixing commit ID with ! and a message will still work, but that's
very silly. Using disable= is now the correct way.
2013-10-26 10:28:12 +01:00
Daniel Martí
3f92d3243c Partially revert Requires Root: changes 2013-10-25 17:19:23 +02:00
Daniel Martí
1452a55642 Don't place UCM:Static in apps to update 2013-10-25 17:16:40 +02:00
Ciaran Gultnieks
fe720343c2 Add wiki category for disabled apps (issue #163) 2013-10-23 13:19:50 +01:00
Daniel Martí
843be72667 label regex pattern now doesn't stop until a new field or a newline are found 2013-10-23 09:58:32 +02:00
Daniel Martí
6de94d8e11 Use "Requires Root:" as a forced ACCESS_SUPERUSER permission 2013-10-23 01:00:21 +02:00
Daniel Martí
8d1db23eee Non-greedy match for app labels (should fix the icon= stuff) 2013-10-17 13:19:06 +02:00
Ciaran Gultnieks
25ae0e8d79 Allow archive policy override for indivudual apps 2013-10-14 16:16:34 +01:00
Daniel Martí
ded019291e sed -i 's/!= None/is not None/g' *.py 2013-10-13 00:03:57 +02:00
Daniel Martí
47cad8fca7 Add support for Litecoin in the server 2013-10-13 00:03:11 +02:00
Daniel Martí
697011f086 Remove unnecessary indenting 2013-10-10 16:45:17 +02:00
Ciaran Gultnieks
7b21d12f65 Purge repo maintenance page cache after updates 2013-10-10 09:47:48 +01:00
Ciaran Gultnieks
4e51a68cfa Don't put redirects in the same category as real app pages 2013-10-09 14:39:00 +01:00
Ciaran Gultnieks
d2867a3192 A few more wiki fixes 2013-10-09 13:23:17 +01:00
Ciaran Gultnieks
87f6bf2392 Add wiki category for failing builds 2013-10-09 09:57:00 +01:00
Ciaran Gultnieks
69b7f68301 Include entries for failed builds in wiki data 2013-10-09 09:48:41 +01:00
Daniel Martí
89a4e17c3b Added myself to copyright notices 2013-09-28 21:06:33 +02:00
Ciaran Gultnieks
0d2a7ba4f8 No colon in wiki app page names 2013-09-05 10:32:33 +01:00
Daniel Martí
96d91342ee Fix sha256 sums not appearing in the index 2013-08-28 08:59:38 +02:00
Daniel Martí
377c9a9700 Remove md5 sums from the index (fixes: #336) 2013-08-26 10:44:52 +02:00
Daniel Martí
8578747ae3 Drop support for old description elements (deprecated one year ago) 2013-08-22 17:03:06 +02:00
Ciaran Gultnieks
eec320a08d Icon resizing diagnostics/robustness 2013-08-21 21:47:48 +01:00
Daniel Martí
e6fe2d7d53 Maximum icon size is now defined in config.py 2013-08-19 11:36:26 +02:00
Daniel Martí
9f246b04cc Add -I/--icons to update 2013-08-19 11:30:54 +02:00
Daniel Martí
a1c2dc1a75 Start publishing new repo icons at max 72x72 px 2013-08-19 11:20:50 +02:00
Daniel Martí
ece2ece071 Deprecate aapt_path in favour of sdk_path + build_tools 2013-08-08 13:00:02 +02:00
Daniel Martí
a49b405780 Remove deprecated parameter 2013-07-31 19:51:02 +02:00
Ciaran Gultnieks
c968a2856c Fix nativecode in index properly (probably) 2013-07-22 15:12:33 +01:00
Ciaran Gultnieks
6cd5d0d667 Revert "Try to fix nativecode issues on index"
This reverts commit de7b117c98.
2013-07-22 15:12:33 +01:00
Daniel Martí
de7b117c98 Try to fix nativecode issues on index 2013-07-19 11:47:35 +02:00
Ciaran Gultnieks
cf35572513 Show auto-update mode on wiki (issue #145) 2013-07-16 09:43:35 +01:00