      (message "Copied line")
      (list (line-beginning-position) (line-end-position)))))
 
+(defun ar/duplicate-line ()
+  "Duplicate current line and paste below."
+  (interactive)
+  (let ((line-text (buffer-substring (line-beginning-position)
+                                     (line-end-position))))
+    (end-of-line)
+    (newline)
+    (insert line-text)))
+
+(bind-key "C-x C-d" #'ar/duplicate-line)
+
 (use-package hungry-delete
   :defer 5
   :ensure t

  :bind ("C-x k" . kill-this-buffer))
;;;; Buffers END

(use-package ar-mu4e
  :if (locate-library "ar-mu4e")
  :bind (:map global-map

(use-package expand-region
  :ensure t
  :bind ("C-c w" . er/expand-region))

(defun ar/yank-line-below ()
  "Yank to line below."
  (interactive)
  (save-excursion
    (move-end-of-line nil)
    (newline)
    (yank))
  (next-line))

(bind-key "M-C-y" #'ar/yank-line-below)

(use-package whitespace
  :defer 5
