MCPcopy Create free account
hub / github.com/krausest/js-framework-benchmark / shouldInclude

Function shouldInclude

cli/copy.js:13–30  ·  view source on GitHub ↗

* Checks whether a given file or directory `name` should be included based on certain conditions. * @param {string} name * @returns {boolean}

(name)

Source from the content-addressed store, hash-verified

11 * @returns {boolean}
12 */
13function shouldInclude(name) {
14 const isBindingScala = name.includes("binding.scala");
15
16 if (isBindingScala) {
17 const isTarget = name.includes("/target");
18 const isTargetWeb = name.includes("/target/web");
19
20 console.log(
21 `File: ${name}\nIs Binding Scala: ${isBindingScala}\nIs Target: ${isTarget}\nIs Target Web: ${isTargetWeb}`
22 );
23
24 if (isTarget) {
25 return name.endsWith("/target") || isTargetWeb;
26 }
27 }
28
29 return internalExclude.every((ex) => !name.includes(ex));
30}
31
32/**
33 * Recursively copies the contents of one directory to another directory.

Callers 1

copyFolderRecursiveSyncFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected