air icon indicating copy to clipboard operation
air copied to clipboard

support filtering log by regex

Open cosmtrek opened this issue 5 years ago • 1 comments

Sometimes there are verbose server logs nothings with my code often upset me. These logs can be filtered by regex.

cosmtrek avatar Dec 30 '18 11:12 cosmtrek

Pity that nothing happened on this. Air has some of the loudest logging we've seen, enough that we're thinking we should go with another hot reloader, or fork Air to get the logging under control.

The problem is that if you run Air inside of a container as we do, we have Air starting up on 10 containers, resulting in about 500 lines of logging in the Docker output that is very close to spam. The more subdirectories you have, the worse it is.

This makes Air potentially harmful, because you might miss something important. I've already missed a message from another container that was buried in the Air log output.

A regexp would work. But since regexp is voodoo for most people, perhaps just a simple array that accepts wildcards. Then it could be in the .toml file:

exclude_logs = ["watching*", "!exclude*"]

perholmes avatar Nov 15 '22 17:11 perholmes