Skip to content

Commit

Permalink
Debug build
Browse files Browse the repository at this point in the history
  • Loading branch information
goswinr committed Dec 15, 2024
1 parent 7c5311e commit 556d550
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 3 deletions.
5 changes: 4 additions & 1 deletion Src/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,11 @@ open Rhino.PlugIns

// IMPORTANT:
// Without this Guid Rhino does not remember the plugin after restart, setting <ProjectGuid> in the new SDK fsproj file does not to work.
#if DEBUG
[<assembly: Guid("e5fab201-4690-49da-8017-203cab8cc11f")>] // so that debug loading and yak install work side by side
#else
[<assembly: Guid("01dab273-99ae-4760-8695-3f29f4887831")>] //Don't change it !! its used in Rhino.Scripting.dll via reflection to find the hosting editor.

#endif

// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
Expand Down
7 changes: 6 additions & 1 deletion Src/Commands.fs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@ type LoadEditor () =
inherit Commands.Command()
static member val Instance = LoadEditor()

override this.EnglishName = "Fesh" //The command name as it appears on the Rhino command line.
override this.EnglishName =
#if DEBUG
"FeshDebug"
#else
"Fesh" //The command name as it appears on the Rhino command line.
#endif

override this.RunCommand (doc, mode) =
FeshApp.showEditor()
Expand Down
8 changes: 7 additions & 1 deletion Src/PlugIn.fs
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,13 @@ type FeshPlugin () =
RhinoAppWriteLine.print "loading Fesh.Rhino Plugin ..."
try
let canRun () = not <| Rhino.Commands.Command.InCommand()
let host = "Rhino"
let host =
#if DEBUG
"RhinoDebug"
#else
"Rhino" //The command name as it appears on the Rhino command line.
#endif

let hostData : Fesh.Config.HostedStartUpData = {
hostName = host
mainWindowHandel = RhinoApp.MainWindowHandle()
Expand Down

0 comments on commit 556d550

Please sign in to comment.