mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-01 12:17:25 -05:00
lang/sh: remove zsh detection
sh-mode already does its own detection for zsh, so this is unnecessary.
This commit is contained in:
12
modules/lang/sh/config.el
Normal file → Executable file
12
modules/lang/sh/config.el
Normal file → Executable file
@ -49,17 +49,7 @@
|
|||||||
(add-hook 'sh-mode-hook #'rainbow-delimiters-mode)
|
(add-hook 'sh-mode-hook #'rainbow-delimiters-mode)
|
||||||
|
|
||||||
;; autoclose backticks
|
;; autoclose backticks
|
||||||
(sp-local-pair 'sh-mode "`" "`" :unless '(sp-point-before-word-p sp-point-before-same-p))
|
(sp-local-pair 'sh-mode "`" "`" :unless '(sp-point-before-word-p sp-point-before-same-p)))
|
||||||
|
|
||||||
;; sh-mode has file extensions checks for other shells, but not zsh, so...
|
|
||||||
(add-hook! 'sh-mode-hook
|
|
||||||
(defun +sh-detect-zsh-h ()
|
|
||||||
(when (or (and buffer-file-name
|
|
||||||
(string-match-p "\\.zsh\\'" buffer-file-name))
|
|
||||||
(save-excursion
|
|
||||||
(goto-char (point-min))
|
|
||||||
(looking-at-p "^#!.+/zsh[$ ]")))
|
|
||||||
(sh-set-shell "zsh")))))
|
|
||||||
|
|
||||||
|
|
||||||
(use-package! company-shell
|
(use-package! company-shell
|
||||||
|
Reference in New Issue
Block a user