assaf / vanity

Experiment Driven Development for Ruby
http://vanity.labnotes.org
MIT License
1.55k stars 269 forks source link

Disable logs #358

Closed edenisn closed 5 years ago

edenisn commented 5 years ago

Good day. Can I somehow disable logs in development mode? It's very hard to find the right information in a big count of vanity logs. screen shot 2018-12-13 at 18 48 21

edenisn commented 5 years ago

I tried to do something like this in Rails:

file: config/environments/development.rb

Vanity.configure do |config|
    config.templates_path = 'app/views/vanity'
    config.logger  = Logger.new('/dev/null')
 end

but it did not help

edenisn commented 5 years ago

Ahhh, I found solution:

Vanity::Adapters::ActiveRecordAdapter::VanityExperiment.logger = Logger.new('/dev/null')