 ;; Put last selected bookmark on top
 (setq bookmark-sort-flag nil)
 (defvar bookmark-order-changed nil)
-(advice-add #'bookmark-save :after
-            #'(lambda () (setq bookmark-order-changed nil)))
+(advice-add #'bookmark-save :after (lambda () (setq bookmark-order-changed nil)))
 (defun bookmark-put-last-use-on-top ()
   (let ((last (bookmark-get-bookmark bookmark-current-bookmark)))
     (setq bookmark-alist (delq last bookmark-alist))


(declare-function magit-restore-window-configuration 'magit-mode)
;; kill buffer when I quit from magit
(setq magit-bury-buffer-function #'(lambda (_)
                                     (magit-restore-window-configuration t))
      magit-commit-show-diff nil)
(advice-add #'magit-status :after #'magit-status-init)
(add-hook 'git-commit-mode-hook #'git-commit-evil-maybe-start-insert)

;; real number for current line
;; relative number for the other line
(setq nlinum-relative-redisplay-delay 0.01)
(add-hook 'evil-emacs-state-entry-hook (lambda () (nlinum-mode 0)))
(add-hook 'evil-emacs-state-exit-hook (lambda () (nlinum-mode 1)))

(require 'save-visited-files)
(setq save-visited-files-location (locate-user-emacs-file ".visited-files")
