Update AGP to 7.4.0 (#5655)

This commit is contained in:
Taco 2023-04-01 17:16:53 -04:00 committed by GitHub
parent 8c9b61e599
commit 78f65349d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
16 changed files with 41 additions and 29 deletions

View File

@ -1,6 +1,6 @@
plugins {
id('com.android.application')
id('com.github.triplet.play') version '3.7.0-agp4.2' apply false
id('com.github.triplet.play') version '3.7.0' apply false
}
apply from: "../common.gradle"
apply from: "../playFlavor.gradle"
@ -56,23 +56,19 @@ android {
}
}
lintOptions {
lint {
disable 'ObsoleteLintCustomCheck', 'CheckResult', 'UnusedAttribute', 'BatteryLife', 'InflateParams',
'RestrictedApi', 'TrustAllX509TrustManager', 'ExportedReceiver', 'AllowBackup', 'VectorDrawableCompat',
'StaticFieldLeak', 'UseCompoundDrawables', 'NestedWeights', 'Overdraw', 'UselessParent', 'TextFields',
'AlwaysShowAction', 'Autofill', 'ClickableViewAccessibility', 'ContentDescription',
'KeyboardInaccessibleWidget', 'LabelFor', 'SetTextI18n', 'HardcodedText', 'RelativeOverlap',
'RtlCompat', 'RtlHardcoded', 'MissingMediaBrowserServiceIntentFilter', 'VectorPath',
'InvalidPeriodicWorkRequestInterval'
'InvalidPeriodicWorkRequestInterval', 'NotifyDataSetChanged', 'RtlEnabled'
}
aaptOptions {
androidResources {
additionalParameters "--no-version-vectors"
}
dexOptions {
jumboMode true
}
}
dependencies {

View File

@ -76,7 +76,6 @@
<activity
android:name=".activity.SplashActivity"
android:label="@string/app_name"
android:configChanges="keyboardHidden|orientation|screenSize"
android:exported="true">
<intent-filter>
@ -99,7 +98,6 @@
android:configChanges="keyboardHidden|orientation|screenSize|smallestScreenSize|screenLayout|density|uiMode|keyboard|navigation"
android:windowSoftInputMode="stateAlwaysHidden"
android:launchMode="singleTask"
android:label="@string/app_name"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
@ -111,14 +109,21 @@
android:host="antennapod.org"
android:pathPrefix="/deeplink/main"
android:scheme="https" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:host="antennapod.org"
android:pathPrefix="/deeplink/search"
android:scheme="https" />
</intent-filter>
<intent-filter>
<action android:name="de.danoeh.antennapod.intents.MAIN_ACTIVITY" />
<category android:name="android.intent.category.DEFAULT" />
<action android:name="de.danoeh.antennapod.intents.MAIN_ACTIVITY" />
<action android:name="android.service.quicksettings.action.QS_TILE_PREFERENCES"/>
</intent-filter>
</activity>
@ -382,6 +387,7 @@
</provider>
<meta-data
tools:ignore="Deprecated"
android:name="com.google.android.actions"
android:resource="@xml/actions" />
</application>

View File

@ -5,7 +5,7 @@ buildscript {
gradlePluginPortal()
}
dependencies {
classpath 'com.android.tools.build:gradle:4.2.2'
classpath 'com.android.tools.build:gradle:7.4.0'
classpath "gradle.plugin.com.github.spotbugs.snom:spotbugs-gradle-plugin:4.7.0"
classpath 'org.codehaus.groovy:groovy-xml:3.0.9'
}

View File

@ -24,16 +24,17 @@ android {
}
packagingOptions {
exclude "META-INF/LICENSE.txt"
exclude "META-INF/NOTICE.txt"
// Extraneous jsoup files
exclude "META-INF/CHANGES"
exclude "META-INF/README.md"
resources {
excludes += ["META-INF/LICENSE.txt",
"META-INF/NOTICE.txt",
"META-INF/CHANGES",
"META-INF/README.md"]
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
}
testOptions {
@ -43,7 +44,7 @@ android {
}
}
lintOptions {
lint {
disable "GradleDependency"
checkDependencies true
warningsAsErrors true

View File

@ -5,7 +5,7 @@ apply from: "../common.gradle"
apply from: "../playFlavor.gradle"
android {
lintOptions {
lint {
disable "InvalidPeriodicWorkRequestInterval", "ObsoleteLintCustomCheck", "DefaultLocale", "UnusedAttribute",
"ParcelClassLoader", "CheckResult", "TrustAllX509TrustManager",
"StaticFieldLeak", "IconDensities", "IconDuplicates"

View File

@ -2,6 +2,7 @@ package de.danoeh.antennapod.core.service.playback;
import static de.danoeh.antennapod.model.feed.FeedPreferences.SPEED_USE_GLOBAL;
import android.annotation.SuppressLint;
import android.app.NotificationManager;
import android.app.PendingIntent;
import android.app.Service;
@ -540,6 +541,7 @@ public class PlaybackService extends MediaBrowserServiceCompat {
}
}
@SuppressLint("LaunchActivityFromNotification")
private void displayStreamingNotAllowedNotification(Intent originalIntent) {
Intent intentAllowThisTime = new Intent(originalIntent);
intentAllowThisTime.setAction(PlaybackServiceInterface.EXTRA_ALLOW_STREAM_THIS_TIME);

View File

@ -1,4 +1,4 @@
android.useAndroidX=true
android.enableJetifier=true
android.jetifier.blacklist=bcprov-jdk15on
android.jetifier.ignorelist=bcprov-jdk15on
org.gradle.jvmargs=-Xmx4096m

View File

@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

View File

@ -5,7 +5,7 @@ plugins {
apply from: "../../../common.gradle"
android {
lintOptions {
lint {
disable 'ParcelClassLoader'
}
}

View File

@ -1,5 +1,7 @@
package de.danoeh.antennapod.net.ssl;
import android.annotation.SuppressLint;
import javax.net.ssl.X509TrustManager;
import java.security.cert.CertificateException;
import java.security.cert.X509Certificate;
@ -12,6 +14,7 @@ import java.util.List;
* trusts a certificate chain, then it is trusted by the composite manager.
* Based on https://stackoverflow.com/a/16229909
*/
@SuppressLint("CustomX509TrustManager")
public class CompositeX509TrustManager implements X509TrustManager {
private final List<X509TrustManager> trustManagers;

View File

@ -1,5 +1,5 @@
android {
flavorDimensions "market"
flavorDimensions += ["market"]
productFlavors {
free {
dimension "market"

View File

@ -1,5 +1,6 @@
package de.danoeh.antennapod.playback.cast;
import android.annotation.SuppressLint;
import android.content.Context;
import androidx.annotation.NonNull;
import com.google.android.gms.cast.framework.CastOptions;
@ -9,6 +10,7 @@ import com.google.android.gms.cast.framework.SessionProvider;
import java.util.List;
@SuppressWarnings("unused")
@SuppressLint("VisibleForTests")
public class CastOptionsProvider implements OptionsProvider {
@Override
@NonNull

View File

@ -1,5 +1,6 @@
package de.danoeh.antennapod.playback.cast;
import android.annotation.SuppressLint;
import android.content.Context;
import androidx.annotation.NonNull;
import android.util.Log;
@ -36,6 +37,7 @@ import org.greenrobot.eventbus.EventBus;
/**
* Implementation of PlaybackServiceMediaPlayer suitable for remote playback on Cast Devices.
*/
@SuppressLint("VisibleForTests")
public class CastPsmp extends PlaybackServiceMediaPlayer {
public static final String TAG = "CastPSMP";

View File

@ -4,8 +4,8 @@ plugins {
apply from: "../../common.gradle"
android {
lintOptions {
disable "StaticFieldLeak"
lint {
disable "StaticFieldLeak", "StringFormatCount", "StringFormatMatches", "StringFormatInvalid", "PluralsCandidate", "StringFormatTrivial"
}
}

View File

@ -4,7 +4,7 @@ plugins {
apply from: "../../common.gradle"
android {
lintOptions {
lint {
disable "StaticFieldLeak"
}
}

View File

@ -4,7 +4,7 @@ plugins {
apply from: "../../common.gradle"
android {
lintOptions {
lint {
disable "Typos", "ExtraTranslation", "ImpliedQuantity",
"PluralsCandidate", "UnusedQuantity", "TypographyEllipsis"
}