You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I made a tiny plugin to handle this for myself, but it would be something that would fit inside this project and probably be implemented better:
I use ⌘E to kill the current line. Wherever my cursor is, the entire line is deleted. If I have a selection that spans multiple lines, they're all deleted.
Most importantly, this command does not need you to highlight exactly the whole line or entire text you want to be deleted, just wherever your cursor is, whatever you have highlighted, or wherever your multiple cursors are, each line involved is deleted
This is what I did, there is probably a better way to do it:
nova.commands.register("example.delete-lines",(editor)=>{editor.selectLinesContainingCursors();editor.edit((actionQueue)=>{// When multiple cursors are involved, ranges must be deleted bottom-up// so it can be performed as one atomic commiteditor.selectedRanges.reverse().forEach((range)=>{actionQueue.delete(range);});});});
The text was updated successfully, but these errors were encountered:
I made a tiny plugin to handle this for myself, but it would be something that would fit inside this project and probably be implemented better:
I use ⌘E to kill the current line. Wherever my cursor is, the entire line is deleted. If I have a selection that spans multiple lines, they're all deleted.
Most importantly, this command does not need you to highlight exactly the whole line or entire text you want to be deleted, just wherever your cursor is, whatever you have highlighted, or wherever your multiple cursors are, each line involved is deleted
This is what I did, there is probably a better way to do it:
The text was updated successfully, but these errors were encountered: