diff options
author | Franck Cuny <franck@fcuny.net> | 2022-04-26 20:20:33 -0700 |
---|---|---|
committer | Franck Cuny <franck@fcuny.net> | 2022-04-26 20:20:33 -0700 |
commit | 7b1acb896133e24e4632724c9fd8806cba807600 (patch) | |
tree | 5ac9004682d84942560d1f7d23f8835b454c7791 /emacs | |
parent | edit: simplify (diff) | |
download | emacs.d-7b1acb896133e24e4632724c9fd8806cba807600.tar.gz |
conf: simplify
Diffstat (limited to '')
-rw-r--r-- | emacs/custom/my-conf.el | 53 | ||||
-rw-r--r-- | emacs/init.el | 23 |
2 files changed, 30 insertions, 46 deletions
diff --git a/emacs/custom/my-conf.el b/emacs/custom/my-conf.el index 55bc132..d91a409 100644 --- a/emacs/custom/my-conf.el +++ b/emacs/custom/my-conf.el @@ -6,51 +6,22 @@ ;;; Code: -(require 'use-package) +(add-to-list 'auto-mode-alist '("\\.yml\\'" . yaml-mode)) +(add-to-list 'auto-mode-alist '("\\.yaml\\'" . yaml-mode)) +(add-to-list 'auto-mode-alist '("Dockerfile\\'" . dockerfile-mode)) +(add-to-list 'auto-mode-alist '("\\.tf\\'" . terraform-mode)) -(use-package dockerfile-mode - :ensure t - :custom - (dockerfile-use-sudo t)) +(customize-set-variable 'dockerfile-use-sudo t) +(customize-set-variable 'dockerfile-use-buildkit t) -(use-package yaml-mode - :ensure t) +(customize-set-variable 'json-reformat:indent-width 2) +(customize-set-variable 'js-indent-level 2) +(customize-set-variable 'css-indent-offset 2) -(use-package js-mode - :custom - (json-reformat:indent-width 2) - (js-indent-level 2) - :hook ((json-mode . flyspell-prog-mode))) +(dolist (hook '(json-mode-hook protobuf-mode-hook systemd-mode-hook term-mode-hook)) + (add-hook hook 'flyspell-prog-mode)) -(use-package jq-format - :ensure t) - -(use-package protobuf-mode - :ensure t - :hook ((protobuf-mode . flyspell-prog-mode))) - -(use-package systemd - :ensure t - :hook ((systemd-mode . flyspell-prog-mode))) - -(use-package hcl-mode - :ensure t) - -(use-package terraform-mode - :ensure t - :mode (("\\.tf\\'" . terraform-mode)) - :hook (terraform-mode . terraform-format-on-save-mode)) - -(use-package terraform-doc - :ensure t) - -(use-package chef-mode - :ensure t) - -(use-package css-mode - :ensure nil - :init - (setq css-indent-offset 2)) +(add-hook 'terraform-mode-hook 'terraform-format-on-save-mode) (provide 'my-conf) ;;; my-conf.el ends here diff --git a/emacs/init.el b/emacs/init.el index 7fbc245..72ac44f 100644 --- a/emacs/init.el +++ b/emacs/init.el @@ -14,11 +14,24 @@ '("melpa" . "https://melpa.org/packages/")) -(defvar my/package-list - '(use-package - exec-path-from-shell - notmuch - markdown-mode) +(defvar my/package-list '(chef-mode + dockerfile-mode + eglot + exec-path-from-shell + go-mode + gotest + hcl-mode + jq-format + markdown-mode + nix-mode + notmuch + protobuf-mode + systemd + terraform-doc + terraform-mode + use-package + yaml-mode + yasnippet) "List of packages to be installed.") (defun my/packages-installed-p () |