How to copy file path in emacs helm-mode

I use helm-mode in emacs to open files. However, when I try to copy the file path (say / home / user1 / Documents / file1.txt) with the left mouse button and hold to paste it into the terminal, I get a message with the message

<down-mouse-1> is undefined

I think helm does not support mouse operations, as described here , and in this case, how can I copy the file path from emacs (at the helm -mode) to paste it into the terminal

+4
source share
2 answers

, Minibuffer . . M-w , . , nil ed x-select-enable-clipboard, . init.el

(defun copy-to-clipboard()
  (interactive)
  (setq x-select-enable-clipboard t)
  (kill-ring-save (region-beginning) (region-end))
  (setq x-select-enable-clipboard nil))

(defun paste-from-clipboard ()
  (interactive)
  (setq x-select-enable-clipboard t)
  (yank)
  (setq x-select-enable-clipboard nil))

, (.. ) ; set-mark-command ( C-SPC C-@) (.. ). shift , . mark-word ( M-@), .

asciinema ( 🙂),

+1

, , .

: , , C-u C-c C-k. helm-kill-selection-and-quit. kill Emacs .

0

Source: https://habr.com/ru/post/1608550/


All Articles