whompmacs/whomp/whomp-ai.el

35 lines
968 B
EmacsLisp
Raw Normal View History

2024-07-13 18:35:50 +00:00
;;
;; AI packages
;; These are the packages uncommon to most developers but are
;; necessary to those they're necessary!
;;
(defcustom whomp-ai nil
"Whether or not to enable AI packages."
:type '(set (const :tag "None" nil)
(const :tag "copilot" copilotmode) ;; code completion
)
:group 'whomp-config)
(when (memq 'copilotmode whomp-ai)
(use-package dash
:straight t
:defer t)
(use-package editorconfig
:straight t
:defer t)
(use-package copilot
:straight (:host github :repo "zerolfx/copilot.el" :files ("dist" "*.el"))
:defer t
:ensure t
:config
;; you can utilize :map :hook and :config to customize copilot
(add-hook 'prog-mode-hook 'copilot-mode)
(define-key copilot-completion-map (kbd "<tab>") 'copilot-accept-completion)
(define-key copilot-completion-map (kbd "TAB") 'copilot-accept-completion))
(message "copilot loaded"))
(message "W.H.O.M.P. AI packages loaded")
(provide 'whomp-ai)
;; whomp-ai.el ends here