-
Notifications
You must be signed in to change notification settings - Fork 52
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
WSL not supported? #111
Comments
I got the same problem under Reading of "config.json" and clipboard seems to be working well, but an error occurs when attempting to read the root directory of VSCode installed under Windows system. (For me it is I only modified Hope to get your reply! |
I did not solve the problem yet.For now i just open another vscode in Windows to write markdown. |
Thanks for your feedback, will fix in the next weekend. |
does it fixed? plz. |
This question stuck with me all day.My troubleshooting and solutions are as follows. troubleshootingI'm not a professional front-end person, so I roughly analyzed the extension running logic. The problem appears on line 106364(Because I added some logs, it is inaccurate.) of extension.js: else {
console.log(`106351 scriptPath:${scriptPath},imagePath:${imagePath}`)
execution = child_process_1.spawn('sh', [scriptPath, imagePath]);
}
execution.stdout.on('data', (data) => {
if (platform === 'linux') {
if (data.toString().trim() === 'no xclip') {
ctx.emit(enum_1.IBuildInEvent.NOTIFICATION, {
title: 'xclip not found',
body: 'Please install xclip before run picgo'
});
return reject(new Error('Please install xclip before run picgo'));
}
}
const imgPath = data.toString().trim(); Note that the Continue the analysis because the result returned by The answer is that this line runs incorrectly. res=$(powershell.exe -noprofile -noninteractive -nologo -sta -executionpolicy unrestricted -file $(wslpath -m $scriptPath) $(wslpath -m $imagePath)"//"$imageName) Powershell's execution policy leads to this problem. Make a simple simulation here.I put the picture in the folder. clk@dp:~$ powershell.exe -noprofile -noninteractive -nologo -sta -executionpolicy unrestricted -file //wsl.localhost/Ubuntu-20.04/home/clk/.vscode-server/extensions/spades.vs-picgo-2.1.6/dist/clipboard/windows10.ps1 //wsl.localhost/Ubuntu-20.04/home/clk/.picgo//20221029092938.png
AuthorizationManager 检查失败。
+ CategoryInfo : SecurityError: (:) [],ParentContainsErrorRecordException
+ FullyQualifiedErrorId : UnauthorizedAccess solution
Note that: the path is like
resultclk@dp:~$ powershell.exe -noprofile -noninteractive -nologo -sta -executionpolicy unrestricted -file //wsl.localhost/Ubuntu-20.04/home/clk/.vscode-server/extensions/spades.vs-picgo-2.1.6/dist/clipboard/windows10.ps1 //wsl.localhost/Ubuntu-20.04/home/clk/.picgo//20221029092938.png
//wsl.localhost/Ubuntu-20.04/home/clk/.picgo//20221029092938.png refs |
Have you repaired it? I am still unable to upload images in WSL, and the error is still PicGo: read file/mnt/c/programfiles/Microsoft VS Code/error |
Try to refer to the solution section in my reply. |
Later I use PicGo instead of this. |
Um I just don't think the picgo experience under Windows is very good, and integrating it into vscode would be more efficient |
Can this plugin be installed with the picgo plugin? |
Sorry, I'm not a developer and I don't quite understand your method...This is my problem. |
Extension show this error in WSL2:
PicGo: read file /mnt/d/programming/Microsoft VS Code/ error.
Should i modify the permission of vscode in windows?
The text was updated successfully, but these errors were encountered: