在VS2015 RC上添加本机工具命令提示符 [英] Adding Native Tools Command Prompt on VS2015 RC

查看:3899
本文介绍了在VS2015 RC上添加本机工具命令提示符的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

由于我无法在工具菜单下找到Native Tools CMD,因此我尝试手动将其添加到外部工具中。几个问题:


  1. 无论我选择 Command (ARM,x86或x64等) strong>命令始终为 C:\Windows \System32\cmd.exe 。为什么不同的CMD最终拥有与原生System32的CMD相同的路径?

  2. 参考

    解决方案


    为什么不同的CMD最终拥有相同的路径System32的CMD?


    VS2015 * CMD只是 cmd.exe 设置为您。因此例如代替键入C:\Windows\Microsoft.NET\Framework64\v4.0.30319\InstallUtil.exe运行 InstallUtil.exe ,您只需输入 InstallUtil 即可。如果您没有设置环境变量,您将收到一条错误消息,指出installutil不能识别为内部或外部命令,可操作的程序或批处理文件。



    < blockquote>

    什么是/ k和什么是这个参数的bat?为什么我需要传递一个路径作为参数到命令提示符?


    / k cmd的参数。 exe 并且它做的是运行由以下字符串指定的命令(在这种情况下它将执行C:\Program Files(x86)\Microsoft Visual Studio 14.0 \Common7\Tools\VsDevCmd.bat并将执行)。


    什么是初始目录?


    初始目录用于指定工作目录您的 cmd.exe 实例将从

    开始

    所以最终你会有这样的Visual Studio 2015:





    VS2015的参数是:


    / kC:\Program文件(x86)\ Microsoft Visual Studio 14.0 \Common7\Tools\VsDevCmd.bat



    Since I cannot locate Native Tools CMD under the Tools menu, I try to manually add it in External Tools. Few questions:

    1. Regardless of what I choose for Command (ARM, x86 or x64 etc.), Command is always C:\Windows\System32\cmd.exe. Why the different CMDs end up having the same path to the native System32's CMD?
    2. Referring to this answer, I should insert /k "C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Tools\VsDevCmd.bat" to the arguments - what is the /k and what is the bat for this argument? Why do I need to pass a path as an argument to the command prompt?
    3. What is Initial Directory?

    解决方案

    Why the different CMDs end up having the same path to the native System32's CMD?

    The VS2015* CMDs are just cmd.exe with some environment variables already set up for you. so for example instead of typing "C:\Windows\Microsoft.NET\Framework64\v4.0.30319\InstallUtil.exe" to run InstallUtil.exe you will just type InstallUtil and it will work. if you didn't set up the environment variables you will get an error message saying that 'installutil' is not recognized as an internal or external command, operable program or batch file.

    what is the /k and what is the bat for this argument? Why do I need to pass a path as an argument to the command prompt?

    /k is a parameter for cmd.exe and what it does is run the commands specified by the string that follows (in this case it will execute what's inside "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\Tools\VsDevCmd.bat" and will carry out).

    What is Initial Directory?

    Initial directory is used to specify the working directory that your cmd.exe instance will start in

    So in the end you'll have something like this for Visual Studio 2015:

    The "arguments" for VS2015 is :

    /k "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\Tools\VsDevCmd.bat"

    这篇关于在VS2015 RC上添加本机工具命令提示符的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