Compare commits

..

No commits in common. "dc74b4bde0de5beb9eeaace46b4cc058410fbfd7" and "051e902d6459587b3f850edca5aa0e25060dadea" have entirely different histories.

13 changed files with 67 additions and 88 deletions

View File

@ -1,4 +1,4 @@
;;; init-company.el --- Autocompletado con company-mode -*- lexical-binding: t -*- ;;; base-company.el --- Autocompletado con company-mode -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -346,5 +346,5 @@
(Template . ,(all-the-icons-material "format_align_left" :height 1.0 :v-adjust -0.2))) (Template . ,(all-the-icons-material "format_align_left" :height 1.0 :v-adjust -0.2)))
company-box-icons-alist 'company-box-icons-all-the-icons)))) company-box-icons-alist 'company-box-icons-all-the-icons))))
(provide 'init-company) (provide 'base-company)
;;; init-company.el ends here ;;; base-company.el ends here

View File

@ -1,4 +1,4 @@
;;; init-ctags.el --- Configuracíón de TAGS -*- lexical-binding: t -*- ;;; base-ctags.el --- Configuracíón de TAGS -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -47,10 +47,8 @@
(defun lsp-citre-capf-function () (defun lsp-citre-capf-function ()
"A capf backend that tries lsp first, then Citre." "A capf backend that tries lsp first, then Citre."
(let ((lsp-result (if (fboundp #'eglot-completion-at-point) (let ((lsp-result (if (bound-and-true-p lsp-mode)
(eglot-completion-at-point) (lsp-completion-at-point))))
(when (fboundp #'lsp-completion-at-point)
(lsp-completion-at-point)))))
(if (and lsp-result (if (and lsp-result
(try-completion (try-completion
(buffer-substring (nth 0 lsp-result) (buffer-substring (nth 0 lsp-result)
@ -66,5 +64,5 @@
(add-hook 'citre-mode-hook #'enable-lsp-citre-capf-backend) (add-hook 'citre-mode-hook #'enable-lsp-citre-capf-backend)
)) ))
(provide 'init-ctags) (provide 'base-ctags)
;;; init-ctags.el ends here ;;; base-ctags.el ends here

View File

@ -1,4 +1,4 @@
;;; init-extensions.el --- Extensiones/paquetes instalados y su configuración -*- lexical-binding: t -*- ;;; base-extensions.el --- Extensiones/paquetes instalados y su configuración -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -26,8 +26,7 @@
(use-package dashboard (use-package dashboard
:defer t :defer t
:straight t :straight t
;; :hook (after-init . dashboard-setup-startup-hook) :hook (after-init . dashboard-setup-startup-hook)
:hook (after-init . org-agenda-list)
:config :config
(setq dashboard-set-file-icons t (setq dashboard-set-file-icons t
dashboard-set-heading-icons t dashboard-set-heading-icons t
@ -104,12 +103,12 @@
:hook :hook
(after-init . global-git-gutter-mode)) (after-init . global-git-gutter-mode))
;; (use-package gcmh (use-package gcmh
;; :defer t :defer t
;; :straight t :straight t
;; :init :init
;; (setq gcmh-high-cons-threshold 100000000) (setq gcmh-high-cons-threshold 100000000)
;; (gcmh-mode 1)) (gcmh-mode 1))
;; Highlight en los números. ;; Highlight en los números.
;; (use-package highlight-numbers ;; (use-package highlight-numbers
@ -350,5 +349,5 @@
:ensure t :ensure t
:straight t) :straight t)
(provide 'init-extensions) (provide 'base-extensions)
;;; init-extensions.el ends here ;;; base-extensions.el ends here

View File

@ -1,4 +1,4 @@
;;; init-functions.el --- Configuración de org-mode -*- lexical-binding: t -*- ;;; base-functions.el --- Configuración de org-mode -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -63,5 +63,5 @@ Saves to a temp file and puts the filename in the kill ring."
(or (featurep 'all-the-icons) (or (featurep 'all-the-icons)
(require 'all-the-icons nil t)))) (require 'all-the-icons nil t))))
(provide 'init-functions) (provide 'base-functions)
;;; init-functions.el ends here. ;;; base-functions.el ends here.

View File

@ -1,4 +1,4 @@
;;; init-ivy.el --- Ayuditas y autocompletado del minibufer -*- lexical-binding: t -*- ;;; base-ivy.el --- Ayuditas y autocompletado del minibufer -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -148,5 +148,5 @@
:straight t :straight t
:bind ("C-c C-y" . ivy-yasnippet)) :bind ("C-c C-y" . ivy-yasnippet))
(provide 'init-ivy) (provide 'base-ivy)
;;; init-ivy.el ends here ;;; base-ivy.el ends here

View File

@ -1,4 +1,4 @@
;;; init-keys.el --- Archivo de configuración de atajos -*- lexical-binding: t -*- ;;; base-keys.el --- Archivo de configuración de atajos -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -40,5 +40,5 @@
;; Deactivar el abrir *messages* al cliquear en el minibuffer ;; Deactivar el abrir *messages* al cliquear en el minibuffer
(define-key minibuffer-inactive-mode-map [mouse-1] #'ignore) (define-key minibuffer-inactive-mode-map [mouse-1] #'ignore)
(provide 'init-keys) (provide 'base-keys)
;;; init-keys.el ends here ;;; base-keys.el ends here

View File

@ -1,4 +1,4 @@
;;; init-lsp.el --- Languaje server protocol. -*- lexical-binding: t -*- ;;; base-lsp.el --- Languaje server protocol. -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -230,21 +230,6 @@
:straight t :straight t
:hook (java-mode . (lambda () (require 'lsp-java)))) :hook (java-mode . (lambda () (require 'lsp-java))))
;; `lsp-mode' and `treemacs' integration
(use-package lsp-treemacs
:defer t
:straight t
:after lsp-mode
:bind (:map lsp-mode-map
("C-<f8>" . lsp-treemacs-errors-list)
("M-<f8>" . lsp-treemacs-symbols)
("s-<f8>" . lsp-treemacs-java-deps-list))
:init (lsp-treemacs-sync-mode 1)
:config
(with-eval-after-load 'ace-window
(when (boundp 'aw-ignored-buffers)
(push 'lsp-treemacs-symbols-mode aw-ignored-buffers)
(push 'lsp-treemacs-java-deps-mode aw-ignored-buffers))))
(provide 'init-lsp) (provide 'base-lsp)
;;; init-lsp.el ends here ;;; base-lsp.el ends here

View File

@ -1,4 +1,4 @@
;;; init-config.el --- Configuración de org-mode -*- lexical-binding: t -*- ;;; base-config.el --- Configuración de org-mode -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -37,6 +37,7 @@
(use-package org (use-package org
:defer t :defer t
:ensure t
:straight (:type built-in) :straight (:type built-in)
:bind (("C-c a" . org-agenda) :bind (("C-c a" . org-agenda)
("C-c x" . org-capture)) ("C-c x" . org-capture))
@ -184,5 +185,5 @@
:ensure t :ensure t
:hook (org-mode . org-autolist-mode)) :hook (org-mode . org-autolist-mode))
(provide 'init-org) (provide 'base-org)
;;; init-org.el ends here ;;; base-org.el ends here

View File

@ -1,4 +1,4 @@
;;; init-treemacs.el --- Extensiones/paquetes instalados y su configuración -*- lexical-binding: t -*- ;;; base-treemacs.el --- Extensiones/paquetes instalados y su configuración -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -56,5 +56,21 @@
magit-post-unstage) magit-post-unstage)
. treemacs-magit--schedule-update)) . treemacs-magit--schedule-update))
(provide 'init-treemacs) ;; `lsp-mode' and `treemacs' integration
;;; init-treemacs.el ends here (use-package lsp-treemacs
:defer t
:straight t
:after lsp-mode
:bind (:map lsp-mode-map
("C-<f8>" . lsp-treemacs-errors-list)
("M-<f8>" . lsp-treemacs-symbols)
("s-<f8>" . lsp-treemacs-java-deps-list))
:init (lsp-treemacs-sync-mode 1)
:config
(with-eval-after-load 'ace-window
(when (boundp 'aw-ignored-buffers)
(push 'lsp-treemacs-symbols-mode aw-ignored-buffers)
(push 'lsp-treemacs-java-deps-mode aw-ignored-buffers))))
(provide 'base-treemacs)
;;; base-treemacs.el ends here

View File

@ -1,4 +1,4 @@
;;; init-base.el --- Configuración base de emacs -*- lexical-binding: t -*- ;;; base.el --- Configuración base de emacs -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net> ;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual ;; URL: https://git.kj2.me/kj/confi-emacs-actual
@ -145,5 +145,5 @@
(load custom-file) (load custom-file)
(provide 'init-base) (provide 'base)
;;; init-base.el ends here ;;; base.el ends here

View File

@ -1,18 +0,0 @@
;;; init-eglot.el --- Configuración de eglot (LSP) -*- lexical-binding: t -*-
;; Author: kj <webmaster@outcontrol.net>
;; URL: https://git.kj2.me/kj/confi-emacs-actual
;;; Commentary:
;;; Code:
(use-package eglot
:defer t
:straight (:type built-in)
:config
(add-to-list 'eglot-server-programs '(php-mode . ("intelephense" "--stdio")))
)
(provide 'init-eglot)
;;; init-eglot.el ends here

View File

@ -14,8 +14,7 @@
(local-set-key (kbd "C-c d b") 'php-doc-block) ;; atajo para docblock (local-set-key (kbd "C-c d b") 'php-doc-block) ;; atajo para docblock
(company-mode t) ; habilita company mode (company-mode t) ; habilita company mode
)) ))
(php-mode . eglot-ensure) ;;(php-mode . lsp)
;; (php-mode . lsp)
) )
) )

21
init.el
View File

@ -39,17 +39,16 @@
(add-to-list 'load-path (concat user-emacs-directory "configs")) (add-to-list 'load-path (concat user-emacs-directory "configs"))
;; Paquetes base ;; Paquetes base
(require 'init-base) (require 'base)
(require 'init-extensions) (require 'base-extensions)
(require 'init-functions) (require 'base-functions)
(require 'init-org) (require 'base-org)
;; (require 'init-lsp) (require 'base-lsp)
(require 'init-eglot) (require 'base-company)
(require 'init-company) (require 'base-treemacs)
(require 'init-treemacs) (require 'base-ctags)
;;(require 'init-ctags) (require 'base-ivy)
(require 'init-ivy) (require 'base-keys)
(require 'init-keys)
;; Lenguajes ;; Lenguajes
(require 'lang-php) (require 'lang-php)