Questions tagged [quickfix]

Questions about the usage of quickfix commands and quickfix windows.

Filter by
Sorted by
Tagged with
0 votes
1 answer
56 views

error not formatted as per efm

I have created a mwe plugin to show my problem for fortran ft. tree ftrial ftrial ├── autoload │   └── makes.vim └── ftplugin └── fortran_mk.vim with cat ftrial/autoload/makes.vim " ...
BaRud's user avatar
  • 471
1 vote
1 answer
50 views

Buffer opened when compiling succeeds

I am writing a vim plugin for the fortran filetype. In an autoload script, I have done: " File Name: autoload/makes.vim let s:Compiler = get(g:, "fortran_compiler", "gfortran"...
BaRud's user avatar
  • 471
1 vote
1 answer
154 views

Text to vim-quickfix with navigation

LaTeX, being a markup language, is very hard to grammar-check. I found one program, that do this exactly Textidote. Problem is, this is a standalone program and, for example, this latex code: \...
BaRud's user avatar
  • 471
0 votes
1 answer
521 views

How can I have lnext/lprev fallback to cnext/cprev when appropriate?

It is often the case that I am in projects with varying filetypes. Sometimes I'm compiling using :make<CR> and sometimes I'm using plugins like ALE. At any given time, I probably only have one ...
Will Bradley's user avatar
0 votes
1 answer
35 views

Quickfix stack doesn't work when using make -j

As mentioned in other questions, using make -C buildpath as makeprg in Vim and the appropriate errorformat triggers the nice handling of the quickfix directory stack. That is, the quickfix uses the "...
Albert Gil Moreno's user avatar
1 vote
1 answer
407 views

How to insert text using substitute and regex?

Honestly I can't read regex for now. I have quick-fix list and I have a hunch that this can be done with regex but I don't know how. I want this: @ViewChild(MatTable) @ViewChild('text 1') @...
zer09's user avatar
  • 149
2 votes
1 answer
165 views

Why does `:cdo print` not show full output?

:cdo print command (intended to print every line in the quickfix list), shows generic file information instead of line output for some quickfix entries. Why is this? The following example is taken ...
mxxk's user avatar
  • 227
0 votes
1 answer
593 views

Quickfix won't parse :make output

My makeprg is set to: cd build/ && cmake --build . --config Debug && ctest && gdb -q -ex run ./a This allows me to build application, run tests and start debugging session ...
Alex's user avatar
  • 11
0 votes
3 answers
934 views

Highlight results of :grep while in quickfix window

To my .vimrc I added a hook which automates entering the quickfix after :grep processing: autocmd QuickFixCmdPost [^l]* nested cwindow 20 Another thing I care about but can't achieve is automation ...
bloody's user avatar
  • 140
2 votes
1 answer
365 views

How to put the output of a function call into quickfix list?

I have the following function that runs eslint project wise: function! EslintProject() " Allows using eslint --format compact output with quickfix list set errorformat+=%f:\ line\ %l\\,\ col\ %c\\...
Henrique Barcelos's user avatar
3 votes
0 answers
444 views

How to search the output of vim command line commands like `:ls`, `:browse oldfiles`

Back from emacs recently, in emacs I can list all the existing buffers in a emacs buffer, where I can do search, delete or jumping etc. In Vim, if I type :browse oldfiles, a long list may be returned ...
Yukun Du's user avatar
0 votes
1 answer
676 views

Neovim, read entries from the terminal into quickfix buffer

