       mouse-yank-at-point t)
 
 
-(use-package keyfreq)
-(keyfreq-mode 1)
-(setq keyfreq-file (emacs-d "cache/keyfreq"))
-(setq keyfreq-file-lock (emacs-d "cache/keyfreq.lock"))
-(defadvice keyfreq-mode (after always-autosave activate)
-  (keyfreq-autosave-mode 1))
-
-
-(use-package keyboard-cat-mode)
+(use-package keyfreq
+  :config
+  (keyfreq-mode 1)
+  (setq keyfreq-file (emacs-d "cache/keyfreq"))
+  (setq keyfreq-file-lock (emacs-d "cache/keyfreq.lock"))
+  (defadvice keyfreq-mode (after always-autosave activate)
+    (keyfreq-autosave-mode 1))
+  )
+
+
+(use-package keyboard-cat-mode
+  :commands (keyboard-cat-mode))
 
 (provide 'setup-editing)


;; automatically indent on return, except in a few modes that have similar stuff by default
;; automatically indent on return
(use-package electric)
(electric-indent-mode 1)
(defadvice electric-indent-post-self-insert-function (around keep-trailing-whitespace activate)
  (noflet ((delete-horizontal-space (&rest args) t))
    ad-do-it))

        (make-directory dir)))))

;; gist
(use-package gist
  :ensure t
  :commands (gist-list gist-buffer gist-region)
  :config
  (setq gist-view-gist t))

;; go to last change
;; http://www.emacswiki.org/emacs/GotoChg
(use-package goto-last-change
  :ensure t)
(global-set-key [f8] 'goto-last-change)

;; Some saner clipboard
