From cf759ec06dea631fecc8407dd314b3d07d773564 Mon Sep 17 00:00:00 2001 From: Nicolas Petton Date: Sat, 2 Mar 2019 23:32:00 +0100 Subject: [PATCH] Fix #199 * indium-chrome.el (indium-chrome--command): Reuse the Chrome profile directory between sessions. --- indium-chrome.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/indium-chrome.el b/indium-chrome.el index 7f4b11c..6ae22c1 100644 --- a/indium-chrome.el +++ b/indium-chrome.el @@ -60,6 +60,9 @@ "When non-nil, each invocation of the browser uses a new temporary profile." :type '(boolean)) +(defvar indium-chrome-data-dir (make-temp-file nil t) + "Chrome profile directory used by Indium.") + (defun indium-launch-chrome (conf) "Start chrome/chromium with remote debugging enabled based on CONF settings." (let-alist conf @@ -76,7 +79,7 @@ (list (indium-chrome--find-executable) (format "--remote-debugging-port=%s" port) (if indium-chrome-use-temporary-profile - (format "--user-data-dir=%s" (make-temp-file nil t)) + (format "--user-data-dir=%s" indium-chrome-data-dir) "") url))