               (remove-hook hook #'nlinum-mode))
             (global-nlinum-mode 1))
         (progn
-          (global-nlinum-mode -1)
+          (when global-linum-mode
+            (global-nlinum-mode -1))
           (dolist (hook modi/linum-mode-hooks)
             (add-hook hook #'nlinum-mode)))))
 

(use-package linum
  :config
  (progn
    (global-linum-mode -1)

    (defun modi/blend-linum ()
      "Set the linum foreground and background color to that of the theme."
      (interactive)
      (set-face-attribute
       'linum nil


;; linum relative
(use-package linum-relative
  :config
  (progn
    ;; The symbol you want to show on the current line, by default it is 0.
    ;; You can use any string like \"->\". If this variable is empty string,
