1
0
mirror of https://gitlab.com/fdroid/fdroidserver.git synced 2024-09-11 15:13:27 +02:00
Commit Graph

3100 Commits

Author SHA1 Message Date
Daniel Martí
3662dfd145 lint: warn (pedantic) about potentially dangerous auto updates 2014-12-22 18:18:07 +01:00
Daniel Martí
fe0af55a6a lint: find the current build like checkupdates does 2014-12-22 18:17:29 +01:00
Kevin Cernekee
d899783884 manual: Clarify separation of Debian base box vs. F-Droid base box 2014-12-21 12:33:59 -08:00
Kevin Cernekee
8d04b93852 Update comment referring to old "raring32.box" image 2014-12-21 11:03:06 -08:00
Daniel Martí
606cda591d Don't break os.symlink if app names contain '/' 2014-12-14 15:43:22 +01:00
Daniel Martí
1268da7ac6 Remove SilentPopen for consistency with SdkToolsPopen 2014-12-14 15:38:24 +01:00
Daniel Martí
1a0831b5c0 Merge branch 'master' of https://gitlab.com/eighthave/fdroidserver 2014-12-14 15:18:30 +01:00
Hans-Christoph Steiner
5f5bcd2e11 do not set sdk_path in config.py if using system-provided aapt
By not setting sdk_path when /usr/bin/aapt is found, sdk_path then defaults
to $ANDROID_HOME when its used.  Since in this case, aapt will be used from
the system path, using aapt entirely ignores sdk_path.  If the user runs
`fdroid build` in this setup, sdk_path will be $ANDROID_HOME, so it should
check the env vars for it, but maybe that doesn't actually work like that
yet.
2014-12-14 13:26:50 +01:00
Hans-Christoph Steiner
fa1cc48d57 run all SDK tools commands using SdkToolsPopen 2014-12-14 13:25:20 +01:00
Hans-Christoph Steiner
9244256461 find cmds from SDK build-tools in a more flexible way, on the fly
This is a more flexible approach than testing for the complete SDK and
build-tools up front.  This will only test for the commands that are
actually being run, so that if you only have `aapt` installed, you can do
`fdroid update` without errors, but other commands will still give
appropriate errors.

This also makes the build_tools item in config.py optional, it is only
needed if you want to force a specific version of the build-tools.
2014-12-14 13:25:20 +01:00
Hans-Christoph Steiner
298a88a498 added test case for common.isApkDebuggable()
Just getting into the habit of adding tests to everything that I change...
Also, it should be useful to have an unsigned APK in the test collection,
since `fdroid update` should handle it gracefully and give a warning of
some kind.
2014-12-14 13:25:20 +01:00
Hans-Christoph Steiner
f7c9eccc1f switched last aapt call to use central config['aapt'] 2014-12-14 13:25:20 +01:00
Hans-Christoph Steiner
0f71929e71 remove redundant test_sdk_exists() call, its called by test_build_tools_exists()
No need to call test_sdk_exists() before test_build_tools_exists() since
test_build_tools_exists() calls test_sdk_exists() as the first thing it
does.
2014-12-14 13:25:20 +01:00
Daniel Martí
16601a0be3 Bump build-tools again to 21.1.2 2014-12-12 12:57:12 +01:00
Daniel Martí
aaf36f654d Update build-tools to 21.1.1 2014-12-12 12:40:09 +01:00
Daniel Martí
e10b2dd382 Update sdk to 24.0.1 2014-12-12 12:39:04 +01:00
Daniel Martí
5e15d8ff47 Add ruby tests to the pre-commit hook 2014-12-12 12:34:28 +01:00
Daniel Martí
05a7a872b6 Add gradle 2.2.1 for plugin versions 1.0.X 2014-12-12 12:29:16 +01:00
Ciaran Gultnieks
3aaa5c9603 Add inkscape to buildserver 2014-12-04 11:38:02 +00:00
Daniel Martí
b2f4aa31fe Merge branch 'master' into 'master'
fix bugs in run-tests scripts

This fixes a couple of subtle bugs in `./run-tests` that only showed up recently.

