updat
This commit is contained in:
parent
55a91359ab
commit
d310899d4c
48
config.org
48
config.org
|
@ -328,26 +328,31 @@
|
||||||
:config (eglot-booster-mode))
|
:config (eglot-booster-mode))
|
||||||
|
|
||||||
(use-package php-mode
|
(use-package php-mode
|
||||||
:ensure t)
|
:ensure t
|
||||||
|
:mode ("\\.php\\'" . php-mode))
|
||||||
|
|
||||||
(use-package web-mode
|
(use-package web-mode
|
||||||
:ensure t
|
|
||||||
:mode
|
:mode
|
||||||
(("\\.phtml\\'" . web-mode)
|
(".twig$" ".html?$" ".hbs$" ".vue$" ".lade.php$")
|
||||||
("\\.php\\'" . web-mode)
|
|
||||||
("\\.tpl\\'" . web-mode)
|
|
||||||
("\\.[agj]sp\\'" . web-mode)
|
|
||||||
("\\.as[cp]x\\'" . web-mode)
|
|
||||||
("\\.erb\\'" . web-mode)
|
|
||||||
("\\.mustache\\'" . web-mode)
|
|
||||||
("\\.djhtml\\'" . web-mode))
|
|
||||||
:config
|
:config
|
||||||
(setq web-mode-markup-indent-offset 2
|
(setq
|
||||||
|
web-mode-markup-indent-offset 2
|
||||||
|
web-mode-css-indent-offset 2
|
||||||
web-mode-code-indent-offset 2
|
web-mode-code-indent-offset 2
|
||||||
web-mode-css-indent-offset 2)
|
web-mode-style-padding 2
|
||||||
web-mode-engines-alist
|
web-mode-script-padding 2
|
||||||
'(("php" . "\\.phtml\\'")
|
web-mode-enable-auto-closing t
|
||||||
("blade" . "\\.blade\\.")))
|
web-mode-enable-auto-opening t
|
||||||
|
web-mode-enable-auto-pairing t
|
||||||
|
web-mode-enable-auto-indentation t)
|
||||||
|
|
||||||
|
(dolist (alist web-mode-engines-auto-pairs)
|
||||||
|
(setcdr alist
|
||||||
|
(cl-loop for pair in (cdr alist)
|
||||||
|
unless (string-match-p "^[a-z-]" (cdr pair))
|
||||||
|
collect (cons (car pair)
|
||||||
|
(string-trim-right (cdr pair)
|
||||||
|
"\\(?:>\\|]\\|}\\)+\\'"))))))
|
||||||
|
|
||||||
(use-package eglot
|
(use-package eglot
|
||||||
:ensure nil
|
:ensure nil
|
||||||
|
@ -442,10 +447,10 @@
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package tree-sitter
|
(use-package tree-sitter
|
||||||
:ensure t
|
:ensure t
|
||||||
:hook
|
|
||||||
(prog-mode . tree-sitter-hl-mode)
|
|
||||||
:config
|
:config
|
||||||
(global-tree-sitter-mode))
|
(global-tree-sitter-mode)
|
||||||
|
;; Disable tree-sitter in web-mode
|
||||||
|
(add-hook 'web-mode-hook (lambda () (tree-sitter-mode -1))))
|
||||||
|
|
||||||
(use-package tree-sitter-langs
|
(use-package tree-sitter-langs
|
||||||
:ensure t)
|
:ensure t)
|
||||||
|
@ -707,3 +712,10 @@
|
||||||
|
|
||||||
(add-hook 'eglot-managed-mode-hook #'flymake-mode)
|
(add-hook 'eglot-managed-mode-hook #'flymake-mode)
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
** Olivetti
|
||||||
|
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package olivetti
|
||||||
|
:ensure t)
|
||||||
|
#+end_src
|
||||||
|
|
Loading…
Reference in a new issue