bolinfest / plovr

plovr: a Closure build tool
78 stars 49 forks source link

Support excluding of warnings via regex pattern #20

Closed rgpower closed 9 years ago

rgpower commented 10 years ago

Dear @bolinfest, I am hoping that you may consider this pull request.

I believe this will allow a close to Issue 1: Make it possible to suppress warnings from individual JS file.

Example usage

  # plovr.cfg
  {
    "warning-exclude-paths": [
    "^/closure/goog/testing/stacktrace.js",
    "^/closure/goog/iter/iter.js",
    "^/closure/goog/labs/promise/promise.js",
    "^/closure/goog/labs/promise/thenable.js",
    # transitive dependencies seem to resolved more fully...
    ".*?/closure/goog/mochikit/async/deferred.js"
    ],
  }

In the interests of other warning suppression, this branch also updates the Config.getJsContentType method to return application/javascript instead of text/javascript since the latter seems to upset HtmlUnit:

WARNING: Obsolete content type encountered: 'text/javascript'

Many thanks for considering this pull request, and for plovr itself.

Sincerely, Rick Power

rgpower commented 10 years ago

Hi @bolinfest,

Please find a re-submit of this pull request with the code-style changes you requested at pull request #27. That new pull request obviates this one.

Thanks very much, Rick

rgpower commented 9 years ago

Closed since obviated by pull request https://github.com/bolinfest/plovr/pull/27