update.NamespaceFolders - tooll3/t3 GitHub Wiki

This is the breaking change. If you already created content with Tooll (no matter if with the Stand Alone Version v3.3 or with and IDE on the dev branch), this is important.

What changed?

We changed how Tooll saves Operators from a flat list into a Directory structure that is derived from the Operator's namespace. They are still stored in Operator/Types/ but instead of a flat list like...

__ImageQuadEmitterOBSOLETE.cs
__ImageQuadEmitterOBSOLETE_bb617a86-d771-480a-be94-c9cc460252a5.t3
__ImageQuadEmitterOBSOLETE_bb617a86-d771-480a-be94-c9cc460252a5.t3ui
_PhysrumAgents2.cs
_PhysrumAgents2_c0feef61-8cec-4418-8889-4001cbe1a957.t3
_PhysrumAgents2_c0feef61-8cec-4418-8889-4001cbe1a957.t3ui
_RenderFontBuffer.cs
_RenderFontBuffer_c5707b79-859b-4d53-92e0-cbed53aae648.t3
_RenderFontBuffer_c5707b79-859b-4d53-92e0-cbed53aae648.t3ui
_SetAudioAnalysis.cs
...

... operators are sorted into a hierarchy:

Operator/
  Types/
    lib/
      3d/
        mesh/
             DrawMesh.cs
             DrawMesh_a3c5471e-079b-4d4b-886a-ec02d6428ff6.t3
             DrawMesh_a3c5471e-079b-4d4b-886a-ec02d6428ff6.t3ui
             DrawMeshAtPoints.cs
             DrawMeshAtPoints_42cb88bc-beb8-4d89-ac99-44b77be5f03e.t3
             DrawMeshAtPoints_42cb88bc-beb8-4d89-ac99-44b77be5f03e.t3ui
             DrawMeshHatched.cs
         rendering/
             ...

Why did we do this?

  1. It will allow users to find and separate their content.
  2. We can have operators with the same Title in different namespaces (e.g. lib.math.int.Add and lib.math.float.Add).
  3. Advanced users can use git-submodules to separate their content from the main repository without forking.
  4. It will open the path for automatic upgrading between versions.
  5. It smooths the path towards packages.

What does it mean for you?

  • If you're new to T3 and didn't create new Operators so far you can ignore this change.
  • If you already created new Operators you should do one of the following...
    • commit them to the dev-branch with a pull request
    • or make sure the new operators have [valid namespaces]

Background

This feature is massive refactoring touching many aspects of Tooll's core. When you're starting Tooll with this new feature and click on File → Save All all Operators will automatically be moved according to their namespaces. This will fail if...

  • the source filename does not match the Symbol class name (e.g. Int3FromInt.cs vs Int3FromInts)
  • the namespace is empty or contain invalid characters.

What we tested so far...

  • Combining selections into new operators.
  • Renaming operators.
  • Live coding and hot reloading (modifying operators with an IDE while tooll is running).
  • Exporting executables.

Next steps

  • Currently this feature is only available in the feat/namespace-folders branch. Pixtur is using this branch for active development
  • After further testing he will push this feature onto the dev branch and it will have an immidiate impact on the next start.

Known issues

  • After creating a new Operator (e.g. by combining) you have to manually rebuild the solution in your IDE. Otherwise you might get the exception...

"Definition '{instanceTypeName}' is missing in Operator.dll".

⚠️ **GitHub.com Fallback** ⚠️