This commit is contained in:
Mars 2024-11-12 22:36:49 -05:00
parent 55a91359ab
commit d310899d4c
Signed by: pupbrained
GPG key ID: 0FF5B8826803F895

View file

@ -328,26 +328,31 @@
:config (eglot-booster-mode))
(use-package php-mode
:ensure t)
:ensure t
:mode ("\\.php\\'" . php-mode))
(use-package web-mode
:ensure t
:mode
(("\\.phtml\\'" . web-mode)
("\\.php\\'" . web-mode)
("\\.tpl\\'" . web-mode)
("\\.[agj]sp\\'" . web-mode)
("\\.as[cp]x\\'" . web-mode)
("\\.erb\\'" . web-mode)
("\\.mustache\\'" . web-mode)
("\\.djhtml\\'" . web-mode))
(".twig$" ".html?$" ".hbs$" ".vue$" ".lade.php$")
: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-css-indent-offset 2)
web-mode-engines-alist
'(("php" . "\\.phtml\\'")
("blade" . "\\.blade\\.")))
web-mode-style-padding 2
web-mode-script-padding 2
web-mode-enable-auto-closing t
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
:ensure nil
@ -442,10 +447,10 @@
#+begin_src emacs-lisp
(use-package tree-sitter
:ensure t
:hook
(prog-mode . tree-sitter-hl-mode)
: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
:ensure t)
@ -707,3 +712,10 @@
(add-hook 'eglot-managed-mode-hook #'flymake-mode)
#+end_src
** Olivetti
#+begin_src emacs-lisp
(use-package olivetti
:ensure t)
#+end_src