0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-03 23:00:14 -05:00

🎨 🔦 read ghost version from package.json

refs #6982
[ci skip]
This commit is contained in:
kirrg001 2016-09-13 20:37:19 +02:00 committed by Hannah Wolfe
parent d42f4f6058
commit 042e0da1c9
2 changed files with 7 additions and 1 deletions

View file

@ -1,6 +1,7 @@
var nconf = require('nconf'),
path = require('path'),
localUtils = require('./utils'),
packageInfo = require('../../../package.json'),
env = process.env.NODE_ENV || 'development';
nconf.set('NODE_ENV', env);
@ -28,5 +29,11 @@ nconf.file('4', __dirname + '/defaults.json');
*/
localUtils.makePathsAbsolute.bind(nconf)();
/**
* values we have to set manual
* @TODO: ghost-cli?
*/
nconf.set('ghostVersion', packageInfo.version);
module.exports = nconf;
module.exports.isPrivacyDisabled = localUtils.isPrivacyDisabled.bind(nconf);

View file

@ -1,5 +1,4 @@
{
"ghostVersion": "0.10.1",
"paths": {
"appRoot": ".",
"corePath": "core/",