-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using win32yank on WSL prints extra line on stdout #3
Comments
There are a couple of similar issues around in github microsoft/WSL#2011 Likely some code is trying to figure out its current directory and having issues with the unexpected path and/or environment vars. I wonder if setting $CD to a valid path works around it? |
No, setting I was trying to make a shell script that changes folder to a Windows folder and then calls win32yank.exe, but I don't have much luck: the -o option pastes twice for example. |
@gglanzani trying to reproduce this on Windows, but I do not get that message with any of the following
I just updated windows so that might be the cause winver.exe reports OS build 15063.250 |
It seems this only happens when using a symlink to the actual binary, like the example in the neovim wiki. |
Installing Xming for Windows, and then making sure to run |
It's not a symlink issue and there's no straight-forward fix for this - it's an error generated by the WSL subsystem when cwd is inside the lxsys filesystem which isn't accessible from win32. The fix is to call win32yank.exe via a Linux-side program/script which will filter that. Here's my solution:
|
Calling win32yank on WSL prints to stdout (before the clipboard is printed) the following line
The tool is basically working when calling it from neovim inside Windows Subsystem from Linux. However that line gets printed everywhere, which is annoying :)
I've looked at the code, but there were no mentions of this so maybe it's rust doing this
The text was updated successfully, but these errors were encountered: