on master help sign in
Reintroduce win32yank as a clipboard provider on Linux for WSL2 + Windows 10 (#1912)

* feat(clipboard): reintroduce win32yank for wsl2 linux * refactor(clipboard): adjust win32yank position to not interrupt wayland/x11 Co-authored-by: jiqb <gthbji@ml1.net>

commita9635659f7d0dbbf2f11552842cf789ce1797914 authorجاد <LGUG2Z@users.noreply.github.com> dateThu 31 Mar 2022, 19:35 (5 years ago) parent6bb2298
1 file changed+5
helix-view/src/clipboard.rs+5
helix-view/src/clipboard.rs+5
@@ -104,6 +104,11 @@ pub fn get_clipboard_provider() -> Box<dyn ClipboardProvider> {
104104 primary_paste => "xsel", "-o";
105105 primary_copy => "xsel", "-i";
106106 }
107+ } else if exists("win32yank.exe") {
108+ command_provider! {
109+ paste => "win32yank.exe", "-o", "--lf";
110+ copy => "win32yank.exe", "-i", "--crlf";
111+ }
107112 } else if exists("termux-clipboard-set") && exists("termux-clipboard-get") {
108113 command_provider! {
109114 paste => "termux-clipboard-get";