 
 (global-set-key (kbd "C-w") (lambda ()
                               (interactive)
-                              (if mark-active
-                                  (kill-region (point) (mark))
+                              (if (use-region-p)
+                                  (call-interactively 'kill-region)
                                 (crux-kill-whole-line))))
 
 (global-set-key (kbd "C-a") 'crux-move-beginning-of-line)


(setq whitespace-line-column 90
      whitespace-style '(face trailing newline))

(global-set-key (kbd "M-\\") 'shrink-whitespace)


(key-chord-define-global "jj" 'avy-goto-word-or-subword-1)
(key-chord-define-global "jl" 'avy-goto-line)
(key-chord-define-global "jk" 'avy-goto-char-timer)
(key-chord-define-global "JJ" 'crux-switch-to-previous-buffer)
(key-chord-mode +1)

;; (require 'jump-char)
