Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
parse: function(str, options) {
/* eslint no-eval: 0 */
return coffee['eval'](str, options);
}
}
parse: function(str, options) {
/* eslint no-eval: 0 */
return coffee['eval'](str, options);
}
}
compileConfigFile(configPath, outputPath){
const fs = require("fs");
const CoffeeScript = require("coffee-script");
const config = fs.readFileSync(configPath).toString();
CoffeeScript.eval(config);
const output = this.compileConfigData(config);
fs.writeFileSync(outputPath, output);
}
compileConfigData(source, cson = false){
if(cson) source = require("coffee-script").eval(source);
const directoryIcons = this.compileList(source.directoryIcons);
const fileIcons = this.compileList(source.fileIcons);
const indexedLists = this.indexLists([directoryIcons, fileIcons]);
return this.stringify(indexedLists);
}