Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
var config = require('ghost-ignition').config();
// see defaults in GhostLogger
var logging = require('ghost-ignition').logging({
path: config.get('logging:path'),
domain: config.get('logging:domain'),
mode: config.get('logging:mode'),
level: config.get('logging:level'),
transports: config.get('logging:transports')
});
module.exports = logging;
var debug = require('ghost-ignition').debug('ghost-version'),
exec = require('child_process').exec,
config = require('ghost-ignition').config(),
fetchGhostVersion,
middleware,
ghostVersion,
ttl;
fetchGhostVersion = function fetchGhostVersion() {
debug('Ghost version not set or ttl expired');
exec('npm show ghost version', function (err, stdout, stderr) {
if (err) {
debug('fetchGhostVersion err', err);
}
if (stderr) {
debug('fetchGhostVersion stderr', stderr);
}