mirror of
https://github.com/neovim/neovim.git
synced 2026-05-04 04:55:16 +00:00
feat(terminal)!: include cursor position in TermRequest event data (#31609)
When a plugin registers a TermRequest handler there is currently no way for the handler to know where the terminal's cursor position was when the sequence was received. This is often useful information, e.g. for OSC 133 sequences which are used to annotate shell prompts. Modify the event data for the TermRequest autocommand to be a table instead of just a string. The "sequence" field of the table contains the sequence string and the "cursor" field contains the cursor position when the sequence was received. To maintain consistency between TermRequest and TermResponse (and to future proof the latter), TermResponse's event data is also updated to be a table with a "sequence" field. BREAKING CHANGE: event data for TermRequest and TermResponse is now a table
This commit is contained in:
@@ -10,7 +10,7 @@ local Screen = require('test.functional.ui.screen')
|
||||
|
||||
describe('default', function()
|
||||
describe('autocommands', function()
|
||||
it('nvim_terminal.TermClose closes terminal with default shell on success', function()
|
||||
it('nvim.terminal.TermClose closes terminal with default shell on success', function()
|
||||
n.clear()
|
||||
n.api.nvim_set_option_value('shell', n.testprg('shell-test'), {})
|
||||
n.command('set shellcmdflag=EXIT shellredir= shellpipe= shellquote= shellxquote=')
|
||||
|
||||
Reference in New Issue
Block a user