aboutsummaryrefslogtreecommitdiff
path: root/.dir-locals.el
blob: 5606ae881bf4d24b5b59e9ea6a1f4003420f1224 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
;; This files contains Emacs Directory Local Variables.
;;
;; Emacs is an extensible, customizable, free/libre text editor.  It
;; allows specification of certain settings that will be applied to
;; all files in current directory and its subdirectories. This is
;; useful in order to automatically enforce certain coding conventions
;; for all contributors of Gnuastro, like the maximum length of lines
;; or the number of spaces to be used for indentation.
;;
;; For more information see (info "(emacs) Directory Variables")

;; Open `.mk' files in Makefile mode
(add-to-list 'auto-mode-alist '("\\.mk$" . makefile-mode))

;; Basic settings.
((nil
  (indent-tabs-mode . nil) ;; No tabs as indentation
  (fill-column . 75))      ;; 75-character wide lines
 (c-mode
  (c-basic-offset . 2)     ;; 2 spaces of indentation
  (c-file-style . "gnu"))  ;; GNU style for braces
 (makefile-mode
  (indent-tabs-mode . t))  ;; Real TABs are important in makefiles
 )