Browse Source

fallback for output path

master
P.BARRY 7 years ago
parent
commit
3283110bd9
1 changed files with 8 additions and 1 deletions
  1. 9
      config.js

9
config.js

@ -38,7 +38,6 @@ config.killZone = {
right: 25 right: 25
} }
config.output = __dirname
config.output = path.join(config.output, 'bobinoscope') config.output = path.join(config.output, 'bobinoscope')
try { try {
@ -46,6 +45,14 @@ try {
console.log('[!] Bobinogrammes will be available in: ' + config.output) console.log('[!] Bobinogrammes will be available in: ' + config.output)
} catch (e) { } catch (e) {
console.log('[!] Failed to create folders: ' + config.output) console.log('[!] Failed to create folders: ' + config.output)
try {
config.output = process.cwd()
config.output = path.join(config.output, 'bobinoscope')
console.log('[!] Bobinogrammes will be available in: ' + config.output)
} catch (e) {
console.log('[!] Failed to create folders: ' + config.output)
process.exit(1)
}
} }
// Init PATH // Init PATH

Loading…
Cancel
Save