dotBunny / VSCode

Unity Visual Studio Code Integration
MIT License
673 stars 180 forks source link

Not opening editor with Insiders #119

Closed nfantone closed 7 years ago

nfantone commented 8 years ago

As described in https://github.com/dotBunny/VSCode/issues/118#issuecomment-238012101, selecting "Assets > Open C# Project in Code" or clicking the "Open" button on the inspector for script files, doesn't seem to have any effect.

Using:

More on PR https://github.com/dotBunny/VSCode/issues/118.

jvlppm commented 8 years ago

My pull request did change the launch command on OSX, so it would launch the vscode indicated by the selected vscode path

https://github.com/dotBunny/VSCode/pull/114/files

This pull request was merged, but a later commit https://github.com/dotBunny/VSCode/commit/1e1a2e01c83a01c356dd6317b1fba2ae9771f30f

did change this back to the old behavior, feeling like the file content was replaced by an older version during conflict resolution.

reapazor commented 8 years ago

I think the intent with the below block was to stick to using the typical launch properties, I'll grab the latest insiders and see about that tonight ... I 'thought' this would have handled it. Maybe its the wrong domain.

#if UNITY_EDITOR_OSX
            proc.StartInfo.FileName = "open";

            // Check the path to see if there is "Insiders"
            if (CodePath.Contains("Insiders"))
            {  
                proc.StartInfo.Arguments = " -n -b \"com.microsoft.VSCodeInsiders\" --args " + args.Replace(@"\", @"\\");
            } 
            else 
            {
                proc.StartInfo.Arguments = " -n -b \"com.microsoft.VSCode\" --args " + args.Replace(@"\", @"\\");
            }

            proc.StartInfo.UseShellExecute = false;
#elif UNITY_EDITOR_WIN
            proc.StartInfo.FileName = CodePath;
            proc.StartInfo.Arguments = args;
            proc.StartInfo.UseShellExecute = false;
#else
            proc.StartInfo.FileName = CodePath;
            proc.StartInfo.Arguments = args.Replace(@"\", @"\\");
            proc.StartInfo.UseShellExecute = false;
#endif
frankprogrammer commented 8 years ago

Everything is working fine with:

On Thu, Aug 11, 2016 at 10:28 AM, Matthew Davey notifications@github.com wrote:

I think the intent with the below block was to stick to using the typical launch properties, I'll grab the latest insiders and see about that tonight ... I 'thought' this would have handled it. Maybe its the wrong domain.

if UNITY_EDITOR_OSX

        proc.StartInfo.FileName = "open";
        // Check the path to see if there is "Insiders"
        if (CodePath.Contains("Insiders"))
        {
            proc.StartInfo.Arguments = " -n -b \"com.microsoft.VSCodeInsiders\" --args " + args.Replace(@"\", @"\\");
        }
        else
        {
            proc.StartInfo.Arguments = " -n -b \"com.microsoft.VSCode\" --args " + args.Replace(@"\", @"\\");
        }

        proc.StartInfo.UseShellExecute = false;

elif UNITY_EDITOR_WIN

        proc.StartInfo.FileName = CodePath;
        proc.StartInfo.Arguments = args;
        proc.StartInfo.UseShellExecute = false;

else

        proc.StartInfo.FileName = CodePath;
        proc.StartInfo.Arguments = args.Replace(@"\", @"\");
        proc.StartInfo.UseShellExecute = false;

endif

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/dotBunny/VSCode/issues/119#issuecomment-239231455, or mute the thread https://github.com/notifications/unsubscribe-auth/ACPbazrUTpVp2HTSW88DJEkkF0I6OwAhks5qe1vUgaJpZM4JhyH1 .

nfantone commented 8 years ago

@frankprogrammer How did you install the plugin? Did you use the Asset Store? Are you on OSX?

nfantone commented 8 years ago

@reapazor I don't believe the domain is the problem here. As I mentioned in #118 , if you edit proc.StartInfo.UseShellExecute = false; and set it to true, the editor opens just fine (along with a warning in Unity's console).

reapazor commented 8 years ago

Ahh i was just looking at the top of that issue, i see what you mean. Is that specific to insiders only?

frankprogrammer commented 8 years ago

Ah didn't see this issue was talking about the Asset Store version originally. I got it through GitHub on June 23rd and it has updated on its own a couple of times. Update Timer set to 1 Day. Running OS X 10.11.3 and 10.11.6. Also tried it with Unity 5.4.0f3 and it works too. Everything checked in settings except Always Write Launch File and my VS Code Path is /Applications/Visual Studio Code - Insiders.app

All my proc.StartInfo.UseShellExecute are set to false.

On Thu, Aug 11, 2016 at 2:00 PM, Nicolás Fantone notifications@github.com wrote:

@frankprogrammer https://github.com/frankprogrammer How did you install the plugin? Did you use the Asset Store? Are you on OSX?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/dotBunny/VSCode/issues/119#issuecomment-239290878, or mute the thread https://github.com/notifications/unsubscribe-auth/ACPba7461yLmJKime1sWdIxXY8FW_pjYks5qe41ggaJpZM4JhyH1 .

nfantone commented 8 years ago

So maybe I am doing something wrong. Just now, I created a new project, installed the plugin from scratch, activate it and still nothing.

Could somebody else try it out and report?

On Aug 11, 2016 7:41 PM, "Frank Ramirez" notifications@github.com wrote:

Ah didn't see this issue was talking about the Asset Store version originally. I got it through GitHub on June 23rd and it has updated on its own a couple of times. Update Timer set to 1 Day. Running OS X 10.11.3 and 10.11.6. Also tried it with Unity 5.4.0f3 and it works too. Everything checked in settings except Always Write Launch File and my VS Code Path is /Applications/Visual Studio Code - Insiders.app

All my proc.StartInfo.UseShellExecute are set to false.

On Thu, Aug 11, 2016 at 2:00 PM, Nicolás Fantone <notifications@github.com

wrote:

@frankprogrammer https://github.com/frankprogrammer How did you install the plugin? Did you use the Asset Store? Are you on OSX?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/dotBunny/VSCode/issues/119#issuecomment-239290878, or mute the thread https://github.com/notifications/unsubscribe-auth/ ACPba7461yLmJKime1sWdIxXY8FW_pjYks5qe41ggaJpZM4JhyH1 .

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/dotBunny/VSCode/issues/119#issuecomment-239315397, or mute the thread https://github.com/notifications/unsubscribe-auth/AAdDpSqK7l4zezjnR2lVIBRnkDw-7HHdks5qe6UvgaJpZM4JhyH1 .

reapazor commented 7 years ago

I'm closing this, but reopen if it still presists in the latest of all things :)