From a187752c824b47052d33d3bc12749b5a7d2e8191 Mon Sep 17 00:00:00 2001 From: Franck Cuny Date: Thu, 1 Jun 2023 19:35:59 -0700 Subject: 🤡 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I06b104d79deac199f9cd9cdae705e333d23cc852 --- emacs/custom/my-prog.el | 63 ------------------------------------------------- 1 file changed, 63 deletions(-) delete mode 100644 emacs/custom/my-prog.el (limited to 'emacs/custom/my-prog.el') diff --git a/emacs/custom/my-prog.el b/emacs/custom/my-prog.el deleted file mode 100644 index 8314ab9..0000000 --- a/emacs/custom/my-prog.el +++ /dev/null @@ -1,63 +0,0 @@ -;;; my-prog.el --- Configures emacs for various programming languages -*- lexical-binding: t -*- - -;;; Commentary: - -;;; Code: -(customize-set-variable 'Man-notify-method 'aggressive) -(customize-set-variable 'Man-fontify-manpage-flag t) - -;; turn on `electric-pair-mode' on `prog-mode' and `conf-mode-hook' -(dolist (hook '(prog-mode-hook conf-mode-hook)) - (add-hook hook 'electric-pair-mode)) - -;; Skip over warnings and info messages in compilation -(customize-set-variable 'compilation-skip-threshold 2) -;; Don't freeze when process reads from stdin -(customize-set-variable 'compilation-disable-input t) -;; Show three lines of context around the current message -(customize-set-variable 'compilation-context-lines 3) -;; Jump to first error -(customize-set-variable 'compilation-scroll-output 'first-error) - -;; yasnippet is required to support place holders with eglot -(dolist (hook '(prog-mode-hook conf-mode-hook org-mode-hook)) - (add-hook hook 'yas-minor-mode)) - -;; where to wrap comments -(require 'newcomment) -(setq comment-fill-column 120) -(setq comment-auto-fill-only-comments t) - -(dolist (hook '(prog-mode-hook conf-mode-hook)) - (add-hook hook 'auto-fill-mode)) - -(defun my/sh-mode-hook () - "Hooks for `sh-mode'." - ;; shell scripts are made executable - (add-hook 'after-save-hook 'executable-make-buffer-file-executable-if-script-p) - (customize-set-variable 'sh-indentation 2) - (customize-set-variable 'sh-basic-offset 2)) - -(add-hook 'sh-mode-hook 'my/sh-mode-hook) - -(defun my/makefile-mode-hook () - "Hooks for `makefile-mode'." - ;; I want small tabs when working in a Makefile - (setq tab-width 2)) - -(add-hook 'makefile-mode-hook 'my/makefile-mode-hook) - -(defun my/elisp-mode-hook () - "Hooks for `elisp-mode'." - (define-key emacs-lisp-mode-map (kbd "C-c C-e") 'eval-buffer) - (define-key emacs-lisp-mode-map (kbd "C-c C-r") 'eval-region)) - -(add-hook 'emacs-lisp-mode-hook 'my/elisp-mode-hook) - -(define-key prog-mode-map (kbd "C-c C-h") 'eldoc) -(dolist (hook '(prog-mode-hook conf-mode-hook)) - (add-hook hook 'turn-on-eldoc-mode)) - -(provide 'my-prog) - -;;; my-prog.el ends here -- cgit 1.4.1