(command, workingDirectory = '../')
| 33 | } |
| 34 | |
| 35 | function executeCommand(command, workingDirectory = '../') { |
| 36 | exec(command, { cwd: path.resolve(__dirname, workingDirectory) }, (error, stdout, stderr) => { |
| 37 | if (error) { |
| 38 | console.error(`An error occurred while executing command "${command}":`, error); |
| 39 | return; |
| 40 | } |
| 41 | if (stderr) { |
| 42 | console.error(`Command error "${stderr}"`); |
| 43 | return; |
| 44 | } |
| 45 | }); |
| 46 | } |
| 47 | |
| 48 | function main() { |
| 49 | files.forEach((file) => { |