See merge request !30
2014-11-17 17:03:22 +00:00
Hans-Christoph Steiner
14cd835929 run-tests: properly handle zero and multiple args
The test for the help flag threw an error if there were 0 args, or if arg 1
was set to a space-separated list.  The -z tests would fail if the arg was
set to a space-separated list.
2014-11-17 17:40:48 +01:00
Hans-Christoph Steiner
49b343d024 run-tests: make sure not to include the bad APKs in tests/
These APKs are meant for specific tests, not the tests that want just a
collection of good APKs.
2014-11-17 17:24:02 +01:00
Ciaran Gultnieks
031b4a74e7 Merge branch 'current-version-links' into 'master'
Current version links

This is the automatic generation of "current version" symlinks that @ciarang and I chatted about, and is discussed here: https://f-droid.org/forums/topic/static-urls-to-current-version-of-each-app/

See merge request !29
2014-11-17 09:01:11 +00:00
Daniel Martí
bf20d5af88 Fix issue where the wrong gradle version may be used 2014-11-15 21:38:48 +01:00
Hans-Christoph Steiner
7a07f59731 server: always use same rsync destination path to allow for strict setups
for more info on how:
http://positon.org/rsync-command-restriction-over-ssh
http://ramblings.narrabilis.com/using-rsync-with-ssh
2014-11-11 15:06:53 +01:00
Hans-Christoph Steiner
8e9e17892d server: upload "current version" symlinks if requested
If `fdroid update` generates the "current version" symlinks, then
`fdroid server update` should upload them to the server.
2014-11-11 15:06:53 +01:00
Hans-Christoph Steiner
b33cae375a remove url-unsafe characters from "current version" symlink names
This prevents the URL from having ugly %20 stuff in the app name.
2014-11-11 15:06:53 +01:00
Hans-Christoph Steiner
803ec39e23 when symlinking current version of app, include gpg sig if it exists
Let's make it easy for people to also find the GPG signature, and promote
easy verification!
2014-11-11 15:06:52 +01:00
Hans-Christoph Steiner
e826938734 static URLs to "Current Version" of each app
I wrote up the feature to automatically generate symlinks with a constant name
that points to the current release version. I have it on by default, with a
*config.py* option to turn it off. There is also an option to set where the
symlink name comes from which defaults to app['Name'] i.e. F-Droid.apk, but
can easily be set to app['id'], i.e. _org.fdroid.fdroid.apk_. I think the best
place for the symlinks is in the root of the repo, so like
https://f-droid.org/F-Droid.apk or https://guardianproject.info/fdroid/ChatSecure.apk

For the case of the current FDroid static link https://f-droid.org/FDroid.apk
it can just be a symlink to the generated one (https://f-droid.org/F-Droid.apk
or https://f-droid.org/org.fdroid.fdroid.apk). Right now, this feature is all
or nothing, meaning it generates symlinks for all apps in the repo, or none. I
can’t think of any problems that this might cause since its only symlinks, so
the amount of disk space is tiny. Also, I think it would be useful for having
an easy “Download this app” button on each app’s page on the “Browse” view. As
long as this button is less prominent than the “Download F-Droid” button, and
it is clear that it is better to use the FDroid app than doing direct
downloads. For the f-droid.org repo, the symlinks should probably be based on
app['id'] to prevent name conflicts.

more info here:
https://f-droid.org/forums/topic/static-urls-to-current-version-of-each-app/
2014-11-11 15:06:52 +01:00
Daniel Martí
c91fca7bb4 Properly catch return codes since -x is no longer used 2014-11-09 14:36:58 +01:00
Daniel Martí
d3faacf9b0 Don't accept pyflakes/pep8 not being installed, common err func 2014-11-09 14:34:24 +01:00
Daniel Martí
cf4635e655 List sh files to check like the python files 2014-11-09 14:31:50 +01:00
Daniel Martí
92a4bacbf6 git pre-commit hooks are always run from the root
No need to find out the basedir. We don't do it for the python tests anyway.
2014-11-09 14:29:28 +01:00
Ciaran Gultnieks
2e56f4ecbf Merge branch 'some-bug-fixes' into 'master'
Some bug fixes and things

A couple of useful bug fixes and commits.

See merge request !28
2014-11-07 14:49:07 +00:00
Ciaran Gultnieks
05c2d18709 Merge branch 'update-vagrantfile' into 'master'
Update Vagrantfile and docs to clarify v1.4.3 is ok

Saw in the server docs that we were recommending 1.3.x and saying 1.4.x was broken. I've confirmed that 1.4.x works, and updated things accordingly. Higher version might work, but figured minimal change to build stuff was best :)

See merge request !24
2014-11-07 14:44:58 +00:00
Hans-Christoph Steiner
18db382c47 include test cases for python getsig replacement
This includes the old getsig.java since that is the canonical implementation
of that algorithm.

fixes #5 https://gitlab.com/fdroid/fdroidserver/issues/5
2014-11-07 09:20:33 +00:00
Hans-Christoph Steiner
d74235564f move apk signature verification into getsig() function
This makes the python replacement behave like an all-in-one replacement
for getsig.java.

fixes #5 https://gitlab.com/fdroid/fdroidserver/issues/5
2014-11-07 09:20:23 +00:00
Daniel Martí
6e2d0a9e1e Replace getsig.java with a pure python implementation
Special thanks to deki for helping out with the certificate encodings:
https://gitlab.com/snippets/1842

fixes #5 https://gitlab.com/fdroid/fdroidserver/issues/5
2014-11-07 09:20:14 +00:00
Hans-Christoph Steiner
c88eff9af7 use jarsigner to verify the APK signature is valid
By using jarsigner here, we can get rid of getsig.java, since the rest of
what getsig.java does can easily be handled in python.  This simplifies
installation and deployment, and makes things work better cross-platform.
This also means that the fdroidserver Debian package no longer needs to
Build-Depends: on default-jdk, which makes builds in pbuilder run a lot
faster. :-)

