Skip to content

Commit

Permalink
Merge pull request #1022 from varya/feature/1007_option-to-disable-log
Browse files Browse the repository at this point in the history
Build option to disable server log. Fix #1007
  • Loading branch information
Junaid Rasheed committed Nov 2, 2016
2 parents 775bbfe + dc11e1a commit 72b3deb
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,11 @@ The server also has the ability to refresh changed styles or KSS markup without

Port of the server. Default is 3000.

<a name="option-disableServerLog"></a>
**disableServerLog** (boolean, optional)

Disables embedded server log.

<a name="option-rootPath"></a>
**rootPath** (string, optional)

Expand Down
1 change: 1 addition & 0 deletions lib/modules/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ function sanitizeOptions(opt) {
customColors: opt.customColors || false,
server: opt.server || false,
port: opt.port || 3000,
disableServerLog: opt.disableServerLog || false,
basicAuth: opt.basicAuth || null,
rootPath: opt.rootPath,
readOnly: opt.readOnly || false,
Expand Down
4 changes: 3 additions & 1 deletion lib/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ module.exports = function(options) {
app = express();

//app.use(favicon(__dirname + '/public/favicon.ico'));
app.use(logger('dev'));
if (!options.disableServerLog) {
app.use(logger('dev'));
}
app.use(bodyParser.json());
app.use(bodyParser.urlencoded({
extended: true
Expand Down

0 comments on commit 72b3deb

Please sign in to comment.