Helm has a variable called helm-maybe-use-default-as-input and a list helm-sources-using-default-as-input. When helm-maybe-use-default-as-input is non-nil or the function that's being called, i.e. helm-occur, belongs to helm-sources-using-default-as-input, helm treats empty input as the symbol at point. More specifically, if the point is at the word "hello" and I run helm-occur, it will match all of the instances of the word "hello" in the current buffer. The moment I input a single character, it will match my input instead.
Is there a way to make consult-line behave similarly? Currently, when consult-line is called, while input is still empty, it will match all non-empty lines in the buffer. I don't think matching all non-empty lines in the current buffer is common use case.
There is a partial solution in the wiki. However, it doesn't treat empty input as symbol at point, it fills the input with symbol at point. So using this means that, if I want to search for something other than the symbol at point, I have to either move the point to an empty area, or call this function and clear the minibuffer before I can start my search.
Hi and thanks for the great package!
Helm has a variable called
helm-maybe-use-default-as-input
and a listhelm-sources-using-default-as-input
. Whenhelm-maybe-use-default-as-input
is non-nil or the function that's being called, i.e.helm-occur
, belongs tohelm-sources-using-default-as-input
, helm treats empty input as the symbol at point. More specifically, if the point is at the word "hello" and I runhelm-occur
, it will match all of the instances of the word "hello" in the current buffer. The moment I input a single character, it will match my input instead.Is there a way to make
consult-line
behave similarly? Currently, whenconsult-line
is called, while input is still empty, it will match all non-empty lines in the buffer. I don't think matching all non-empty lines in the current buffer is common use case.There is a partial solution in the wiki. However, it doesn't treat empty input as symbol at point, it fills the input with symbol at point. So using this means that, if I want to search for something other than the symbol at point, I have to either move the point to an empty area, or call this function and clear the minibuffer before I can start my search.