canvace/grunt-appcache — pull request #3 by phette23 (2014-03-29 04:42:04+00:00)
Title: add support for protocol-relative URLs

I typically include scripts from the Google CDN in my projects, e.g. ``, and their recommended practice is protocol-relative URLs, which help in situations where the client can choose to load resources over HTTP or HTTPS. I noticed grunt-appcache wasn't including the CDN files in the manifest, however.

This commit fixes a bug in `isAbsolutePath`, which returns false for an absolute URL like '//cdn.com/lib.js'. It just makes the http(s) optional when it tests the beginning of the path.