-;; Time-stamp: <2015-02-23 11:42:32 kmodi>
+;; Time-stamp: <2015-03-11 13:06:55 kmodi>
 
 ;; IRegister (Interactive Register)
 ;; https://github.com/atykhonov/iregister.el

(defalias 'my/iregister-delete-append  'iregister-append-to-latest-register-delete)

(use-package iregister
  :config
  (progn

    (defun my/iregister-copy-append-sep (start end &optional separator)

      (if (region-active-p)
          (let ((selection (buffer-substring-no-properties start end)))
            (if iregister-last-used-register
                (progn
                  (with-temp-buffer
                    (if (string-match "\\n" separator)
                        (newline)
                      (insert separator))
                    (insert selection)
                    (append-to-register iregister-last-used-register
                                        (point-min) (point-max)))
                  (delete-region start end))
              (message "No registers has been used within iregister.el."))
            (deactivate-mark))
        (message "!Region is not active.")))
