Commit 9831ef6077dcd85c5c333ffb3d90d3667ade0ffb
Respect empty ssb_appname env var
Charles Lehner committed on 3/22/2016, 11:48:19 PMParent: e79a1c8ddcfc1950835039e14b72f92377eed48a
Files changed
server.js | changed |
server.js | ||
---|---|---|
@@ -2,9 +2,9 @@ | ||
2 | 2 | ':' //; exec "$(command -v nodejs || command -v node)" "$0" "$@" |
3 | 3 | // http://unix.stackexchange.com/questions/65235/universal-node-js-shebang |
4 | 4 | // vi: ft=javascript |
5 | 5 | |
6 | -var appName = process.env.ssb_appname || | |
6 | +var appName = 'ssb_appname' in process.env ? process.env.ssb_appname : | |
7 | 7 | require('child_process').spawnSync('git', ['config', 'ssb.appname'], |
8 | 8 | {encoding: 'utf8'}).stdout.trim() |
9 | 9 | var config = require('ssb-config/inject')(appName) |
10 | 10 | var ssbClient = require('ssb-client') |
Built with git-ssb-web