From 2bf2867a5095fa88cbe4c22ba39ad87c04b8b393 Mon Sep 17 00:00:00 2001 From: mitchell <70453897+orbitalquark@users.noreply.github.com> Date: Tue, 15 Dec 2020 12:20:55 -0500 Subject: Save the current session prior to loading another one. --- modules/textadept/session.lua | 1 + 1 file changed, 1 insertion(+) (limited to 'modules') diff --git a/modules/textadept/session.lua b/modules/textadept/session.lua index 55a33be8..efadb243 100644 --- a/modules/textadept/session.lua +++ b/modules/textadept/session.lua @@ -52,6 +52,7 @@ function M.load(filename) } if not filename then return end end + if session_file ~= filename then M.save(session_file) end local f = loadfile(filename, 't', {}) if not f or not io.close_all_buffers() then return end -- fail silently local session = f() -- cgit v1.2.3