 ;; (:map smartparens-strict-mode-map
 ;;       ("SPC" . comint-magic-space))
 
-(defun ar/term-mode-hook-function ()
-  "Called when entering term mode."
-  ;; Don't need trailing spaces highlighted in terminal.
-  (setq-local whitespace-style '(face empty tabs)))
-
-(add-hook 'term-mode-hook #'ar/term-mode-hook-function)
+(use-package term
+  :init
+  (defun ar/term-mode-hook-function ()
+    "Called when entering term mode."
+    ;; Don't need trailing spaces highlighted in terminal.
+    (setq-local whitespace-style '(face empty tabs)))
+  :hook (term-mode . ar/term-mode-hook-function))
 
 ;; From http://endlessparentheses.com/a-comment-or-uncomment-sexp-command.html
 (defun ar/uncomment-sexp (&optional n)

;;   (global-emojify-mode +1))

(use-package objc-mode
  :bind (:map objc-mode-map
              ([f6] . recompile)))


;;   :config
;;   (csetq alert-default-style 'osx-notifier))

(use-package cc-mode
  :init
  (defun ar/java-mode-hook-function ()
    "Called when entering `java-mode'."
    ;; 2-char indent for java.
    (defvar c-basic-offset)
    (validate-setq c-basic-offset 2)
    (set-fill-column 100))
  :hook (java-mode . ar/java-mode-hook-function))

(use-package immortal-scratch :ensure t
  :config
