6
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Android Studioで署名付きAPK作成時にLintエラーが出た場合の対処法

Posted at

アプリが完成し、いざ署名付きリリースビルド!
と思ったら以下のエラーが出ました。

Lint found fatal errors while assembling a release target.

To proceed, either fix the issues identified by lint, or modify your build script as follows:
...
android {
    lintOptions {
        checkReleaseBuilds false
        // Or, if you prefer, you can continue to check for errors in release builds,
        // but continue the build even when errors are found:
        abortOnError false
    }
}
...

qiita_2020-02-25_01h28_32.png

指示通り、build.gradle(Module:app)の「android」の中に
「lintOptions」を貼り付けて「Sync Now」。

checkReleaseBuildsは、
リリースビルド時にLintチェックするかどうか。
abortOnErrorはエラー時にビルドを停止する、ですね。

ビルドし直すとエラーが出なくなりました。

6
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
6
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?