refs #5 https://gitlab.com/fdroid/fdroidserver/issues/5
2014-11-07 09:20:04 +00:00
Daniel Martí
80cc8ef5f0 Add support for gradle plugin version 0.14 in the wrapper 2014-11-05 21:30:00 +01:00
Ciaran Gultnieks
872e57c8da Set correct defaults for Binaries metadata field 2014-10-27 17:21:04 +00:00
Ciaran Gultnieks
3f63435318 Move build/fdroidserver info to META-INF 2014-10-24 22:20:42 +01:00
Daniel Martí
5df1d89c8e Make lint report total app counts as well 2014-10-24 22:24:11 +02:00
Daniel Martí
3829896a8a Fix all pep8 warnings 2014-10-24 22:23:58 +02:00
Ciaran Gultnieks
8568805866 Support for publishing signed binaries from elsewhere
Done after verifying that they match ones built using a recipe.
Everything in the metadata should be the same as normal, with the
addition of the Binaries: directive to specify where (with pattern
substitution) to get the binaries from.

Publishing only takes place if there is a proper match. (Which seems
very unlikely to be the case unless the exact same toolchain is used, so
I would imagine that unless the person building and signing the incoming
binaries uses fdroidserver to build them, probably the exact same
buildserver id, they will not match. But at least we have the
functionality to support that.)
2014-10-24 21:04:15 +01:00
Hans-Christoph Steiner
e8e94e1020 add debug message to mark when syncing to Amazon S3 starts 2014-10-23 14:26:11 -04:00
Hans-Christoph Steiner
d2b5b86ed5 fix rsync's chmod on local copy
rsync's --chmod works a bit oddly, it only affects the source files. To
make it set the destintation with the perms set in --chmod, the --perms
flag must also be included.
2014-10-23 14:26:11 -04:00
Hans-Christoph Steiner
e8a5d2b354 check the syntax of included shell scripts in the pre-commit hook 2014-10-23 14:26:11 -04:00
Hans-Christoph Steiner
93adee0e2b do not include timestamps in .gz files of docs
The timestamps in the .gz files are not used for anything, and they break
the reproducibility of the build.  Giving --no-name means gzip will not
save the filename and timestamp in the gz file itself.  When gunziping, the
current file name will be used, minus the .gz suffix.
2014-10-23 14:26:11 -04:00
Hans-Christoph Steiner
455e76b9e7 jenkins: don't scan fdroidserver/ project for APKs
This was causing a number of problems:

* it would spend lots of time sorting through the tmp folders of APKs
  created by previous runs of this script
* it would include the bad test APKs in tests/ as normal APKs
2014-10-23 14:26:11 -04:00