     (evil-define-key 'visual python-mode-map
       "\C-c\C-c" 'python-shell-send-region)
     (evil-leader/set-key-for-mode 'python-mode
-      "'" 'python-shell-switch-to-shell)))
+      "'" 'python-shell-switch-to-shell)
+
+    (add-hook 'python-mode-hook
+              '(lambda ()
+                 (local-set-key (kbd "<C-return>") 'python-shell-send-defun)))))
 
 ;;; completion
 (use-package company-jedi

(add-hook 'text-mode-hook 'turn-on-auto-fill)

;;; disable splash screen and minibuffer messages on startup
(setq inhibit-splash-screen t)
(setq inhibit-startup-echo-area-message t)

(setq ring-bell-function 'ignore)

(setq major-mode 'text-mode)

;;; backup directory
(setq backup-directory-alist `(("." . "~/.emacs-backup"))

    (defun my/python-mode-hook ()
      (add-to-list 'company-backends 'company-jedi))
    (add-hook 'python-mode-hook 'my/python-mode-hook)))

;;;-----------------------------------------------------------------------------
;;; clojure
(use-package clojure-mode
  :ensure t
  :mode (("\\.clj" . clojure-mode)
         ("\\.cljs" . clojurescript-mode))
  :config
  (progn
    (evil-leader/set-key-for-mode 'clojure-mode
      "'" 'cider-switch-to-repl-buffer)
    (evil-leader/set-key-for-mode 'clojurescript-mode
      "'" 'cider-switch-to-repl-buffer)
    (push '("\*.*cider-repl.*\*" :regexp t :noselect t) popwin:special-display-config)))

;;; completion
(use-package cider
  :ensure t
  :commands cider-jack-in)

;;;============================================================================
;;; Additional packages
