Something went wrong. Try again.
Library of 45+ independent Lua modules improving Neovim experience with minimal effort nvim-mini.org/mini.nvim
Something went wrong. Try again.
12345678910111213141516171819202122dofile('scripts/minimal_init.lua')
-- Enable reading correct shada filevim.o.shadafile = 'tests/dir-misc/restore-cursor.shada'
-- Set testable sizevim.o.lines = 10vim.o.columns = 20
-- Set up tested functionality based on test typelocal test_type = vim.env.RESTORE_CURSOR_TEST_TYPE
if test_type == 'set-not-normal-buftype' then vim.cmd('au BufReadPost * set buftype=help') endif test_type == 'set-position' then vim.cmd('au BufReadPost * call cursor(4, 0)') endif test_type == 'make-folds' then vim.cmd('au BufReadPost * 2,3 fold | 9,10 fold') end
local opts = {}if test_type == 'not-center' then opts = { center = false } endif test_type == 'ignore-lua' then opts = { ignore_filetype = { 'lua' } } end
require('mini.misc').setup_restore_cursor(opts)