-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Description
Preface
Currently, I'm using History::display to display the navigation history for my editor, and I find it confusing during branch switching.
Steps to reproduce
For example, say we start with the following tree:
* 1-3 [HEAD] src/position.rs
* 1-2 src/soft_wrap.rs
| * 0-3 src/quickfix_list.rs
| * 0-2 src/context.rs
|/
* 1-1 src/components/editor.rs
* 1-0 [SAVED]
Expected outcome
And when I switched to [0-3], I expect it to display as follows (only [HEAD] is moved):
* 1-3 src/position.rs
* 1-2 src/soft_wrap.rs
| * 0-3 [HEAD] src/quickfix_list.rs
| * 0-2 src/context.rs
|/
* 1-1 src/components/editor.rs
* 1-0 [SAVED]
Actual outcome
However, it surprised me by totally modifying the tree, specifically:
- Making branch
0the main trunk - Renaming entries
1-1and1-0, to0-1and0-0respectively
* 0-3 [HEAD] src/quickfix_list.rs
* 0-2 src/context.rs
| * 1-3 src/position.rs
| * 1-2 src/soft_wrap.rs
|/
* 0-1 src/components/editor.rs
* 0-0 [SAVED]
Metadata
Metadata
Assignees
Labels
No labels