MCPcopy
hub / github.com/iptv-org/iptv / compile

Method compile

scripts/core/markdown.ts:18–29  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

16 }
17
18 compile() {
19 const workingDir = process.cwd()
20
21 const templatePath = path.resolve(workingDir, this.template)
22 const template = fs.readFileSync(templatePath, 'utf8')
23 const processedContent = this.processIncludes(template, workingDir)
24
25 if (this.build) {
26 const outputPath = path.resolve(workingDir, this.build)
27 fs.writeFileSync(outputPath, processedContent, 'utf8')
28 }
29 }
30
31 private processIncludes(template: string, baseDir: string): string {
32 const includeRegex = /#include\s+"([^"]+)"/g

Callers 1

mainFunction · 0.95

Calls 1

processIncludesMethod · 0.95

Tested by

no test coverage detected