Skip to content
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

Is there an option to remove "||" in the quickfix output? #228

Open
zoumi opened this issue Jun 19, 2021 · 5 comments
Open

Is there an option to remove "||" in the quickfix output? #228

zoumi opened this issue Jun 19, 2021 · 5 comments

Comments

@zoumi
Copy link

zoumi commented Jun 19, 2021

asyncrun.vim will output something like this

|| [xxxxxx]
...
...
|| Hello, world!
|| [Finished in 2 seconds]

I need copy the output of my cmd. Can I tell asyncrun.vim to not add "||" at the begin of line?
(I need error format be captured, so I can't use "-raw" option)

@jobo3208
Copy link

FWIW, it looks like Vim itself adds the "||" to the quickfix contents when displaying them. You can verify this by inspecting the list returned from getqflist() -- the quickfix entries themselves do not contain the leading "||".

I searched around for a way to modify the way Vim displays the quickfix list, but it doesn't appear to be configurable. Your best (only?) bet may be to use an autocommand to temporarily make the quickfix buffer modifiable, and then to do a substitution to remove the leading pipes. At that point, though, you may begin to wonder (as I did) if the quickfix buffer is really the right tool for the job...

@skywind3000
Copy link
Owner

try this:

:AsyncRun -mode=term -pos=TAB  ls -la

@jobo3208
Copy link

Thanks! I didn't even think of using the built-in terminal. (I don't have much experience with it.) This indeed gets rid of the leading pipes, and feels like the more appropriate tool for my particular use case.

@aemonge
Copy link

aemonge commented Sep 6, 2022

But that makes the qf not to update :(

@skywind3000
Copy link
Owner

"||" is a part of quickfix window, you can copy content from quickfix and remove the first 2 columns.

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

No branches or pull requests

4 participants