While working through Section 5.8, "Lab: Create, View, and Edit Text Files", I noticed that the keyboard shortcut to enter Visual Block mode (Ctrl+V), does not work as expected. It pastes whatever is stored in the clipboard.
The "v" and "Shift+V" commands work as expected.
I am using a Windows 11 system, with Firefox 124.0.1.
If you're using a web-based interface for Vim and can't switch to a local or SSH-based environment, you might be able to change the key bindings or settings within your browser or web-based terminal to prevent Ctrl+V from pasting.
This approach depends heavily on the specific application or service you're using and might not always be feasible.
To utilize all Vim shortcuts without interference, consider using Vim in a different context where it has full control over keyboard input:
Local Terminal: Running Vim in a local terminal emulator that supports custom keybindings or Vim-specific modes can help. Terminal applications like ConEmu, Alacritty, or Windows Terminal allow for more granular control over shortcuts.
SSH into a Linux VM or Server: If you're connecting to a Linux system via SSH using PuTTY or another SSH client, Ctrl+V should work as expected in Vim, as these clients usually pass keyboard input directly to the remote shell.
If you are on Windows 11 and are facing this issue in a browser, consider using the Windows Subsystem for Linux (WSL) with Windows Terminal. This setup provides a more native Unix-like environment where Vim (and its keyboard shortcuts) should work as expected. Windows Terminal allows for custom keybindings, so you can ensure Ctrl+V behaves correctly in the context of Vim.
________________________________________________
After you’ve selected the block of text you want to copy:
To paste the text you've just copied:
If you're using a web-based interface for Vim and can't switch to a local or SSH-based environment, you might be able to change the key bindings or settings within your browser or web-based terminal to prevent Ctrl+V from pasting.
This approach depends heavily on the specific application or service you're using and might not always be feasible.
To utilize all Vim shortcuts without interference, consider using Vim in a different context where it has full control over keyboard input:
Local Terminal: Running Vim in a local terminal emulator that supports custom keybindings or Vim-specific modes can help. Terminal applications like ConEmu, Alacritty, or Windows Terminal allow for more granular control over shortcuts.
SSH into a Linux VM or Server: If you're connecting to a Linux system via SSH using PuTTY or another SSH client, Ctrl+V should work as expected in Vim, as these clients usually pass keyboard input directly to the remote shell.
If you are on Windows 11 and are facing this issue in a browser, consider using the Windows Subsystem for Linux (WSL) with Windows Terminal. This setup provides a more native Unix-like environment where Vim (and its keyboard shortcuts) should work as expected. Windows Terminal allows for custom keybindings, so you can ensure Ctrl+V behaves correctly in the context of Vim.
________________________________________________
After you’ve selected the block of text you want to copy:
To paste the text you've just copied:
Thanks for your reply. I am in fact doing most of my training on a Windows port of Vim. But in order to complete the labs and have them graded, I have to use the JupyterLab, or am I missing something here?
Anyway, I have just found that JupyterLab has an extensive range of keyboard shortcuts, and that they are configurable. So I will probably find a way around Ctrl+V pasting text instead of entering Visual Block mode.
Since a lot of course contents are about editing yaml files and yaml files strongly depend on correct indentation, a way to access the vim visual mode in JupyterLab to indent blocks would be really required.
Red Hat
Learning Community
A collaborative learning environment, enabling open source skill development.