use*_*459 21 windows windows-terminal
使用非管理员用户帐户的 Windows 10。
从 Microsoft Windows 应用程序安装 Windows 终端。调用wt.exe从cmd.exe无法找到它。使用快捷方式从开始运行 Windows 终端打开它。
运行wt.exe在cmd.exe从管理员帐户成功地打开它。
PATH变量具有非管理员用户的相关条目:%USERPROFILE%\AppData\Local\Microsoft\WindowsApps其中包含wt.exe。在资源管理器中单击它会打开 Windows 终端。
cmd.exe 的输出where和输出echo:
C:\Users\sr>wt
'wt' is not recognized as an internal or external command,
operable program or batch file.
C:\Users\sr>where wt
INFO: Could not find files for the given pattern(s).
C:\Users\sr>echo %USERPROFILE%
C:\Users\sr
Run Code Online (Sandbox Code Playgroud)
如何cmd.exe使用wt.ext非管理员帐户打开 Windows 终端?
编辑:所有命令都从 cmd.exe 中运行
编辑 2:wt.exe 也无法从 Powershell 启动,包括标准和管理员:标准:
PS C:\Users\sr> wt
wt : The term 'wt' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name,
or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ wt
+ ~~
+ CategoryInfo : ObjectNotFound: (wt:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
Run Code Online (Sandbox Code Playgroud)
行政
PS C:\WINDOWS\system32> wt
Program 'wt.exe' failed to run: The file cannot be accessed by the systemAt line:1 char:1
+ wt
+ ~~.
At line:1 char:1
+ wt
+ ~~
+ CategoryInfo : ResourceUnavailable: (:) [], ApplicationFailedException
+ FullyQualifiedErrorId : NativeCommandFailed
Run Code Online (Sandbox Code Playgroud)
编辑 3:在 cmd.exe 中,输入 wt.exe 的完整路径启动它:
C:\Users\sr>C:\Users\sr\AppData\Local\Microsoft\WindowsApps\wt.exe
Bra*_*don 80
TLDR:尝试App execution aliases在 Windows 10 中打开设置页面并关闭 Windows 终端的开关,然后再次打开。
我不确定这是否与原始问题中的问题完全相同,但我随机遇到了wt命令不起作用的问题(当我将它输入到“开始”菜单并按 Enter 键时,或者当我将它输入到文件资源管理器的地址栏尝试打开当前目录中的终端)。如果我在开始菜单中手动单击 Windows 终端或为其打开 Microsoft Store 页面并单击“启动”按钮,则它会起作用。我的路径环境变量是有序的,我没有安装 Windows 终端预览——只是 Windows 终端。
在谷歌搜索之后,我发现了一些提到 Windows 10 中的“应用程序执行别名”设置页面的内容。我打开它并关闭了开关,此时我看到%USERPROFILE%\AppData\Local\Microsoft\WindowsApps\wt.exe文件消失了。然后我wt.exe重新打开它并重新出现在该文件夹中。这样做之后,一切又正常了。
| 归档时间: |
|
| 查看次数: |
5340 次 |
| 最近记录: |