   (define-key magit-section-mode-map (kbd "M-3") nil)
   (define-key magit-section-mode-map (kbd "M-4") nil)
   (define-key magit-section-mode-map (kbd "M-5") nil)
+  (define-key magit-section-mode-map (kbd "M-6") nil)
+  (define-key magit-section-mode-map (kbd "M-7") nil)
+  (define-key magit-section-mode-map (kbd "M-8") nil)
+  (define-key magit-section-mode-map (kbd "M-9") nil)
   (define-key magit-mode-map (kbd "M-w") nil)
   (define-key magit-mode-map (kbd "C-w") nil)
   (define-key magit-mode-map (kbd "C-c C-m") #'magit-toggle-margin)

  ("M-`"        #'previous-buffer)           ; window
  ("M-~"        #'next-buffer)               ; window
  ("M-w"        #'other-window)              ; window
  ("M-2"        #'me:window-2nd-buffer)
  ("M-3"        #'me:window-3rd-buffer)
  ("M-4"        #'me:window-4th-buffer)
  ("M-5"        #'me:window-5th-buffer)
  :init
  (add-function :after after-focus-change-function
                (lambda () (unless (frame-focus-state)

          (switch-to-buffer-other-window buffer)
        (switch-to-buffer buffer))))

  ;; Define M-2 to M-9 as selecting the nth buffer
  (dotimes (ind 8) ;; 0 to 7
    (let ((key (+ 2 ind)))
      (global-set-key (kbd (concat "M-" (format "%d" key)))
                      (lambda (&optional prefix)
                        (interactive "P")
                        (me:window-nth-buffer ind prefix)))))

  :demand)

