# Lint Step Setup

**URL:** <https://discuss.bitrise.io/t/lint-step-setup/10706>\
**Category:** Question & Answer\
**Created:** [October 23, 2019, 12:46pm UTC](https://discuss.bitrise.io/t/lint-step-setup/10706 "2019-10-23T12:46:05Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![mgursch](https://avatars.discourse-cdn.com/v4/letter/m/e56c9b/32.png) [@mgursch](https://discuss.bitrise.io/u/mgursch)\
**Post date:** [October 23, 2019, 12:46pm UTC](https://discuss.bitrise.io/t/lint-step-setup/10706/1 "2019-10-23T12:46:05Z")

</div>

Hello,

I want to run only a few specific lint check before building and signing my app. If lint found an error everything should fail.

I added an additional lintOptions section to my app/build.gradle but it seems to be ignored

lintOptions {  
check ‘StringFormatCount’, ‘StringFormatInvalid’, ‘StringFormatMatches’  
checkReleaseBuilds true  
xmlReport false  
abortOnError true  
}

If I run ./gradlew app:lintProductionRelease on my local machine everything works as expected, but not on bitrise.  
Is there any way to only run these 3 checks and abort if there are errors?

Thanks a lot

---

<div class="post-metadata">

**Author:** ![mgursch](https://avatars.discourse-cdn.com/v4/letter/m/e56c9b/32.png) [@mgursch](https://discuss.bitrise.io/u/mgursch)\
**Post date:** [November 11, 2019, 9:45am UTC](https://discuss.bitrise.io/t/lint-step-setup/10706/2 "2019-11-11T09:45:26Z")

</div>

no one can help ??

---

<div class="post-metadata">

**Author:** ![koral](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/koral/32/357_2.png) [@koral](https://discuss.bitrise.io/u/koral)\
**Post date:** [November 11, 2019, 12:17pm UTC](https://discuss.bitrise.io/t/lint-step-setup/10706/3 "2019-11-11T12:17:05Z")

</div>

How are running lint on bitrise (using which step)?  
IMHO the easiest way to achieve the same results as locally is to use Gradle Runner step and specify `app:lintProductionRelease` in its `gradle_task` input .

---

<div class="post-metadata">

**Author:** ![mgursch](https://avatars.discourse-cdn.com/v4/letter/m/e56c9b/32.png) [@mgursch](https://discuss.bitrise.io/u/mgursch)\
**Post date:** [November 11, 2019, 12:29pm UTC](https://discuss.bitrise.io/t/lint-step-setup/10706/4 "2019-11-11T12:29:46Z")

</div>

Hi @koral ,

I tried two ways:

1. gradle\_task exactly as i run it on my local machine
2. lint\_task

I want to achive, that

1. only specific lint rules are checked  
and
2. that the build fails if lint detect errors

Thanks a lot

---

<div class="post-metadata">

**Author:** ![bitce](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/bitce/32/1639_2.png) [@bitce](https://discuss.bitrise.io/u/bitce)\
**Post date:** [December 7, 2019, 12:42pm UTC](https://discuss.bitrise.io/t/lint-step-setup/10706/5 "2019-12-07T12:42:45Z")

</div>

Hi @mgursch!

Unfortunately, the existing Lint step would not allow you for this kind of flexibility. Feel free to fork the step and bend it to your use case! 🙂

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/bitrise/original/2X/d/d901cf2aad020f2dd11918afc89ec2089bb87b35.png) [@system](https://discuss.bitrise.io/u/system)\
**Post date:** [January 6, 2020, 12:51pm UTC](https://discuss.bitrise.io/t/lint-step-setup/10706/6 "2020-01-06T12:51:44Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
