     (remove-hook 'post-command-hook 'floobits-post-command-func))
 
   (remove-hook 'after-save-hook 'floobits-after-save-hook)
-  ; (remove-hook 'minibuffer-exit-hook 'floobits-minibuffer-hook)
   (ad-disable-advice 'delete-file 'before 'floobits-delete-file)
   (ad-disable-advice 'rename-file 'before 'floobits-rename-file))
 

  (when (_floobits-is-buffer-shared (current-buffer))
    (floobits-send-to-agent (list (cons 'path (buffer-file-name))) 'saved)))

; (defun floobits-minibuffer-hook ()
;   (when floobits-jump-list
;     (run-at-time 0.1 nil (lambda (path pos) (switch-to-buffer path) (goto-char pos)) 
;       (car floobits-jump-list) (cadr floobits-jump-list))
;     (setq floobits-jump-list nil)))

(defun floobits-get-text-for-path (p)
  (cons (intern p) (floobits-get-buffer-text (find-buffer-visiting p))))


      (add-hook 'buffer-list-update-hook 'floobits-buffer-list-change nil nil))
    (add-hook 'post-command-hook 'floobits-post-command-func nil nil))
  (add-hook 'after-save-hook 'floobits-after-save-hook nil nil)
  ; (add-hook 'buffer-list-update-hook 'floobits-buffer-list-change nil nil)
  (ad-enable-advice 'delete-file 'before 'floobits-delete-file)
  (ad-enable-advice 'rename-file 'before 'floobits-rename-file)
  (ad-activate 'delete-file)