I made my own vim wrapper around ripgrep (I know there is vim-grepper, but I wanted to try customize some things). The crux of it is I populate a quickfix window as follows: let searchString = input(...
run_the_race's user avatar
2 votes
1 answer
125 views

Why does this binding break the quickfix window? [duplicate]

If I have this vimrc: set nocompatible nnoremap <C-m> ^^ When I try to open a file from the quickfix window by pressing enter nothing happens. If I comment out the last line, so the vimrc is ...
Alligator's user avatar
  • 141
1 vote
2 answers
258 views

Put in quickfix list the files whose content does not match a pattern inside it

I would like to put in the quickfix the files not matching a pattern. That it, these files don't have any line matching the search pattern. I know that for finding files whose content match a pattern ...
aturegano's user avatar
  • 179
0 votes
1 answer
188 views

Line position after quickfix jump

I'm using fzf's Rg command to populate QuickFix window with all search results. I also have my own mappings to :cn and :cp commands. Everything is fine except one thing when I press mapped key for :...
igor.sol's user avatar
  • 103
3 votes
1 answer
795 views

Open quickfix Window Only, Don't Jump To First Result

Is there a way to open just the quickfix list without jumping to the first result when using :lt? I am using :lt to populate the location list with tags that match with the following binding: nmap &...
ThoseKind's user avatar
  • 219
1 vote
2 answers
812 views

quickfix Menu Usage With :tselect and :vimgrep

I am currently using the following mapping to search for knows tags: nnoremap <expr> <Leader>t "<ESC>:tselect /" . input("") . "<ESC>" I also use this mapping to grep all ...
ThoseKind's user avatar
  • 219
2 votes
1 answer
760 views

Open quickfix/help in existing window [duplicate]

my usual setup is two vertically split windows. Lets say my cursor is in left window. When I vimgrep something, I would like for quickfix window to reuse already opened right window and automatically ...
Vjekoslav's user avatar
2 votes
1 answer
111 views

visit file from quickfix list without populating oldfiles

I like consulting my oldfiles to see what I've been working on recently and to make it easy to find files that are buried deep in various directories. Before I started using the grep and make commands,...
Greg Nisbet's user avatar
  • 1,785
2 votes
1 answer
172 views

load quickfixlist into a specific window

I'm not interested in loading an item into a specific window. I'm interested in opening/loading quickfix list into a specific window/pane. Searched online everywhere, but couldn't find it. Does anyone ...
flashburn's user avatar
  • 689
1 vote
1 answer
885 views

Visual delete items from quickfix list

I am trying to delete items from the quickfix list, using the same delete interface I am used to, visual delete and dd. The .vimrc code I am trying to use to accomplish this is below. It does not work....
Josh Lawrence's user avatar
1 vote
1 answer
540 views

Quickfix and building a CMake project on windows

I'm trying to get to the point where I can build a CMake project in neovim and have it output a quickfix list that I can quickly step through. In Visual Studio, I would typically hit CTRL+b for build,...
cmaughan's user avatar
  • 131
1 vote
0 answers
35 views

Quickfix mode with path transformation

I have a build log file from compiling a project with Visual Studio on a Windows machine, and would like to use quickfix mode to jump to the errors and warnings in that logfile. The logfile is read ...
Simon Richter's user avatar
1 vote
2 answers
313 views

:cnext / :cprevious without jumping to location

I've got a pretty large log file with some info interleaved with some errors / warnings and I would like to go to the next error in my quickfix window but without jumping to that location in the code. ...
Anthony's user avatar
  • 11
3 votes
1 answer
248 views

How to make two windows equally high?

It seems that there is an issue with window-resize with Quickfix list window. In case of regular window and quickfix list window, how to make them equal in high? The CTRL-W- (and the CTRL-W+) works,...
IvanDi's user avatar
  • 99
0 votes
2 answers
1k views

How to use setqflist to add an entry to the quickfix list

I'd like to be able to define my own functions that add certain kinds of line to the quickfix list, or set it to those in its entirety, without having to go via the filesystem with a made-up errorfile ...
OJFord's user avatar
  • 395
1 vote
2 answers
907 views

Go to next quickfix entry, removing current?

Is there a way to 'delete current, and cnext' so that when progressing through the quickfix list progress can more easily be seen, and, when all quick fixes have been made, the window automatically ...
OJFord's user avatar
  • 395
2 votes
0 answers
80 views

How can I make 'lnext' run 'lfirst' if it needs to be?

I use ALE for finding syntax errors in code in vim, which populates the loclist with any errors found. However, when I first open a file with errors, which populates that list (I have g:...
Andrew Ferrier's user avatar
3 votes
3 answers
159 views

Plugin to show enclosing indentation levels

I'm looking for functionality which may or may not exist. Basically, I'd like to have a location list split at the top of each writable buffer which shows the last line of each enclosing indentation ...
mnosefish's user avatar
  • 173
6 votes
1 answer
521 views

Changing how the quickfix list displays matches

I have the habit of leaving comments in my C source files like // @TODO or // @CHECK to quickly be able to get back to where I may have things to do. I can already match those in pretty much any ...
FlatBartender's user avatar
7 votes
2 answers
8k views

How can I close the quickfix window and go back to the file I was editing

I use gutentags and gutentags-plus for generating and managing tag files. When I use the key combinations setup by them ( cX usually ), it opens the relevant lines in a quickfix window and I can use :...
Osada Lakmal's user avatar
1 vote
1 answer
107 views

Echoing a message when grep has no result

Is there a way echoing a message if grep has no result and getqflist() is empty? I've tried this, but it doesn't work: au QuickFixCmdPost grep call g:GrepPostActions() function! g:GrepPostActions()...
Mattia72's user avatar
  • 191
0 votes
1 answer
179 views

Modify Quickfix to ignore paths outside project

I have been learning about quickfix recently, trying to make it work well with pytest to that end I provided my own makeprg and efm. So far everything is great except that pytest frequently traces ...
sgp667's user avatar
  • 125
3 votes
0 answers
387 views

Quickfix go to next error of specific type

I am starting to use quickfix to handle my latex compilation process. I found the vim-latex package (https://github.com/vim-latex/vim-latex) but I am only interested in the quickfix part, and I want ...
Weijun Zhou's user avatar
5 votes
1 answer
385 views

Skip the quickfix list when buffer switching using :bn

Often when editing LaTeX files, you are constantly switching between your .tex, .sty and .bib files which are often in their own buffer. To navigate between those, I use the :bn and :bp commands ...
Benjamin Chausse's user avatar
1 vote
0 answers
270 views

Add conceal in function

Trying to maintain add conceals to the generated location list, but I can not figure it out. The current workaround is to add it manually everytime through the vim commandline, like: : set ...
jolanda's user avatar
  • 11
2 votes
1 answer
79 views

Maintain concealed text in quickfix buffer

Would like to maintain the concealed text in the locationlist (aka quickfix) from the targeted file, which has the extension .rex . For example, the target file is has: +- concealed to ± The ...
jolanda's user avatar
  • 21
1 vote
1 answer
377 views

function: sort output alphabetically

This function outputs data between braces as joined lines in a quickfix window. The output is sorted based on line numbers. I'm searching for a method to sort the data alphabetically. I tried to ...
Jane's user avatar
  • 11
1 vote
0 answers
72 views

How to write to a temproary buffer in a plugin

I've started to write my first vim plugin, a simple timer. I want to be able to set a timer for an arbitrary amount of time, and have it notify me once that time has passed. I've got it all working, ...
Elias Van Ootegem's user avatar
2 votes
1 answer
412 views

Close multiple quickfix windows

I love the quickfix feature in vim. It also works flawlessly in most cases. But when I work with LaTeX documents, it leads to funny behavior. I don't think it's relevant, but I have the LaTeX suite ...
pfnuesel's user avatar
  • 674
4 votes
2 answers
1k views

how to check whether the location list for the current window is open

Using getwininfo it is possible to determine whether an window is a quickfix window or location list window. But once a location list window is found, how can I know which window it is associated ...
doraemon's user avatar
  • 1,647
4 votes
1 answer
584 views

how to get the index of the current item in quickfix list

I can use getqflist() to get the whole list. But how can I know which is the currently selected item in the list? It is used if :cc [nr] without specifying nr. It is also used for cnext and cprev. But ...
doraemon's user avatar
  • 1,647
2 votes
1 answer
621 views

Give variable to makeprg

I'm trying to put the output of a command into a QuickFix list when a particular key is pressed. That command takes as its argument the word under the cursor, so my function looks basically like this (...
zondo's user avatar
  • 123
1 vote
1 answer
120 views

Put error into quickfix window

I can customize some error display in my file like highlight all white space at the end of each line by: :match ErrorMsg /\s\+$/ Can I put all the error I found into quickfix windows that I can go ...
How Chen's user avatar
  • 113
4 votes
2 answers
2k views

Using global command on Quickfix entries [duplicate]

I find and replace a pattern in all the files in my project (which is a big one). After the search is done, quickfix window is opened with the matches. The matches are in different files in different ...
Salahuddin Ahmed's user avatar
0 votes
1 answer
31 views

How to automatically return to where the cursor was before executing cdo?

Is it possible to automatically return to where the cursor was before running :cdo command? Currently, the cursor ends in the last file in the quickfix, then I have to navigate back to where I was ...
Salahuddin Ahmed's user avatar
3 votes
2 answers
8k views

How to set a shortcut to run make in Vim and show the output

I'd like to run make and display the output when I press Ctrl+m in Vim. I know how to run make and display the output while in command mode, thanks to this StackOverflow answer, namely with: :make | ...
Josh Pinto's user avatar
2 votes
3 answers
2k views

Open quickfix window without focusing it

I run my make commands asynchronously in vim with the asyncrun plugin. I use this code in my .vimrc to open the quickfix window automatically everytime I run an asynchronous make command in order to ...
Natjo's user avatar
  • 123
1 vote
1 answer
1k views

How to differentiate quickfix window buffers and location list buffers?

Recently I've been playing with my statusline and I'm coming to a point where I want to set a different highlighting group for the statusline of my quickfix window, location list window, and the other ...
statox's user avatar
  • 49k
8 votes
2 answers
488 views

How to capture errors from make in terminal window

Vim 8.1's release note seems to indicate that you can feed output from make running in a terminal window to a quickfix list, but I couldn't find any detailed explanation. Is there a way to do this ...
Sora Minazuki's user avatar