-
Notifications
You must be signed in to change notification settings - Fork 4
New symbol to show that there is no upstream branch #3
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, I'm ok to add the flag, however I'd like a few changes (explained in the comment). Feel free to challenge my points.
README.md
Outdated
@@ -120,6 +120,7 @@ needs_to_merge_symbol | `ᄉ` | |||
needs_to_merge_color | `$yellow` | |||
has_upstream_symbol | `⇅` | |||
has_upstream_color | `$on` | |||
has_no_upstream_symbol | ` ⃢` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know this symbol, it probably comes from a patched font, however I'd rather have a standard unicode symbol as default. Because not everyone may have this symbol. Also the space may not be necessary.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The symbol is the unicode character SCREEN
However, it does not seem to be supported by many fonts. I replaced it with a character from your code.
An alternative would be to leave it empty and it can then be adjusted by the user via the variable.
I use a font from 'Awesome-Terminal-Fonts' with the symbol 'omg_not_tracked_branch_symbol' from 'oh-my-git'.
oh-my-git.plugin.zsh
Outdated
@@ -230,7 +231,7 @@ function oh_my_git_info { | |||
|
|||
else | |||
oh_my_git_string+=" | |||
${has_no_upstream_color}(${current_branch_color}${current_branch}${reset}${has_no_upstream_color})${reset} | |||
${has_no_upstream_color}(${current_branch_color}${current_branch}${reset}${has_no_upstream_color}${has_no_upstream_symbol})${reset} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't it be better if it was placed at the same position as the upstream indicator ([line 190-192]](0350b07#diff-d65f4cbd76d7f4fbc68f321e1ae82c3fR190)). Also I think it should be displayed only if the same (display_has_upstream
) is enabled, or a similar one.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, you're right, I didn't think of that. I've changed it.
I think the existing flag 'display_has_upstream' is sufficient for this.
Thanks for your work, here are some small extensions.