diff options
author | Erlend <erlendf80@gmail.com> | 2023-11-15 16:32:47 +0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-15 16:32:47 +0700 |
commit | f86c584fc2d4a2bab47df0cd5d187dd81fb71856 (patch) | |
tree | b98a59f078eb48aebdd03b60522e93e969d1eca0 | |
parent | c19a2ceb71607aea6c34491fa325a1de2da8dfaf (diff) | |
parent | e8d1ccef3d03779e35cfd64d73e968b2d0de39bd (diff) | |
download | vis-cursors-master.tar.gz |
ignore files with cursor at the beginning; simplify cursor saving
-rw-r--r-- | init.lua | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -80,6 +80,12 @@ local on_win_close = function(win) end end + -- ignore files with cursor at the beginning + if win.selection.pos == 0 then + return + end + + -- insert current path to top of files table.insert(files, 1, win.file.path) |