Skip to content

Commit

Permalink
emacs know ssh-agent
Browse files Browse the repository at this point in the history
  • Loading branch information
Chen Bin committed Sep 15, 2023
1 parent 083f000 commit 5c5304d
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lisp/init-essential.el
Original file line number Diff line number Diff line change
Expand Up @@ -291,5 +291,12 @@ If OTHER-SOURCE is 2, get keyword from `kill-ring'."
;; better performance
(setq show-paren-delay 0.5))

;; Make emacs know ssh-agent
;; @see https://emacs.stackexchange.com/questions/17866/magit-how-to-use-systems-ssh-agent-and-dont-ask-for-password
(my-run-with-idle-timer 2
(lambda ()
(exec-path-from-shell-copy-env "SSH_AGENT_PID")
(exec-path-from-shell-copy-env "SSH_AUTH_SOCK")))

(provide 'init-essential)
;;; init-essential.el ends here

0 comments on commit 5c5304d

Please sign in to comment.