Tutorials for Rhino/Grasshopper for mac on Visual Studio Code

I am developing a Grasshopper plugin using Visual Studio Code on a Mac, as Visual Studio for Mac will soon be retired. I have encountered significant challenges in the development process due to the scarcity of resources and guides for this specific environment. My primary issue is with the plugin not loading in Rhino WIP after compilation.

Development Environment:

  • OS: macOS 14.2.1 (23C71)
  • IDE: Visual Studio Code
  • Target Framework: .NET 8.0
  • Rhino Version: Version 8 (8.4.24044.15002, 2024-02-13)

Problem Description: After successfully compiling my C# code into a .gha file for a custom Grasshopper component, I placed the file in the Grasshopper Libraries folder. Despite following the expected procedures for plugin development, the component does not show up in the Grasshopper UI. There are no error messages or load errors dialogs upon startup in Grasshopper, and the component is missing from its designated category (“Utilities”) as well as other categories.

Also when on my script I run ‘run in WIP’ there is a compile error in rhino stating:
“Script server execute error:
Compile Error
The type or namespace name ‘Grasshopper’ could not be found (are you missing a using directive or an assembly reference?) (Error CS0246) file:///Users/jamesriggleman/code/c-sharp/HelloWorld/HelloWorld.cs:[2:7]
The type or namespace name ‘GH_Component’ could not be found (are you missing a using directive or an assembly reference?) (Error CS0246) file:///Users/jamesriggleman/code/c-sharp/HelloWorld/HelloWorld.cs:[5:36]
The type or namespace name ‘GH_InputParamManager’ could not be found (are you missing a using directive or an assembly reference?) (Error CS0246) file:///Users/jamesriggleman/code/c-sharp/HelloWorld/HelloWorld.cs:[14:49]
The type or namespace name ‘GH_OutputParamManager’ could not be found (are you missing a using directive or an assembly reference?) (Error CS0246) file:///Users/jamesriggleman/code/c-sharp/HelloWorld/HelloWorld.cs:[19:50]
The type or namespace name ‘IGH_DataAccess’ could not be found (are you missing a using directive or an assembly reference?) (Error CS0246) file:///Users/jamesriggleman/code/c-sharp/HelloWorld/HelloWorld.cs:[24:43]
‘HelloWorldComponent.Icon’: no suitable method found to override (Error CS0115) file:///Users/jamesriggleman/code/c-sharp/HelloWorld/HelloWorld.cs:[29:46]
‘HelloWorldComponent.ComponentGuid’: no suitable method found to override (Error CS0115) file:///Users/jamesriggleman/code/c-sharp/HelloWorld/HelloWorld.cs:[38:26]
‘GH_Component’ does not contain a constructor that takes 5 arguments (Error CS1729) file:///Users/jamesriggleman/code/c-sharp/HelloWorld/HelloWorld.cs:[8:9]”

It seems that in my vscode environment I am able to find the references to grasshopper and related packages, but once it tries compiling in rhino, there are compilation errors.

Complications:

  • The development workflow and resources for Grasshopper plugin development are scarce for Visual Studio Code, especially when compared to the retiring Visual Studio for Mac.
  • The absence of explicit documentation for plugin development in VS Code leads to uncertainty in project configuration and dependency management, particularly in ensuring the correct loading of plugins within Rhino WIP.

Request: I am seeking guidance or resources that could assist with Grasshopper plugin development in Visual Studio Code, especially in relation to:

  • Setting up the development environment in VS Code for Grasshopper plugin development.
  • Configuring project files (.csproj) to ensure compatibility with Rhino WIP.
  • Debugging and troubleshooting processes when the plugin does not load in Grasshopper.

Any help or direction to relevant resources would be greatly appreciated to bridge the gap caused by the transition from Visual Studio for Mac to Visual Studio Code for Grasshopper plugin development.

ignore the part about the "run in wwip, Im mostly looking for guidance on this =>
Request: I am seeking guidance or resources that could assist with Grasshopper plugin development in Visual Studio Code, especially in relation to:

  • Setting up the development environment in VS Code for Grasshopper plugin development.
  • Configuring project files (.csproj) to ensure compatibility with Rhino WIP.
  • Debugging and troubleshooting processes when the plugin does not load in Grasshopper.