(filePath, appName)
| 14 | const repeatChar = (char, times) => char.repeat(times); |
| 15 | |
| 16 | function replaceImport(filePath, appName) { |
| 17 | if (!fs.existsSync(filePath)) { |
| 18 | console.warn(`⚠ File not found: ${filePath}`); |
| 19 | return; |
| 20 | } |
| 21 | |
| 22 | const data = fs.readFileSync(filePath, "utf8"); |
| 23 | |
| 24 | const updated = data.replace( |
| 25 | /(import\s+com\.foxdebug\.)(acode|acodefree)(\.R;)/, |
| 26 | `$1${appName}$3` |
| 27 | ); |
| 28 | |
| 29 | fs.writeFileSync(filePath, updated); |
| 30 | } |
| 31 | |
| 32 | try { |
| 33 | if (!fs.existsSync(configXML)) { |