parent
9e122c6847
commit
851b51357e
1 changed files with 10 additions and 10 deletions
|
@ -228,21 +228,21 @@ Relevant: `doom-project-hook'."
|
||||||
`(lambda ()
|
`(lambda ()
|
||||||
(and (not (bound-and-true-p ,name))
|
(and (not (bound-and-true-p ,name))
|
||||||
(and buffer-file-name (not (file-remote-p buffer-file-name nil t)))
|
(and buffer-file-name (not (file-remote-p buffer-file-name nil t)))
|
||||||
,(when match
|
,(or (null match)
|
||||||
`(if buffer-file-name (string-match-p ,match buffer-file-name)))
|
`(if buffer-file-name (string-match-p ,match buffer-file-name)))
|
||||||
,(when files
|
,(or (null files)
|
||||||
;; Wrap this in `eval' to prevent eager expansion
|
;; Wrap this in `eval' to prevent eager expansion
|
||||||
;; of `project-file-exists-p!' from pulling in
|
;; of `project-file-exists-p!' from pulling in
|
||||||
;; autoloaded files prematurely.
|
;; autoloaded files prematurely.
|
||||||
`(eval
|
`(eval
|
||||||
'(project-file-exists-p!
|
'(project-file-exists-p!
|
||||||
,(if (stringp (car files)) (cons 'and files) files))))
|
,(if (stringp (car files)) (cons 'and files) files))))
|
||||||
,(or when t)
|
,(or when t)
|
||||||
(,name 1)))))
|
(,name 1)))))
|
||||||
`((dolist (mode ,modes)
|
`((dolist (mode ,modes)
|
||||||
(let ((hook-name
|
(let ((hook-name
|
||||||
(intern (format "doom--enable-%s%s-h" ',name
|
(intern (format "doom--enable-%s%s-h" ',name
|
||||||
(if (eq mode t) "" (format "-in-" mode))))))
|
(if (eq mode t) "" (format "-in-%s" mode))))))
|
||||||
(fset hook-name #',fn)
|
(fset hook-name #',fn)
|
||||||
(if (eq mode t)
|
(if (eq mode t)
|
||||||
(add-to-list 'auto-minor-mode-magic-alist (cons hook-name #',name))
|
(add-to-list 'auto-minor-mode-magic-alist (cons hook-name #',name))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue