Pull copyright from license - easier to maintain single place

This commit is contained in:
Bryan Ashby 2018-04-10 19:53:04 -06:00
parent 7bd980c886
commit 207e361c03
1 changed files with 6 additions and 3 deletions

View File

@ -25,9 +25,12 @@ exports.main = main;
// object with various services we want to de-init/shutdown cleanly if possible // object with various services we want to de-init/shutdown cleanly if possible
const initServices = {}; const initServices = {};
const ENIGMA_COPYRIGHT = 'ENiGMA½ Copyright (c) 2014-2017 Bryan Ashby'; // only include bbs.js once @ startup; this should be fine
const COPYRIGHT = fs.readFileSync(paths.join(__dirname, '../LICENSE.TXT'), 'utf8').split(/\r?\n/g)[0];
const FULL_COPYRIGHT = `ENiGMA½ ${COPYRIGHT}`;
const HELP = const HELP =
`${ENIGMA_COPYRIGHT} `${FULL_COPYRIGHT}
usage: main.js <args> usage: main.js <args>
eg : main.js --config /enigma_install_path/config/ eg : main.js --config /enigma_install_path/config/
@ -90,7 +93,7 @@ function main() {
function complete(err) { function complete(err) {
// note this is escaped: // note this is escaped:
fs.readFile(paths.join(__dirname, '../misc/startup_banner.asc'), 'utf8', (err, banner) => { fs.readFile(paths.join(__dirname, '../misc/startup_banner.asc'), 'utf8', (err, banner) => {
console.info(ENIGMA_COPYRIGHT); console.info(FULL_COPYRIGHT);
if(!err) { if(!err) {
console.info(banner); console.info(banner);
} }