<commit_before>(setq c-default-style "linux")
(setq c-basic-offset 4)

(defun mjhoy/c-init ()
  (setq c-basic-offset 4)
  (if (or (file-exists-p "makefile")
          (file-exists-p "Makefile"))
      (set (make-local-variable 'compilation-read-command) nil)))

(defun mjhoy/my-c-initialization ()
  (define-key c-mode-base-map (kbd "C-m") 'c-context-line-break)
  (define-key c-mode-base-map (kbd "C-c C-c") 'compile))

(add-hook 'c-initialization-hook 'mjhoy/my-c-initialization)
(add-hook 'c-mode-hook 'mjhoy/c-init)

(provide 'init-c)<commit_msg>emacs: c: use flycheck-mode on init<commit_after>(mjhoy/require-package 'flycheck)

(setq c-default-style "linux")
(setq c-basic-offset 4)

(defun mjhoy/c-init ()
  "My setup for c files."
  (setq c-basic-offset 4)
  (flycheck-mode 1)
  (if (or (file-exists-p "makefile")
          (file-exists-p "Makefile"))
      (set (make-local-variable 'compilation-read-command) nil)))

(defun mjhoy/my-c-initialization ()
  (define-key c-mode-base-map (kbd "C-m") 'c-context-line-break)
  (define-key c-mode-base-map (kbd "C-c C-c") 'compile))

(add-hook 'c-initialization-hook 'mjhoy/my-c-initialization)
(add-hook 'c-mode-hook 'mjhoy/c-init)

(provide 'init-c)
{'fraction_non_alphanumeric': 0.18786367414796343, 'fraction_numerical': 0.004156275976724855, 'mean_word_length': 3.684824902723735, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6113994', 'n_tokens_mistral': 518, 'n_tokens_neox': 500, 'n_words': 97}