Change `exec-path'

This commit is contained in:
Case Duckworth 2021-03-24 16:22:39 +00:00
parent f6d1bf0e04
commit 47bdc595c5
1 changed files with 9 additions and 20 deletions

View File

@ -98,26 +98,15 @@
;;; Bootstrap package manager (`straight.el')
;; 1. Update `exec-path'.
(let ((win-app-dir "~/Applications"))
(dolist (path (list
;; Windows
(expand-file-name "exe" win-app-dir)
(expand-file-name "exe/bin" win-app-dir)
(expand-file-name "Git/bin" win-app-dir)
(expand-file-name "Git/usr/bin" win-app-dir)
(expand-file-name "Git/mingw64/bin" win-app-dir)
(expand-file-name "Everything" win-app-dir)
(expand-file-name "Win-builds/bin" win-app-dir)
(expand-file-name "Z/bin" win-app-dir)
(expand-file-name "racket" win-app-dir)
;; Linux
(expand-file-name "bin" user-emacs-directory)
(expand-file-name "~/bin")
(expand-file-name "~/.local/bin")
(expand-file-name "~/usr/bin")
))
(when (file-exists-p path)
(add-to-list 'exec-path path :append))))
(dolist (path (list (expand-file-name "bin" user-emacs-directory)
(expand-file-name "~/bin")
(expand-file-name "~/.local/bin")
(expand-file-name "~/usr/bin")
(expand-file-name "~/cmd")
(expand-file-name "~/mingw64/bin")))
(when (file-exists-p path)
(add-to-list 'exec-path path :append)))
;; 1.5. Update $PATH to reflect changes.
(setenv "PATH" (mapconcat #'identity exec-path path-separator))