Visual Studio 2022 已安装。运行错误。VS 2022。team_explorer.bat VsDevCmd.bat

Visual Studio 2022 已安装。运行错误。VS 2022。team_explorer.bat VsDevCmd.bat

已安装 Visual Studio 2022 Win 10 Home X64

启动并运行 VS 2022 的开发工具以及我得到的任何命令错误

**********************************************************************
** Visual Studio 2022 Developer Command Prompt v17.2.4
** Copyright (c) 2022 Microsoft Corporation
**********************************************************************
[ERROR:team_explorer.bat] Directory not found : "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer"

C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools>

搜索这个问题让我很头疼。

1- 搜索目录中的 team_explorer.bat 从未找到

2- 一些网络搜索让我测试了 VsDevCmd.bat

"C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\Tools\VsDevCmd.bat" -test

当我测试它时,出现以下错误

**********************************************************************
[TEST:dotnet.bat] Checking for ilasm.exe...
[TEST:msbuild.bat] checking for msbuild.exe...
[TEST:winsdk.bat] Checking for 'signtool.exe'...
[TEST:winsdk.bat] Checking for 'ucrt.lib' in LIB...
[TEST:winsdk.bat] Checking for 'kernel32.lib' in LIB...
[TEST:winsdk.bat] Checking for 'corecrt.h' in INCLUDE...
[TEST:winsdk.bat] Checking for 'windows.h' in INCLUDE...
[TEST:cmake.bat] Checking for cmake.exe...
[TEST:cmake.bat] Checking for ninja.exe...
C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\Common7\IDE\VC\Linux\bin\ConnectionManagerExe\ConnectionManager.exe
[TEST:netfxsdk.bat] Checking for ildasm.exe...
[TEST:netfxsdk.bat] Checking for sn.exe...
[TEST:team_explorer.bat] Testing for tf.exe...
[ERROR:team_explorer.bat] 'where tf.exe' failed
[TEST:testwindow.bat] Checking for vstest.console.exe...
[TEST:vcvars.bat] Checking for cl.exe...
[TEST:vcvars.bat] Checking for dumpbin.exe...
[TEST:vcvars.bat] Checking for msvcrt.lib in LIB...
[TEST:vcvars.bat] Checking for vcruntime.h in INCLUDE...
[ERROR:VsDevCmd.bat] *** VsDevCmd.bat encountered errors. Environment may be incomplete and/or incorrect. ***
[ERROR:VsDevCmd.bat] In an uninitialized command prompt, please 'set VSCMD_DEBUG=[value]' and then re-run
[ERROR:VsDevCmd.bat] vsdevcmd.bat [args] for additional details.
[ERROR:VsDevCmd.bat] Where [value] is:
[ERROR:VsDevCmd.bat]    1 : basic debug logging
[ERROR:VsDevCmd.bat]    2 : detailed debug logging
[ERROR:VsDevCmd.bat]    3 : trace level logging. Redirection of output to a file when using this level is recommended.
[ERROR:VsDevCmd.bat] Example: set VSCMD_DEBUG=3
[ERROR:VsDevCmd.bat]          vsdevcmd.bat > vsdevcmd.trace.txt 2>&1

最后如何解决这个问题?

3-一些网络搜索说系统环境变量路径未添加。

[https://developercommunity.visualstudio.com/t/vs2017-developer-command-prompt-directory-not-foun/359683]

如何添加以及在哪里添加!?

我没有 Sys Env VarVSINSTALLDIRDevEnvDir只有 Path 和其他非相对变量

在系统变量下Path只有这些

Path=
C:\windows\system32;C:\windows;C:\windows\System32\Wbem;
C:\windows\System32\WindowsPowerShell\v1.0\;
C:\windows\System32\OpenSSH\;
C:\Users\USER\AppData\Local\Programs\Python\Python39;
C:\Users\USER\AppData\Local\Programs\Python\Python39\Scripts;
C:\Users\USER\AppData\Local\Programs\Python\Python39\Lib\site-packages;
C:\Program Files\Git\cmd;
C:\Program Files\Wolfram Research\WolframScript\;
C:\Program Files\Microsoft SQL Server\150\Tools\Binn\;
C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;
C:\Program Files\dotnet\;
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC

最后

什么以及如何解决这个问题!?

我需要确切地知道该做什么以及怎么做!?

在系统下添加 Var。我将其命名为 !? 并且引用哪个文件 !?

主要错误源自

team_explorer.bat
VsDevCmd.bat

感谢你的帮助

答案1

我通过进入BuildTools\Common7\Tools\vsdevcmd\ext文件夹并重命名team_explorer.bat为解决了这个问题team_explorer.bat.skip

相关内容