mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-04 22:40:29 +03:00
eliminate app.builds everywhere, it should be app['Builds']
The .txt format was the last place where the lowercase "builds" was used,
this converts references everywhere to be "Builds". This makes it possible
to load metadata YAML files with any YAML parser, then have it possible to
use fdroidserver methods on that data, like metadata.write_metadata().
The test files in tests/metadata/dump/*.yaml were manually edited by cutting
the builds: block and putting it the sort order for Builds: so the contents
should be unchanged.
```
sed -i \
-e 's/app\.builds/app.get('Builds', \[\])/g' \
-e "s/app\.get(Builds, \[\]) =/app\['Builds'] =/g" \
-e "s/app\.get(Builds, \[\]) =/app\['Builds'] =/g" \
-e "s/app\.get(Builds, \[\])/app.get('Builds', \[\])/g" \
-e "s/app\.get('Builds', \[\])\.append/app\['Builds'\].append/g" \
-e "s/app\['builds'\]/app.get('Builds', [])/g" \
*/*.*
```
This commit is contained in:
parent
877779195f
commit
bf25b4ca03
18 changed files with 275 additions and 279 deletions
|
|
@ -943,7 +943,7 @@ class CommonTest(unittest.TestCase):
|
|||
app = fdroidserver.metadata.App()
|
||||
build = fdroidserver.metadata.Build()
|
||||
build.gradle = ['devVersion']
|
||||
app.builds = [build]
|
||||
app['Builds'] = [build]
|
||||
app.id = 'org.fdroid.fdroid.dev'
|
||||
paths = [
|
||||
os.path.join('source-files', 'fdroid', 'fdroidclient', 'AndroidManifest.xml'),
|
||||
|
|
@ -957,7 +957,7 @@ class CommonTest(unittest.TestCase):
|
|||
app = fdroidserver.metadata.App()
|
||||
build = fdroidserver.metadata.Build()
|
||||
build.gradle = ['free']
|
||||
app.builds = [build]
|
||||
app['Builds'] = [build]
|
||||
app.id = 'eu.siacs.conversations'
|
||||
paths = [
|
||||
os.path.join('source-files', 'eu.siacs.conversations', 'build.gradle'),
|
||||
|
|
@ -970,7 +970,7 @@ class CommonTest(unittest.TestCase):
|
|||
app = fdroidserver.metadata.App()
|
||||
build = fdroidserver.metadata.Build()
|
||||
build.gradle = ['generic']
|
||||
app.builds = [build]
|
||||
app['Builds'] = [build]
|
||||
app.id = 'com.nextcloud.client'
|
||||
paths = [
|
||||
os.path.join('source-files', 'com.nextcloud.client', 'build.gradle'),
|
||||
|
|
@ -983,7 +983,7 @@ class CommonTest(unittest.TestCase):
|
|||
app = fdroidserver.metadata.App()
|
||||
build = fdroidserver.metadata.Build()
|
||||
build.gradle = ['versionDev']
|
||||
app.builds = [build]
|
||||
app['Builds'] = [build]
|
||||
app.id = 'com.nextcloud.android.beta'
|
||||
paths = [
|
||||
os.path.join('source-files', 'com.nextcloud.client', 'build.gradle'),
|
||||
|
|
@ -996,7 +996,7 @@ class CommonTest(unittest.TestCase):
|
|||
app = fdroidserver.metadata.App()
|
||||
build = fdroidserver.metadata.Build()
|
||||
build.gradle = ['standard']
|
||||
app.builds = [build]
|
||||
app['Builds'] = [build]
|
||||
app.id = 'at.bitfire.davdroid'
|
||||
paths = [
|
||||
os.path.join('source-files', 'at.bitfire.davdroid', 'build.gradle'),
|
||||
|
|
@ -1009,7 +1009,7 @@ class CommonTest(unittest.TestCase):
|
|||
app = fdroidserver.metadata.App()
|
||||
build = fdroidserver.metadata.Build()
|
||||
build.gradle = ['libre']
|
||||
app.builds = [build]
|
||||
app['Builds'] = [build]
|
||||
app.id = 'com.kunzisoft.fdroidtest.applicationidsuffix.libre'
|
||||
paths = [
|
||||
os.path.join('source-files', 'com.kunzisoft.testcase', 'build.gradle'),
|
||||
|
|
@ -1022,7 +1022,7 @@ class CommonTest(unittest.TestCase):
|
|||
app = fdroidserver.metadata.App()
|
||||
build = fdroidserver.metadata.Build()
|
||||
build.gradle = ['pro']
|
||||
app.builds = [build]
|
||||
app['Builds'] = [build]
|
||||
app.id = 'com.kunzisoft.fdroidtest.applicationidsuffix.pro'
|
||||
paths = [
|
||||
os.path.join('source-files', 'com.kunzisoft.testcase', 'build.gradle'),
|
||||
|
|
@ -1035,7 +1035,7 @@ class CommonTest(unittest.TestCase):
|
|||
app = fdroidserver.metadata.App()
|
||||
build = fdroidserver.metadata.Build()
|
||||
build.gradle = ['free']
|
||||
app.builds = [build]
|
||||
app['Builds'] = [build]
|
||||
app.id = 'com.kunzisoft.fdroidtest.applicationidsuffix'
|
||||
paths = [
|
||||
os.path.join('source-files', 'com.kunzisoft.testcase', 'build.gradle'),
|
||||
|
|
@ -1048,7 +1048,7 @@ class CommonTest(unittest.TestCase):
|
|||
app = fdroidserver.metadata.App()
|
||||
build = fdroidserver.metadata.Build()
|
||||
build.gradle = ['underscore']
|
||||
app.builds = [build]
|
||||
app['Builds'] = [build]
|
||||
app.id = 'com.kunzisoft.fdroidtest.applicationidsuffix.underscore'
|
||||
paths = [
|
||||
os.path.join('source-files', 'com.kunzisoft.testcase', 'build.gradle'),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue