我想设置默认的 python 解释器路径,以避免每次登录远程服务器时都被询问。
我尝试过这个类似答案中的方法。我的workspace.json 现在看起来像:
{
"folders": [
{
"uri": "vscode-remote://ssh-remote+172.1.1.1/home/user/workspace/folder1"
},
{
"uri": "vscode-remote://ssh-remote+172.1.1.1/home/wzy/workspace/folder2"
}
],
"remoteAuthority": "ssh-remote+172.1.1.1",
"settings": {
"python.defaultInterpreterPath": "/home/user/miniconda3/envs/py38/bin/python",
}
}
Run Code Online (Sandbox Code Playgroud)
但是每次重新连接到服务器时,我都需要手动选择 python 解释器(否则/user/bin/python3将选择基本解释器)
我无法通过 VSCode 远程开发或 WSL 在我的无头机器上安装 Vim VSCode 扩展。我想我以前可以,但我卸载了一次,从那以后我就再也无法安装它了。我只能在我的 Windows 计算机上安装和卸载,但不能远程安装和卸载:当我单击按钮将 Windows 扩展安装到服务器时,Vim VSCode 扩展不是批处理的一部分:
编辑:实际上,该扩展在 Windows 中也停止工作,没有明显的原因。
这是我的扩展列表:也许我引入了我不知道的不兼容性:
我想知道如何获取扩展的 JSON 列表:(
我想要显示在 Windows VS Code 中打开的 Powershell 中的目录中的所有文件(包括隐藏文件)。我想要相当于“ls -a”的 Powershell。
我怎么做?
我试过了:
dir ./d
dir /a
dir ./a
dir /ad
dir \h
Run Code Online (Sandbox Code Playgroud)
...以及这些的许多变体
我正在使用课程所需的特定语法,但是当我在 VS Code 中使用此 C++ 语法时,它不起作用并会引发错误。
以下是无效语法的示例:
error: expected ';' at end of declaration
int i {0};
^
;
Run Code Online (Sandbox Code Playgroud)
当我将其更改为int i = 0;错误时,错误就消失了。
它特别不识别{}设置默认变量值的语法。我ssh在本课程中使用登录名,语法在 中运行良好ssh,但在 VS Code 中不起作用。
我尝试通过执行此线程中的最佳答案将 VS Code C++ 版本更改为 C++17 ,但它仍然无法识别语法。
我是否使用了不正确的语法,或者有办法解决这个问题吗?
我在 Windows 10 上安装了“node”和“npm”。我使用以下命令检查安装情况,一切正常。
c:\>node -v
v16.17.0
c:\>npm -v
8.15.0
Run Code Online (Sandbox Code Playgroud)
当我尝试在“IntelliJ”终端中运行以下命令时,出现错误。
PS D:\Cypress> npm init
Program 'npm.cmd' failed to run: Access is deniedAt line:1 char:1
+ npm init
+ ~~~~~~~~.
At line:1 char:1
+ npm init
+ ~~~~~~~~
+ CategoryInfo : ResourceUnavailable: (:) [], ApplicationFailedException
+ FullyQualifiedErrorId : NativeCommandFailed
Run Code Online (Sandbox Code Playgroud)
我该如何解决?
我无法在我的 arduino 项目上解决这个问题。我在 vscode 上使用 Platformio。
我想使用 MFRC522_I2C 库来读取 rfid 徽章,因此我创建了一个类来使用库方法。
该库可以在这里找到:https ://github.com/arozcan/MFRC522-I2C-Library
这是我的代码:
主要.cpp:
#include <Arduino.h>
#include "rfid/Rfid.hpp" // my rfid class
Rfid _rfid;
void setup()
{
Serial.begin(115200);
_rfid.setupRfid();
}
void loop()
{
_rfid.rfidLoop();
}
Run Code Online (Sandbox Code Playgroud)
射频识别.cpp:
#include "Rfid.hpp"
Rfid::Rfid(/* args */)
{
}
Rfid::~Rfid()
{
}
void Rfid::setupRfid()
{
_rfidReader.PCD_Init();
}
void Rfid::rfidLoop()
{
// here is my code to read the rfid
}
Run Code Online (Sandbox Code Playgroud)
射频识别.hpp:
#ifndef _RFID_HPP_
#define _RFID_HPP_
#include "../lib/rfidReader/MFRC522_I2C.h" // the MFRC522 library
MFRC522 _rfidReader(0x28);
class …Run Code Online (Sandbox Code Playgroud) c++ arduino multiple-definition-error visual-studio-code platformio
我正在使用 VScode 在 jupyter 上使用 keras_ocr。通过运行此代码:prediction_groups = pipeline.recognize(images) 我收到此错误消息“如何修复错误消息”在回复完成之前取消了execute_request消息的未来在当前单元格或上一个单元格中执行代码时内核崩溃细胞。请检查单元格中的代码以确定失败的可能原因。点击这里查看更多信息。查看 Jupyter 日志以获取更多详细信息。”有人可以帮我解决这个问题吗
解决内核问题
我已在 settings.json 文件中添加此 java classPath,以在 Ubuntu 22.04 的 vscode 中使用 JavaFx
"java.classPath": "/usr/share/openjfx/lib",
Run Code Online (Sandbox Code Playgroud)
添加此行后,Java 编译器之前向我显示的与 JavaFX 包和方法相关的错误消息消失了。JavaFX 的智能感知和建议也正在发挥作用。
但我在 settings.json 文件中收到此错误消息
无法从“vscode://schemas/settings/folder”加载架构:无法打开 vscode://schemas/settings/folder。详细信息:无法解析资源 vscode://schemas/settings/folder 的文本模型内容。
我的 settings.json 文件如下所示:
{
"java.classPath": "/usr/share/openjfx/lib",
"java.project.sourcePaths": ["src"],
"java.project.outputPath": "bin",
"java.project.referencedLibraries": [
"lib/**/*.jar",
"/usr/share/openjfx/lib/javafx.web.jar",
"/usr/share/openjfx/lib/javafx.swing.jar",
"/usr/share/openjfx/lib/javafx.media.jar",
"/usr/share/openjfx/lib/javafx.graphics.jar",
"/usr/share/openjfx/lib/javafx.fxml.jar",
"/usr/share/openjfx/lib/javafx.controls.jar",
"/usr/share/openjfx/lib/javafx.base.jar"
],
"java.debug.settings.onBuildFailureProceed": true
}
Run Code Online (Sandbox Code Playgroud)
我尝试通过从 chatGPT 获得的链接更改架构文件夹,并在这里搜索了一些与此相关的问题。但它们都不起作用。
这是我过去几天收到的问题,我使用了nodejs,并且没有安装任何Python或其他软件
我已经删除了所有扩展并删除了缓存