Emacs config utilizing prelude as a base
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

54 lines
1.9 KiB

  1. ;;; prelude-windows.el --- Emacs Prelude: Windows-specific setup.
  2. ;;
  3. ;; Copyright © 2011-2021 Bozhidar Batsov
  4. ;;
  5. ;; URL: https://github.com/bbatsov/prelude
  6. ;; This file is not part of GNU Emacs.
  7. ;;; Commentary:
  8. ;; Additional setup that's useful when running Emacs in Windows.
  9. ;;; License:
  10. ;; This program is free software; you can redistribute it and/or
  11. ;; modify it under the terms of the GNU General Public License
  12. ;; as published by the Free Software Foundation; either version 3
  13. ;; of the License, or (at your option) any later version.
  14. ;;
  15. ;; This program is distributed in the hope that it will be useful,
  16. ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
  17. ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  18. ;; GNU General Public License for more details.
  19. ;;
  20. ;; You should have received a copy of the GNU General Public License
  21. ;; along with GNU Emacs; see the file COPYING. If not, write to the
  22. ;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  23. ;; Boston, MA 02110-1301, USA.
  24. ;;; Code:
  25. ;; Teach Emacs how to interpret various modifier keys
  26. (setq w32-pass-lwindow-to-system nil)
  27. (setq w32-lwindow-modifier 'super) ; Left Windows key
  28. (setq w32-pass-rwindow-to-system nil)
  29. (setq w32-rwindow-modifier 'super) ; Right Windows key
  30. (setq w32-pass-apps-to-system nil)
  31. (setq w32-apps-modifier 'hyper) ; Menu/App key
  32. ;; Git setup (assuming you've installed Git for Windows)
  33. (when (file-exists-p "C:/Program Files/Git/bin")
  34. (add-to-list 'exec-path "C:/Program Files/Git/bin")
  35. (add-to-list 'exec-path "C:/Program Files/Git/mingw64/bin")
  36. (setenv "PATH" (concat "C:/Program Files/Git/bin;" "C:/Program Files/Git/mingw64/bin;" (getenv "PATH"))))
  37. ;; needed for arc-mode (it allows you to open archives in Emacs)
  38. (if (file-exists-p "C:/Program Files/7-Zip")
  39. (add-to-list 'exec-path "C:/Program Files/7-Zip")
  40. (message "7-Zip not found. It's a good idea to install it."))
  41. (provide 'prelude-windows)
  42. ;;; prelude-windows.el ends here