 (use-package evil-snipe
   :diminish evil-snipe-mode
   :init
-  (define-key evil-normal-state-map "s" nil)
-  (define-key evil-normal-state-map "S" nil)
   (setq-default
    evil-snipe-smart-case t
-   evil-snipe-repeat-keys nil ;; using evil-space for repeating
+   evil-snipe-repeat-keys nil ; using evil-space to repeat
    evil-snipe-scope 'line
    evil-snipe-repeat-scope 'buffer
-   evil-snipe-override-evil-repeat-keys nil
+   evil-snipe-override-evil-repeat-keys nil ; causes problems with remapped ;
    evil-snipe-symbol-groups '((?\[ "[[{(]")
                               (?\] "[]})]")))
   :config


  (bind! :map evil-command-window-mode-map :n [escape] 'kill-buffer-and-window)

  (defadvice evil-ex-hl-do-update-highlight (around evil-ex-hl-shut-up activate)
    "Silence 'Error running timer `evil-ex-hl-do-update-highlight': (error
\"Invalid use of `\\' in replacement text\") errors.

See https://bitbucket.org/lyro/evil/issue/527"
    (ignore-errors ad-do-it))

  ;; modes to map to different default states
  (dolist (mode-map '((cider-repl-mode   . emacs)
                      (comint-mode       . emacs)
                      (term-mode         . emacs)
                      (fundamental-mode  . motion)
                      (help-mode         . normal)
                      (message-mode      . normal)
                      (compilation-mode  . normal)
                      (text-mode         . normal)))
    (evil-set-initial-state `,(car mode-map) `,(cdr mode-map)))

  (progn ; evil hacks

  :functions (iedit-current-occurrence-string iedit-restrict-region)
  :commands (evil-iedit-state evil-iedit-state/iedit-mode)
  :config
  (bind!
   :v "SPC" 'narf:iedit-restrict-to-region
   (:map evil-iedit-state-map ; Don't interfere with evil-snipe
     "s"   nil
     "S"   nil
     "V"   'evil-visual-line
     "C"   'evil-iedit-state/substitute  ; instead of s/S
     "za"  'iedit-toggle-unmatched-lines-visible)))

(use-package evil-indent-textobject
  :commands (evil-indent-i-indent
