 (defvar-local intero-repl-last-loaded
   nil
   "The last loaded thing with `intero-repl-load`.")
+
+(defvar-local intero-buffer-host nil
+  "The hostname of the box hosting the intero process for the current buffer.")
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;; Interactive commands

	      (if (eq 0 (string-match tramp-file-name-regexp file))
		  (tramp-file-name-host (tramp-dissect-file-name file))
		"")))))))
	
(defun intero-extend-path-by-buffer-host (path &optional buffer)
  "Take a path, and extend it by the host of the provided buffer (default to current buffer). Return path unchanged if the file is local, or the buffer has no host."
  (with-current-buffer (or buffer (current-buffer))

    (when name
      (intero-canonicalize-path (substring-no-properties name)))))

(defun intero-buffer-host (&optional buffer)
  "Get the hostname of the box hosting the file behind the buffer."
  (with-current-buffer (or buffer (current-buffer))
