1
0
Fork 0

Add hooks for company and indendation, some correct stuff

This commit is contained in:
CRy386i 2024-12-17 23:31:21 +02:00
parent 601243da71
commit 214a38c447

25
init.el
View file

@ -80,7 +80,8 @@
("C-q" . mark-word) ("C-q" . mark-word)
("C-x w" . downcase-word) ("C-x w" . downcase-word)
("C-," . shrink-window-horizontally) ("C-," . shrink-window-horizontally)
("C-." . enlarge-window-horizontally))) ("C-." . enlarge-window-horizontally)
("C-c M-c" . uncomment-region)))
;; example configuration for Consult ;; example configuration for Consult
(use-package consult (use-package consult
@ -274,13 +275,23 @@
orderless-style-dispatchers (list #'+orderless-consult-dispatch orderless-style-dispatchers (list #'+orderless-consult-dispatch
#'orderless-affix-dispatch))) #'orderless-affix-dispatch)))
(use-package glsl-mode
:ensure t)
(use-package company-glsl
:ensure t)
(use-package company (use-package company
:ensure t :ensure t
:init (global-company-mode) :init (global-company-mode)
:hook (c-mode . company-mode) :hook
((c-mode . company-mode)
(glsl-mode . company-mode)
(d-mode . company-mode))
:custom :custom
(company-idle-delay 0.01)) (company-idle-delay 0.01))
(use-package flycheck (use-package flycheck
:ensure t :ensure t
:init (global-flycheck-mode)) :init (global-flycheck-mode))
@ -316,24 +327,28 @@
(use-package json-mode (use-package json-mode
:custom (js-indent-line 4)) :custom (js-indent-line 4))
(setq default-tab-width 4)
(custom-set-variables (custom-set-variables
;; custom-set-variables was added by Custom. ;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful. ;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance. ;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right. ;; If there is more than one, they won't work right.
'(c-basic-offset 4)
'(custom-buffer-indent 4)
'(custom-enabled-themes '(gruvbox-dark-medium)) '(custom-enabled-themes '(gruvbox-dark-medium))
'(custom-safe-themes '(custom-safe-themes
'("046a2b81d13afddae309930ef85d458c4f5d278a69448e5a5261a5c78598e012" "d445c7b530713eac282ecdeea07a8fa59692c83045bf84dd112dd738c7bcad1d" "ba323a013c25b355eb9a0550541573d535831c557674c8d59b9ac6aa720c21d3" "871b064b53235facde040f6bdfa28d03d9f4b966d8ce28fb1725313731a2bcc8" "7b8f5bbdc7c316ee62f271acf6bcd0e0b8a272fdffe908f8c920b0ba34871d98" default)) '("046a2b81d13afddae309930ef85d458c4f5d278a69448e5a5261a5c78598e012" "d445c7b530713eac282ecdeea07a8fa59692c83045bf84dd112dd738c7bcad1d" "ba323a013c25b355eb9a0550541573d535831c557674c8d59b9ac6aa720c21d3" "871b064b53235facde040f6bdfa28d03d9f4b966d8ce28fb1725313731a2bcc8" "7b8f5bbdc7c316ee62f271acf6bcd0e0b8a272fdffe908f8c920b0ba34871d98" default))
'(display-line-numbers t) '(display-line-numbers t)
'(flycheck-c/c++-gcc-executable "x86_64-w64-mingw32-gcc-14") '(global-flycheck-mode t)
'(flycheck-gcc-args '("-Wall" "-mwindows" "-municode"))
'(indent-tabs-mode nil) '(indent-tabs-mode nil)
'(inhibit-startup-screen t) '(inhibit-startup-screen t)
'(menu-bar-mode nil) '(menu-bar-mode nil)
'(package-selected-packages '(package-selected-packages
'(multiple-cursors markdown-mode d-mode flycheck tree-sitter-langs tree-sitter company consult orderless vertico gruvbox-theme)) '(company-glsl glsl-mode multiple-cursors markdown-mode d-mode flycheck tree-sitter-langs tree-sitter company consult orderless vertico gruvbox-theme))
'(recentf-mode t) '(recentf-mode t)
'(tab-bar-mode t) '(tab-bar-mode t)
'(tab-stop-list nil)
'(tab-width 4) '(tab-width 4)
'(tool-bar-mode nil) '(tool-bar-mode nil)
'(xref-show-definitions-function 'consult-xref)) '(xref-show-definitions-function 'consult-xref))