My Android Studio was working fine, everything was good but after updating Android Studio to the latest version and updating gradle I got the following error
Could you please provide the solution, thank you
Task :app:processDebugResources FAILED
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{}],"original":"AAPT: unknown option '--proguard-minimal-keep-rules'.\n\naapt2 link [options] -o arg --manifest arg files...\n\nOptions:\n -o arg Output path.\n --manifest arg Path to the Android manifest to build.\n -I arg Adds an Android APK to link against.\n -A arg An assets directory to include in the APK. These are unprocessed.\n -R arg Compilation unit to link, using overlay semantics.\n The last conflicting resource given takes precedence.\n --package-id arg Specify the package ID to use for this app. Must be greater or equal to\n 0x7f and can't be used with --static-lib or --shared-lib.\n --java arg Directory in which to generate R.java.\n --proguard arg Output file for generated Proguard rules.\n --proguard-main-dex arg Output file for generated Proguard rules for the main dex.\n --proguard-conditional-keep-rules Generate conditional Proguard keep rules.\n --no-auto-version Disables automatic style and layout SDK versioning.\n --no-version-vectors Disables automatic versioning of vector drawables. Use this only\n when building with vector drawable support library.\n --no-version-transitions Disables automatic versioning of transition resources. Use this only\n when building with transition support library.\n --no-resource-deduping Disables automatic deduping of resources with\n identical values across compatible configurations.\n --enable-sparse-encoding This decreases APK size at the cost of resource retrieval performance.\n -x Legacy flag that specifies to use the package identifier 0x01.\n -z Require localization of strings marked 'suggested'.\n -c arg Comma separated list of configurations to include. The default\n is all configurations.\n --preferred-density arg Selects the closest matching density and strips out all others.\n --product arg Comma separated list of product names to keep\n --output-to-dir Outputs the APK contents to a directory specified by -o.\n --no-xml-namespaces Removes XML namespace prefix and URI information\n from AndroidManifest.xml and XML binaries in res/*.\n --min-sdk-version arg Default minimum SDK version to use for AndroidManifest.xml.\n --target-sdk-version arg Default target SDK version to use for AndroidManifest.xml.\n --version-code arg Version code (integer) to inject into the AndroidManifest.xml if none is\n present.\n --version-code-major arg Version code major (integer) to inject into the AndroidManifest.xml if none is\n present.\n --version-name arg Version name to inject into the AndroidManifest.xml if none is present.\n --replace-version If --version-code and/or --version-name are specified, these\n values will replace any value already in the manifest. By\n default, nothing is changed if the manifest already defines\n these attributes.\n --compile-sdk-version-code arg Version code (integer) to inject into the AndroidManifest.xml if none is\n present.\n --compile-sdk-version-name arg Version name to inject into the AndroidManifest.xml if none is present.\n --shared-lib Generates a shared Android runtime library.\n --static-lib Generate a static Android library.\n --proto-format Generates compiled resources in Protobuf format.\n Suitable as input to the bundle tool for generating an App Bundle.\n --no-static-lib-packages Merge all library resources under the app's package.\n --non-final-ids Generates R.java without the final modifier. This is implied when\n --static-lib is specified.\n --stable-ids arg File containing a list of name to ID mapping.\n --emit-ids arg Emit a file at the given path with a list of name to ID mappings,\n suitable for use with --stable-ids.\n --private-symbols arg Package name to use when generating R.java for private symbols.\n If not specified, public and private symbols will use the application's\n package name.\n --custom-package arg Custom Java package under which to generate R.java.\n --extra-packages arg Generate the same R.java but with different package names.\n --add-javadoc-annotation arg Adds a JavaDoc annotation to all generated Java classes.\n --output-text-symbols arg Generates a text file containing the resource symbols of the R class in\n the specified folder.\n --allow-reserved-package-id Allows the use of a reserved package ID. This should on be used for\n packages with a pre-O min-sdk\n \n --auto-add-overlay Allows the addition of new resources in overlays without\n tags.\n --rename-manifest-package arg Renames the package in AndroidManifest.xml.\n --rename-instrumentation-target-package arg Changes the name of the target package for instrumentation. Most useful\n when used in conjunction with --rename-manifest-package.\n -0 arg File extensions not to compress.\n --no-compress Do not compress any resources.\n --warn-manifest-validation Treat manifest validation errors as warnings.\n --split arg Split resources matching a set of configs out to a Split APK.\n Syntax: path/to/output.apk:[,[...]].\n On Windows, use a semicolon ';' separator instead.\n -v Enables verbose logging.\n --debug-mode Inserts android:debuggable=\"true\" in to the application node of the\n manifest, making the application debuggable even on production devices.\n --strict-visibility Do not allow overlays with different visibility levels.\n -h Displays this help menu\n\n ","tool":"AAPT"}
AAPT: unknown option '--proguard-minimal-keep-rules'.
aapt2 link [options] -o arg --manifest arg files...
Options:
-o arg Output path.
--manifest arg Path to the Android manifest to build.
-I arg Adds an Android APK to link against.
-A arg An assets directory to include in the APK. These are unprocessed.
-R arg Compilation unit to link, using overlay semantics.
The last conflicting resource given takes precedence.
--package-id arg Specify the package ID to use for this app. Must be greater or equal to
0x7f and can't be used with --static-lib or --shared-lib.
--java arg Directory in which to generate R.java.
--proguard arg Output file for generated Proguard rules.
--proguard-main-dex arg Output file for generated Proguard rules for the main dex.
--proguard-conditional-keep-rules Generate conditional Proguard keep rules.
--no-auto-version Disables automatic style and layout SDK versioning.
--no-version-vectors Disables automatic versioning of vector drawables. Use this only
when building with vector drawable support library.
--no-version-transitions Disables automatic versioning of transition resources. Use this only
when building with transition support library.
--no-resource-deduping Disables automatic deduping of resources with
identical values across compatible configurations.
--enable-sparse-encoding This decreases APK size at the cost of resource retrieval performance.
-x Legacy flag that specifies to use the package identifier 0x01.
-z Require localization of strings marked 'suggested'.
-c arg Comma separated list of configurations to include. The default
is all configurations.
--preferred-density arg Selects the closest matching density and strips out all others.
--product arg Comma separated list of product names to keep
--output-to-dir Outputs the APK contents to a directory specified by -o.
--no-xml-namespaces Removes XML namespace prefix and URI information
from AndroidManifest.xml and XML binaries in res/*.
--min-sdk-version arg Default minimum SDK version to use for AndroidManifest.xml.
--target-sdk-version arg Default target SDK version to use for AndroidManifest.xml.
--version-code arg Version code (integer) to inject into the AndroidManifest.xml if none is
present.
--version-code-major arg Version code major (integer) to inject into the AndroidManifest.xml if none is
present.
--version-name arg Version name to inject into the AndroidManifest.xml if none is present.
--replace-version If --version-code and/or --version-name are specified, these
values will replace any value already in the manifest. By
default, nothing is changed if the manifest already defines
these attributes.
--compile-sdk-version-code arg Version code (integer) to inject into the AndroidManifest.xml if none is
present.
--compile-sdk-version-name arg Version name to inject into the AndroidManifest.xml if none is present.
--shared-lib Generates a shared Android runtime library.
--static-lib Generate a static Android library.
--proto-format Generates compiled resources in Protobuf format.
Suitable as input to the bundle tool for generating an App Bundle.
--no-static-lib-packages Merge all library resources under the app's package.
--non-final-ids Generates R.java without the final modifier. This is implied when
--static-lib is specified.
--stable-ids arg File containing a list of name to ID mapping.
--emit-ids arg Emit a file at the given path with a list of name to ID mappings,
suitable for use with --stable-ids.
--private-symbols arg Package name to use when generating R.java for private symbols.
If not specified, public and private symbols will use the application's
package name.
--custom-package arg Custom Java package under which to generate R.java.
--extra-packages arg Generate the same R.java but with different package names.
--add-javadoc-annotation arg Adds a JavaDoc annotation to all generated Java classes.
--output-text-symbols arg Generates a text file containing the resource symbols of the R class in
the specified folder.
--allow-reserved-package-id Allows the use of a reserved package ID. This should on be used for
packages with a pre-O min-sdk
--auto-add-overlay Allows the addition of new resources in overlays without tags. --rename-manifest-package arg Renames the package in AndroidManifest.xml. --rename-instrumentation-target-package arg Changes the name of the target package for instrumentation. Most useful when used in conjunction with --rename-manifest-package. -0 arg File extensions not to compress. --no-compress Do not compress any resources. --warn-manifest-validation Treat manifest validation errors as warnings. --split arg Split resources matching a set of configs out to a Split APK. Syntax: path/to/output.apk:[,[...]]. On Windows, use a semicolon ';' separator instead. -v Enables verbose logging. --debug-mode Inserts android:debuggable="true" in to the application node of the manifest, making the application debuggable even on production devices. --strict-visibility Do not allow overlays with different visibility levels. -h Displays this help menu
