Fellow Stranger
Fellow Stranger

Reputation: 34013

Want logs in console but not in development.log

For several reasons I don't want Rails to write log info to development.log.

How can I accomplish that but still output log info in the console?

Inserting the following to config/environments/development.rb stopped logs to both development.log and the console:

config.log_level = :fatal

Upvotes: 1

Views: 935

Answers (1)

Brian
Brian

Reputation: 5481

Per this comment (https://stackoverflow.com/a/19082842/4638378):

you can log to STDOUT in development.rb:

config.logger = Logger.new(STDOUT)

Upvotes: 2

Related Questions