Skip to content

Commit

Permalink
Avoid relying on entry assembly for netcore
Browse files Browse the repository at this point in the history
  • Loading branch information
glopesdev committed Jul 12, 2024
1 parent a07c2d2 commit d8343ef
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Bonsai/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,11 @@ internal static int Main(string[] args)
editorArgs.AddRange(new[] { PipeCommand, pipeName });

var setupInfo = new ProcessStartInfo();
#if NETFRAMEWORK
setupInfo.FileName = Assembly.GetEntryAssembly().Location;
#else
setupInfo.FileName = Environment.ProcessPath;
#endif
setupInfo.Arguments = string.Join(" ", editorArgs);
setupInfo.WorkingDirectory = workingDirectory;
setupInfo.UseShellExecute = false;
Expand Down

0 comments on commit d8343ef

Please sign in to comment.