emacs/vc: better feedback from 'SPC g {y,Y}'
This commit is contained in:
parent
550c9bda74
commit
ac21c09419
1 changed files with 10 additions and 5 deletions
|
@ -19,10 +19,13 @@ the URL."
|
|||
If a selection is active, highlight them. Otherwise omits the #L<N> suffix in
|
||||
the URL."
|
||||
(interactive)
|
||||
(let ((url
|
||||
(if (or (use-region-p)
|
||||
(ignore-errors (evil-visual-state-p)))
|
||||
(browse-at-remote-kill)
|
||||
(kill-new (browse-at-remote--file-url (buffer-file-name)))))
|
||||
(evil-visual-state-p))
|
||||
(browse-at-remote-get-url)
|
||||
(browse-at-remote--file-url (buffer-file-name)))))
|
||||
(kill-new url)
|
||||
(message "Copied to clipboard: %S" url)))
|
||||
|
||||
|
||||
(defun +vc--remote-homepage ()
|
||||
|
@ -40,4 +43,6 @@ the URL."
|
|||
(defun +vc/browse-at-remote-kill-homepage ()
|
||||
"Copy homepage URL of current project to clipboard."
|
||||
(interactive)
|
||||
(kill-new (+vc--remote-homepage)))
|
||||
(let ((url (+vc--remote-homepage)))
|
||||
(kill-new url)
|
||||
(message "Copied to clipboard: %S" url)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue