MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / resolveVariable

Method resolveVariable

tools/mcpack.js:1260–1267  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

1258 return null;
1259 }
1260 resolveVariable(value) {
1261 value = value.replace(/\$\(([^\)]+)\)/g, (offset, value) => {
1262 if (value in this.environment)
1263 return this.environment[value];
1264 return this.getenv(value);
1265 });
1266 return this.resolveSlash(value);
1267 }
1268 selectManifest(builtin) {
1269 let index;
1270 if (builtin.manifests.length == 1)

Callers 3

includeManifestMethod · 0.45
parseBuildMethod · 0.45
resolveSourceMethod · 0.45

Calls 2

replaceMethod · 0.80
resolveSlashMethod · 0.45

Tested by

no test coverage detected