chiark / gitweb /
Ciaran Gultnieks [Sat, 7 Nov 2015 09:27:02 +0000 (09:27 +0000)]
Fix 'set default java'
Daniel Martí [Thu, 5 Nov 2015 10:55:19 +0000 (11:55 +0100)]
Bump build-tools to 23.0.2
Ciaran Gultnieks [Thu, 5 Nov 2015 10:51:54 +0000 (10:51 +0000)]
If we're using a jessie buildserver, we need backports (for java 8)
Daniel Martí [Fri, 4 Sep 2015 04:44:59 +0000 (21:44 -0700)]
Install Java 1.8 alongside 1.7 for retrolambda
Fixes #103.
Daniel Martí [Tue, 3 Nov 2015 09:53:03 +0000 (10:53 +0100)]
Fix example config default
Daniel Martí [Sun, 1 Nov 2015 12:52:16 +0000 (13:52 +0100)]
run-tests: Don't set -x until option parsing is done
Daniel Martí [Sun, 1 Nov 2015 12:51:25 +0000 (13:51 +0100)]
run-tests: Don't show echo_header commands
Daniel Martí [Sun, 1 Nov 2015 12:48:25 +0000 (13:48 +0100)]
tests: allow running ./tests/run-tests
Daniel Martí [Sun, 1 Nov 2015 11:35:36 +0000 (12:35 +0100)]
checkupdates: check packages in AM.xml files too
Daniel Martí [Sat, 31 Oct 2015 08:59:38 +0000 (09:59 +0100)]
scanner: allow apache.org maven repo
Since it has the same free software and source code publishing
requirements that oss.sonatype and maven.org repos have.
Daniel Martí [Fri, 30 Oct 2015 18:03:53 +0000 (19:03 +0100)]
checkupdates: work around multiple package ids
If there are multiple package ids in a build.gradle file and the first
one we don't want, checkupdates would get stuck. Make it ignore any
package id that we don't want so that it can get past that.
Daniel Martí [Tue, 27 Oct 2015 12:42:02 +0000 (13:42 +0100)]
checkupdates: better "no tags" messages
Daniel Martí [Tue, 27 Oct 2015 12:41:09 +0000 (13:41 +0100)]
checkupdates: no need to sort tags if len()<=5
Daniel Martí [Mon, 26 Oct 2015 15:49:11 +0000 (16:49 +0100)]
Also fix local.prop files before subdir
If subdir=foo/bar and there is a foo/local.properties file, it would not
get treated.
Daniel Martí [Mon, 26 Oct 2015 15:29:26 +0000 (16:29 +0100)]
checkupdates: don't blindly accept subdir
This is unnecessary because dirs_with_manifest will pick it up anyway.
But the problem manifested because we weren't checking the package id
here.
Daniel Martí [Mon, 26 Oct 2015 15:13:35 +0000 (16:13 +0100)]
checkupdates: compare CVs as ints, not strs
Daniel Martí [Sun, 25 Oct 2015 23:28:29 +0000 (00:28 +0100)]
Add an extra strip() to work around tostring issue
In cases like this xml code:
<string name="app_name">"OpenKeychain"</string>
<!-- title -->
<string name="title_encrypt_text">"Encrypt"</string>
tostring() returns trailing whitespaces (including newlines). Which
aren't removed until the very end, after we try to remove enclosing
quotes. So strip right after tostring() too, since we never really care
about whitespaces anyway.
Daniel Martí [Sun, 25 Oct 2015 18:14:23 +0000 (19:14 +0100)]
checkupdates: never auto-update to older versions
Daniel Martí [Sun, 25 Oct 2015 18:10:49 +0000 (19:10 +0100)]
common: Compile more regexes only once
Daniel Martí [Sun, 25 Oct 2015 18:10:23 +0000 (19:10 +0100)]
Don't double check package name
Daniel Martí [Sun, 25 Oct 2015 18:09:55 +0000 (19:09 +0100)]
checkupdates: don't ignore root directory
Daniel Martí [Sun, 25 Oct 2015 11:09:01 +0000 (12:09 +0100)]
checkupdates: Make RepoManifest change subdir too
Daniel Martí [Sun, 25 Oct 2015 11:00:02 +0000 (12:00 +0100)]
checkupdates: let Tags detect subdir changes
Up until now, this was done only if no overall version could be found. But in
tags, we would get stuck with an old version from an old tag and not see
subdir changes in new tags.
Daniel Martí [Sun, 25 Oct 2015 10:41:46 +0000 (11:41 +0100)]
Be consistent about root_dir/build_dir naming
Daniel Martí [Sun, 25 Oct 2015 10:32:18 +0000 (11:32 +0100)]
Fix a small indentation issue
Daniel Martí [Sun, 25 Oct 2015 09:48:17 +0000 (10:48 +0100)]
Fix gradle-2.8 checksum
I once again did the -all.zip hash, not the -bin.zip one.
Daniel Martí [Sat, 24 Oct 2015 22:07:33 +0000 (00:07 +0200)]
lint: fix unlinkified links regex
It was incorrectly matching:
foo [http://bar
and not matching:
http://foo (start of line)
Daniel Martí [Sat, 24 Oct 2015 18:13:49 +0000 (20:13 +0200)]
update: fix for
0fa6aac2881
For some reason, my up to date pyflakes didn't catch this.
Daniel Martí [Sat, 24 Oct 2015 17:42:40 +0000 (19:42 +0200)]
Also replace git@gitlab.com submodule urls
Daniel Martí [Sat, 24 Oct 2015 17:05:21 +0000 (19:05 +0200)]
Add gradle 2.8
Daniel Martí [Sat, 24 Oct 2015 17:02:14 +0000 (19:02 +0200)]
Bump sdk to 24.4.1
Daniel Martí [Sat, 24 Oct 2015 16:47:43 +0000 (18:47 +0200)]
tests: we now replace "buildToolsVersion var" too
See
d706cfa7d8a
Daniel Martí [Sat, 24 Oct 2015 16:37:57 +0000 (18:37 +0200)]
Daniel Martí [Sat, 24 Oct 2015 15:02:53 +0000 (17:02 +0200)]
common: don't crash if an sdk binary is not found
Daniel Martí [Sat, 24 Oct 2015 14:34:55 +0000 (16:34 +0200)]
Remove densities getter
Daniel Martí [Thu, 22 Oct 2015 10:23:57 +0000 (12:23 +0200)]
scanner: allow sonatype groups/public repo
See http://central.sonatype.org/pages/ossrh-guide.html
Daniel Martí [Thu, 22 Oct 2015 10:22:46 +0000 (12:22 +0200)]
scanner: escape urls
Daniel Martí [Wed, 14 Oct 2015 17:34:30 +0000 (19:34 +0200)]
Fix build-tools patching when it uses variables
Like:
buildToolsVersion FOO_VERSION
Daniel Martí [Thu, 8 Oct 2015 14:39:47 +0000 (16:39 +0200)]
tests: Comment values are lists, not strings
Since there can be multiple lines.
Ciaran Gultnieks [Thu, 8 Oct 2015 13:16:16 +0000 (14:16 +0100)]
Fix shasum for gradle 2.7 (see
a229afe1)
Daniel Martí [Thu, 8 Oct 2015 11:20:48 +0000 (13:20 +0200)]
tests: adapt to new comments dict
Daniel Martí [Thu, 8 Oct 2015 11:20:35 +0000 (13:20 +0200)]
tests: close files
Daniel Martí [Thu, 8 Oct 2015 10:16:45 +0000 (12:16 +0200)]
scanner: ignore gradle comment lines
Useful to detect:
maven {
// foo
url "http://foo.bar"
}
Daniel Martí [Thu, 8 Oct 2015 10:08:21 +0000 (12:08 +0200)]
Remove unwanted files in a more consistent way
Daniel Martí [Wed, 7 Oct 2015 16:14:11 +0000 (18:14 +0200)]
scanner: error on unknown maven repos
This finds maven repos of the format:
maven {
url 'http://foo.bar'
}
And checks if the repository is one that we allow. As usual, scanignore can be
used, or the list modified, if there are exceptions or more repositories to
allow.
Ciaran Gultnieks [Tue, 6 Oct 2015 08:32:00 +0000 (08:32 +0000)]
Fix moving of gpg sigs between repo and archive
Daniel Martí [Mon, 5 Oct 2015 21:40:19 +0000 (23:40 +0200)]
buildserver: Add gradle 2.7
Daniel Martí [Mon, 5 Oct 2015 19:43:08 +0000 (21:43 +0200)]
Always use the same logging format
This helps differentiate errors, warnings and regular messages.
Daniel Martí [Sun, 4 Oct 2015 16:01:32 +0000 (18:01 +0200)]
extension simplifications
Daniel Martí [Sun, 4 Oct 2015 16:01:23 +0000 (18:01 +0200)]
write_metadata fixes
Daniel Martí [Sun, 4 Oct 2015 10:22:18 +0000 (03:22 -0700)]
Final touches to yaml writing
Now it writes and reads properly.
Daniel Martí [Sun, 4 Oct 2015 10:08:28 +0000 (03:08 -0700)]
bash-completion: add appid support for all formats
Daniel Martí [Sun, 4 Oct 2015 07:29:51 +0000 (00:29 -0700)]
More improvements to yaml writing
Daniel Martí [Sun, 4 Oct 2015 07:27:15 +0000 (00:27 -0700)]
Don't leave an empty line at the end
Daniel Martí [Sun, 4 Oct 2015 07:03:02 +0000 (00:03 -0700)]
Add basic yaml metadata writing
Daniel Martí [Sun, 4 Oct 2015 06:13:18 +0000 (23:13 -0700)]
Rename write_metadata to specify txt
Daniel Martí [Sun, 4 Oct 2015 06:00:18 +0000 (23:00 -0700)]
Simplify format parsing logic
Daniel Martí [Sun, 4 Oct 2015 00:00:22 +0000 (17:00 -0700)]
scanner: don't error on partially used globs
This meant that using something like `scanignore=*` would error if there were
ignores happening in some directories/files, but not all.
Fixes #110
Daniel Martí [Sat, 3 Oct 2015 23:52:23 +0000 (16:52 -0700)]
Rework path glob expansion
Slightly simplifies the whole thing and lets us map what each resulting path
comes from. This will be useful to fix #110 later on.
Daniel Martí [Sat, 3 Oct 2015 23:28:48 +0000 (16:28 -0700)]
import: fix issue tracker links
Daniel Martí [Thu, 1 Oct 2015 00:04:00 +0000 (17:04 -0700)]
Don't use exists() on symlinks
If they are broken, exists() will return false. islink() will return true in
both cases.
Daniel Martí [Wed, 30 Sep 2015 19:33:01 +0000 (12:33 -0700)]
Smarter archive policy apk moving
* Move apks back from the archive repo (e.g. if builds are disabled thus the
number of apks on the main repo decreases)
* Also move apk signatures back and forth
Daniel Martí [Wed, 30 Sep 2015 23:34:02 +0000 (16:34 -0700)]
checkupdates: Ignore xml tags in string content
This allows us to fetch strings like the following:
<string name="app_name">foo <xliff:g>bar</xliff:g></string>
Up until now, using .text would only return "foo ", but if we use .tostring()
with the text method, it converts everything into plain text for us resulting
in "foo bar".
Daniel Martí [Wed, 30 Sep 2015 23:12:45 +0000 (16:12 -0700)]
Fetch string contents in a safer way
Daniel Martí [Wed, 30 Sep 2015 03:39:36 +0000 (20:39 -0700)]
Daniel Martí [Tue, 29 Sep 2015 19:51:11 +0000 (12:51 -0700)]
Increase wiki error detail length limit
8k is too small, e.g. when make -jN errors or when there are a lot of scanner
errors and warnings. 16k should be better. Also, use "[...]" to make it
obvious that the output is truncated.
Daniel Martí [Sat, 26 Sep 2015 23:53:08 +0000 (16:53 -0700)]
fdroid: don't treat MetaDataException as unknown
Up until now, if it was thrown, fdroid would crash with a full stacktrace as
if the program had stopped unexpectedly. Now it just prints the metadata
error, as intended.
Daniel Martí [Fri, 25 Sep 2015 05:40:49 +0000 (22:40 -0700)]
rewritemeta: add -l option to list files
Daniel Martí [Fri, 25 Sep 2015 05:27:38 +0000 (22:27 -0700)]
Make write_metadata take a writer
This will let rewritemeta report format issues without writing to disk.
Daniel Martí [Fri, 25 Sep 2015 01:50:51 +0000 (18:50 -0700)]
Replace MD5withRSA with SHA1withRSA. Fixes #26.
Looks to me like we were using SHA1withRSA all along. Tested that everything
still works with a test repo.
As Hans reports, SHA1withRSA has been the default on Android tools for a long
time and it's supported on all Android versions.
Ciaran Gultnieks [Thu, 24 Sep 2015 09:19:17 +0000 (09:19 +0000)]
Push a more complete/standard fdroidserver layout to buildserver
Daniel Martí [Thu, 24 Sep 2015 01:52:59 +0000 (18:52 -0700)]
checkupdates: ignore gradle comments
Daniel Martí [Wed, 23 Sep 2015 20:02:22 +0000 (13:02 -0700)]
build: make sure .gradle/ is removed at clean
Daniel Martí [Wed, 23 Sep 2015 04:46:14 +0000 (21:46 -0700)]
Update build status badge to new CI url
Daniel Martí [Tue, 22 Sep 2015 20:03:42 +0000 (13:03 -0700)]
scanner: skip symlinks to avoid issues
If they resolve to a missing file, we don't care about them. If they resolve
to an existing file, we'll scan that file anyway.
Daniel Martí [Tue, 22 Sep 2015 20:02:26 +0000 (13:02 -0700)]
scanner: don't crash on unused gradle files
Daniel Martí [Tue, 22 Sep 2015 18:52:16 +0000 (11:52 -0700)]
gradle: don't strip out comments
This was never intended. Comments can help sed usage, and can still be useful
in source tarballs.
Daniel Martí [Mon, 21 Sep 2015 22:09:23 +0000 (22:09 +0000)]
Merge branch 'asynchronous_reader' into 'master'
Add asynchronous filereader, fix python3 lockups
with the current implementation of AsynchronousFileReader with Python 3 FDroidPopen deadlocks with 100% CPU-utilization
The code is from https://github.com/soxofaan/asynchronousfilereader
I hope the MIT-Licence makes no problems
See merge request !80
Daniel Martí [Mon, 21 Sep 2015 19:58:50 +0000 (19:58 +0000)]
Merge branch 'docs' into 'master'
docs: Add list of trusted maven repos
See merge request !81
Boris Kraut [Mon, 21 Sep 2015 10:16:47 +0000 (12:16 +0200)]
docs: Add list of trusted maven repos
Daniel Martí [Mon, 21 Sep 2015 17:06:38 +0000 (17:06 +0000)]
Merge branch 'master' into 'master'
Added support for gradle flavor specific dependencies in usual suspects check
When you have flavor specific dependencies in your project, you specify them in the build.gradle file with a prefixed *compile* command:
```
compile 'normal dependency'
myflavorCompile 'only for myflavor'
```
The usual suspects check just searches for some often used library names in the whole build.gradle file. I added another condition, so dependencies for not build flavors are not checked.
See merge request !77
NeroBurner [Sun, 20 Sep 2015 18:50:02 +0000 (20:50 +0200)]
Add asynchronous filereader, fix python3 lockups
Jan Kühle [Fri, 18 Sep 2015 15:22:34 +0000 (17:22 +0200)]
Added support for gradle flavor specific dependencies in usual suspects check.
Daniel Martí [Sat, 19 Sep 2015 01:57:44 +0000 (18:57 -0700)]
Remove Dogecoin donation support
Not nearly as popular as bitcoin and litecoin. To the point where it hadn't
been used yet.
Bump index version to 14 to mark its removal.
Daniel Martí [Thu, 17 Sep 2015 21:09:21 +0000 (14:09 -0700)]
metadata: fix html paragraph tag regression
Spotted in fdroid/fdroidclient#422
Daniel Martí [Thu, 17 Sep 2015 00:20:22 +0000 (17:20 -0700)]
scanner: use a blacklist instead of a whitelist
This is much closer to what we did before with mimetypes. Using a whitelist
turns out to be a bad idea since repositories seem to be randomly filled with
executable images and documents, which trigger the scanner.
In an ideal world the scanner would complain about all of those. For now, just
warn about the possibility of them being hidden binaries.
Daniel Martí [Thu, 17 Sep 2015 00:14:06 +0000 (17:14 -0700)]
scanner: also ignore ttf and otf files
Daniel Martí [Thu, 17 Sep 2015 00:13:54 +0000 (17:13 -0700)]
scanner: improve usual suspect output
Daniel Martí [Wed, 16 Sep 2015 21:29:41 +0000 (21:29 +0000)]
Merge branch 'fix_licence_setup' into 'master'
Update Licence in setup.py to AGPLv3
See merge request !79
NeroBurner [Wed, 16 Sep 2015 20:55:22 +0000 (22:55 +0200)]
Update Licence in setup.py to AGPLv3
Daniel Martí [Tue, 15 Sep 2015 21:06:31 +0000 (14:06 -0700)]
import: fix import -u from fdroiddata
Have -u take precedence over .git checking to fix import -u being run from
fdroiddata.
Daniel Martí [Tue, 15 Sep 2015 01:13:03 +0000 (18:13 -0700)]
Deduplicate statsdir
Daniel Martí [Tue, 15 Sep 2015 01:12:15 +0000 (18:12 -0700)]
Replace some hard-coded paths with os.path.join
Daniel Martí [Tue, 15 Sep 2015 00:40:44 +0000 (17:40 -0700)]
import: do set root_dir if running from a repo
Daniel Martí [Mon, 14 Sep 2015 16:40:41 +0000 (16:40 +0000)]
Merge branch 'dont-use-sudo-brew' into 'master'
Don't recommend using sudo with Homebrew
Homebrew [doesn't recommend using `sudo`][1], so update the README to reflect that.
[1]: https://github.com/Homebrew/homebrew/blob/master/share/doc/homebrew/FAQ.md#why-does-homebrew-say-sudo-is-bad-
See merge request !78
Daniel Martí [Mon, 14 Sep 2015 05:22:03 +0000 (22:22 -0700)]
scanner: avoid checking if usual files are binary
Daniel Martí [Mon, 14 Sep 2015 05:11:53 +0000 (22:11 -0700)]
Rewrite scanner logic
Initially, the scanner used libmagic which used magic numbers in the file's
content to detect what kind of file it appears to be. Since that library isn't
available on all systems, we added support for two other libraries, mimetypes
amongst them.
The issue with mimetypes is that it only uses the file's extension, not its
actual content. So this ends in variable behaviour depending on what system
you're using fdroidserver on. For example, an executable binary without
extension would be ignored if mimetypes was being used.
We now drop all libraries - mimetypes too as it depends on the system's
mime.types file - and instead check extensions ourselves. On top of that, do
a simple binary content check to find binary executables that don't have an
extension.
The new in-house code without any dependencies doesn't add any new checks, so
no builds should break. The current checks still work:
% fdroid scanner app.openconnect:1029
[...]
Found executable binary at assets/raw/armeabi/curl
Found executable binary at assets/raw/mips/curl
Found executable binary at assets/raw/x86/curl
Found JAR file at lib/XposedBridgeApi-54.jar
Found JAR file at libs/acra-4.5.0.jar
Found JAR file at libs/openconnect-wrapper.jar
Found JAR file at libs/stoken-wrapper.jar
Found shared library at libs/armeabi/libopenconnect.so
Found shared library at libs/armeabi/libstoken.so
Found shared library at libs/mips/libopenconnect.so
Found shared library at libs/mips/libstoken.so
Found shared library at libs/x86/libopenconnect.so
Found shared library at libs/x86/libstoken.so
Daniel Martí [Mon, 14 Sep 2015 05:05:41 +0000 (22:05 -0700)]
scanner: support apps using srclib repo type
Alex Jordan [Sun, 13 Sep 2015 21:53:34 +0000 (14:53 -0700)]
Don't recommend using sudo with Homebrew
Daniel Martí [Sat, 12 Sep 2015 06:42:50 +0000 (23:42 -0700)]
all: deduplicate -v/-q setup