MCPcopy Create free account
hub / github.com/socketstream/socketstream / pushMainEntries

Function pushMainEntries

lib/client/bundler/index.js:582–598  ·  view source on GitHub ↗
(from)

Source from the content-addressed store, hash-verified

580 }
581
582 function pushMainEntries(from) {
583 var p = path.join(ss.root,from);
584 if (!fs.existsSync(p) || fs.statSync(p).isFile()) {
585 p = from;
586 } else {
587 p = path.join(from,'**','*');
588 }
589 return glob.sync(p, {cwd:ss.root}).forEach(function(file) {
590 var extension = path.extname(file);
591 extension = extension && extension.substring(1); // argh!
592 var assetType = bundle==='tmpl'? 'html':bundle;
593 var entry = {file:file,importedBy:from,includeType:includeType,ext:extension,bundle:bundle,assetType:assetType};
594 if (isAssetType(entry)) {
595 _entries.push(entry);
596 }
597 });
598 }
599
600 function isAssetType(entry) {
601 if (ss.client.formatters == null) {

Callers

nothing calls this directly

Calls 1

isAssetTypeFunction · 0.85

Tested by

no test coverage detected