Error6 al intentar usar texto sublime para msbuild

I'm trying to use msbuild with my sublime project. I created the build file sugerido aquí and the following is my project file

{
    "folders":
    [
        {
            "path": "/W/MyOrg/MyApp",
                        "folder_exclude_patterns": ["_ReSharper.*", "bin", "obj"]
        }
    ]
}

I select the msbuild40 build system and hit Build y obtén el resultado:

[Error 6] The handle is invalid
[Finished]

I'm not even sure if this is a python or an msbuild error. Which is it, how can I fix it, and whats a good way to troubleshoot this sort of stuff in the future?

Noticias

I tried updating my project to the following and using that build and still no dice

{
    "folders":
    [
        {
            "path": "/W/MyOrg/MyApp",
            "folder_exclude_patterns": ["_ReSharper.*", "bin", "obj"]
        }
    ],
    "build_systems":
    [
        {
            "name": "msbuild",
            "cmd": ["c:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319\\MSBuild.exe", "w:\\MyOrg\\MyApp\\MyApp.sln"]
        }
    ]
}

preguntado el 03 de mayo de 12 a las 21:05

1 Respuestas

Turns out that this happens whenever you start sublime from command line ( I was starting it via a powershell alias).

You can fix this by using a batch file and the START command. I created sublime_text.bat:

START "Sublime Text 2"  "C:\Program Files\Sublime Text 2\sublime_text.exe" %*

and set my powershell alias to that bat file. Now everything works.

contestado el 04 de mayo de 12 a las 16:05

That's mighty annoying. I para vivir in the command line so I never start ST2 (or anything else) except from the CLI. Thanks for sharing this! - seje

Thank you veeeeery much! This solved a problem I had with using SublimeREPL: github.com/wuub/SublimeREPL/issues/271 - L42

Unfortunately this doesn't seem to work with ST3's subl.exe. I could only get it to work with sublime_text.exe. :( - andreas haferburg

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.