Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

If you can't desugar, add salt!

License

NotificationsYou must be signed in to change notification settings

GradleUp/salty

Repository files navigation

When you can't desugar, add salt!

A Gradle plugin that inspects your bytecode to detect bad functions that are not safe to use on older Android versions.

Usage

Add the plugin:

plugins {    id("com.gradleup.salty.android").version("0.0.1")}

Configure the methods to forbid:

salty {    forbiddenMethods.add("java.util.List.removeFirst")}

Salty adds asaltyCheck${variantName} task that visits your app and dependencies bytecode usingASM and fails if an usage of any forbidden method is found.

$ ./gradlew :app:saltyCheckDebug> Task :app:saltyCheckDebug FAILEDe: [...]/debug/com/example/android_test/MainActivity.class uses java.util.List.removeFirstFAILURE: Build failed with an exception.

saltyCheck${variantName} is added to thecheck task so that it is run automatically.

About

If you can't desugar, add salt!

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp