Skip to content

Commit

Permalink
Make vc one button
Browse files Browse the repository at this point in the history
  • Loading branch information
jcs090218 committed Feb 26, 2024
1 parent 3f51751 commit f690654
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions jcs-modeline.el
Original file line number Diff line number Diff line change
Expand Up @@ -424,15 +424,21 @@ mouse-1: Reveal project in folder" project)
(backend-icon (if (jcs-modeline--char-displayable-p backend-icon)
backend-icon
""))
(branch (or (vc-git--symbolic-ref bfn) "")))
(branch (or (vc-git--symbolic-ref bfn) ""))
(separator (if (and backend-icon
(not (string-empty-p backend-icon)))
" "
""))
(tip (jcs-modeline-2str backend)))
(concat (propertize backend-icon
'mouse-face 'mode-line-highlight
'help-echo (jcs-modeline-2str backend))
(if (and backend-icon (not (string-empty-p backend-icon))) " " "")
(propertize branch
'help-echo tip)
(propertize (concat
separator
branch)
'face 'jcs-modeline-vc-face
'mouse-face 'mode-line-highlight
'help-echo branch)
'help-echo tip)
" ")))

;;
Expand Down

0 comments on commit f690654

Please sign in to comment.