title: How can I ignore files with dartanalyzer?
body: <p>I want to ignore all files ending with .g.dart, .inject.dart, .inject.summary in bin/ lib/ and test/</p>
  
  <p>What is the syntax to ignore files <code>dartanalyzer</code>? I tried adding this section to my analysis_options.yaml file:</p>
  
  <pre><code>analyzer:
    exclude:
      - lib/**.g.dart
  </code></pre>
  
  <p>to my analysis_options.yaml and when I run <code>dartanalyzer</code> on my project it doesn't take that in consideration. I also tried using <code>dartanalyzer --options analysis_options.yaml</code> to make sure it'd use these options without luck.</p>
  
  <p>The only syntax that I found would work with <code>dartanalyzer</code> cli tool was:</p>
  
  <pre><code>analyzer:
    exclude:
      - **/*.g.dart
  </code></pre>
  
  <p>but IntelliJ says it's an error (<code>Undefined alias</code>.)</p>
  
  <p>if I use this syntax:</p>
  
  <pre><code>analyzer:
    exclude:
      - lib/**.g.dart
      - lib/**.inject.dart
      - lib/**.inject.summary
      - test/**.g.dart
      - test/**.inject.dart
  
  </code></pre>
  
  <p>The analyzer embedded in IntelliJ filters correctly those files, but the <code>dartanalyzer</code> cli tool doesn't.</p>
  
  <p>Is there any way that works both with IntelliJ and the <code>dartanalyzer</code> CLI tool?</p>
  
  <p>Note:</p>
  
  <p>I'm using</p>
  
  <pre><code>❯ dart --version
  Dart VM version: 2.4.0 (Wed Jun 19 11:53:45 2019 +0200) on "linux_x64"
  </code></pre>