Skip to content

Add the ability to route stdout and stderr to different buffers based on regular expressions #1525

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
bbatsov opened this issue Jan 24, 2016 · 4 comments

Comments

@bbatsov
Copy link
Member

bbatsov commented Jan 24, 2016

It would be useful if we had the ability to redirect certain type of output (e.g. logging output to dedicated buffers for quick inspection).

Adding support for this won't be hard - basically we need a mapping between regular expressions or functions, that will be used to check if some output is a match, a buffer name (or some function) that will be used when we have a match. We just have to figure out what to do in the unlikely scenario of multiple matches - should check all patterns & predicates or just stop after the first match.

This functionality should be exposed to the users in the form of a defcustom.

@cch1
Copy link

cch1 commented Jan 24, 2016

+1

@Malabarba Malabarba modified the milestones: v0.11, v0.13.0 Feb 14, 2016
@cch1
Copy link

cch1 commented Mar 15, 2016

Still dreaming of seeing the org.apache.log4j.ConsoleAppender output in emacs... without having to go via a file.

@bbatsov bbatsov removed this from the v0.13.0 milestone Jun 18, 2018
@bbatsov bbatsov added good first issue A simple tasks suitable for first-time contributors and removed good first issue A simple tasks suitable for first-time contributors low hanging fruit labels May 8, 2019
@bbatsov
Copy link
Member Author

bbatsov commented May 14, 2019

In general it seems that this is not really doable, as when I created the ticket I had forgotten that output is spread over multiple messages (each containing a chunk of the output). Matching the contents of any one of them with a regular expression doesn't make much sense as they'd often be partial messages.

@bbatsov bbatsov closed this as completed May 14, 2019
@bbatsov bbatsov added wontfix and removed good first issue A simple tasks suitable for first-time contributors labels May 14, 2019
@hiteshjasani
Copy link

I'm working with a system in kubernetes that is generating a large amount of logs to STDOUT. The ability to blacklist certain log messages by regex so they get dropped and not printed to the REPL would be valuable to me.

Would this be doable, since I assume partial messages have to be reassembled before being printed to the REPL?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants