Skip to content

Instantly share code, notes, and snippets.

@mattdkerr
Created March 7, 2025 16:00
Show Gist options
  • Save mattdkerr/64a07ed454c3e39d20b100be4c68723a to your computer and use it in GitHub Desktop.
Save mattdkerr/64a07ed454c3e39d20b100be4c68723a to your computer and use it in GitHub Desktop.
WSL2 - fix nvim clipboard in ~/.cargo/nvim/init.zsh
let g:clipboard = {
'name': 'WslClipboard',
'copy': {
'+': 'clip.exe',
'*': 'clip.exe',
},
'paste': {
'+': 'powershell.exe -c [Console]::Out.Write($(Get-Clipboard -Raw).tostring().replace("`r", ""))',
'*': 'powershell.exe -c [Console]::Out.Write($(Get-Clipboard -Raw).tostring().replace("`r", ""))',
},
'cache_enabled': 0,
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment