Skip to content

prompts deduplicate their history#15271

Open
Axlefublr wants to merge 1 commit intohelix-editor:masterfrom
Axlefublr:Axlefublr/history_dedup
Open

prompts deduplicate their history#15271
Axlefublr wants to merge 1 commit intohelix-editor:masterfrom
Axlefublr:Axlefublr/history_dedup

Conversation

@Axlefublr
Copy link
Contributor

Normally, if you execute these three command mode commands in a row:

:echo banana
:echo potato
:echo banana

You will have this in your command mode history (meaning, : register)

echo banana
echo potato
echo banana

If we scale this up to a long helix session, you might end up having a lot of repeats, that are annoying to ↑ through.

With this pr, when you accept your input in a prompt and it's added to history, all the previous times this exact input was in history, is cleaned up.
So, you'll end up with just this instead:

echo potato
echo banana

If you :echo potato from this state, now your history is:

echo banana
echo potato

I use command mode as the example, but all prompts that have history are affected by this improvement.

If you like this change, check out my #15266 also.

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

Successfully merging this pull request may close these issues.

1 participant