diff --git a/fdroidserver/checkupdates.py b/fdroidserver/checkupdates.py index eb30693e..69b2f544 100644 --- a/fdroidserver/checkupdates.py +++ b/fdroidserver/checkupdates.py @@ -141,6 +141,7 @@ def check_tags(app, pattern): for tag in tags: logging.debug("Check tag: '{0}'".format(tag)) vcs.gotorevision(tag) + try_init_submodules(app, last_build, vcs) if app.UpdateCheckData: filecode, codeex, filever, verex = app.UpdateCheckData.split('|') diff --git a/tests/run-tests b/tests/run-tests index 460179ab..59fb08e5 100755 --- a/tests/run-tests +++ b/tests/run-tests @@ -1367,6 +1367,54 @@ $fdroid checkupdates --allow-dirty grep "CurrentVersionCode: 2" metadata/fake.yml +#------------------------------------------------------------------------------# +echo_header "checkupdates check version in submodule" + +ROOT=$(create_test_dir) +cd "$ROOT" +mkdir app sub +cd sub +$git init +echo 1 > ver +$git add ver +$git commit -m 1 + +cd ../app +$git init +$git submodule add "file://$(pwd)/../sub" +$git commit -am 1 +$git tag 1 + +cd ../sub +echo 2 > ver +$git commit -am 2 + +cd ../app +$git init +$git submodule update --remote +$git commit -am 2 + +cd .. +mkdir repo +mkdir metadata +cat > metadata/fake.yml <