sublimehq / sublime_merge

Issue tracker for Sublime Merge
https://www.sublimemerge.com
274 stars 14 forks source link

Locations sidebar: format the display of Stash entries that have a custom message #1829

Open Paul-van-Klaveren opened 11 months ago

Paul-van-Klaveren commented 11 months ago

Problem description

In short: Stash entries for which the user has supplied a message are unnecessarily hard to find.

Explanation

In the Locations sidebar we can expand the Stashes to see the entries listed. The entries appear to be identical to the output of git stash list — without the stash@{index} prefix:

Interestingly, git places its regular WIP 'message' before the branch name, whereas it places the custom message after On <branch name>. … and that's exactly the problem, because if you work in a project where you are required to have verbose branch names the On <verbose branch name that takes up a lot of space> pushes the user's message all the way to the right. This makes it cumbersome to scan the list for messages and find what you're looking for; almost up to the point that adding a message has no added value. Moreover, the user is required to increase the width of the sidebar substantially to get the messages in view — and then decrease the size to read the diff of the selected stash entry.

Preferred solution

Ideally, there would be a Sublime Merge setting to format the Stashes list differently, e.g. put the user's stash message before the branch part, or leave out the branch part entirely for stashes with messages.

Paul-van-Klaveren commented 11 months ago

Workaround

Create a temporary branch with a single character name that you don't intend to use for anything other than to stash-with-message, then stash on that brand, and afterwards remove the branch.

image