MCPcopy
hub / github.com/bower/bower / getExtractor

Function getExtractor

lib/util/extract.js:141–151  ·  view source on GitHub ↗
(archive)

Source from the content-addressed store, hash-verified

139}
140
141function getExtractor(archive) {
142 // Make the archive lower case to match against the types
143 // This ensures that upper-cased extensions work
144 archive = archive.toLowerCase();
145
146 var type = mout.array.find(extractorTypes, function(type) {
147 return mout.string.endsWith(archive, type);
148 });
149
150 return type ? extractors[type] : null;
151}
152
153function isSingleDir(dir) {
154 return Q.nfcall(fs.readdir, dir).then(function(files) {

Callers 2

canExtractFunction · 0.85
extractFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…