sketchucation logo sketchucation
    • Login
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info

    Best practices for creating an rbe

    Scheduled Pinned Locked Moved Developers' Forum
    4 Posts 2 Posters 7.2k Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • F Offline
      Frankn
      last edited by

      I've been trying to get a plugin signed and running into some issues which seem to be related with require... I get these errors...
      @unknownuser said:

      Error: #<LoadError: cannot load such file
      .

      I found this post https://forums.sketchup.com/t/cant-load-required-rb/42755/3 where Dan uploaded some templates but I'm not sure how the
      @unknownuser said:

      MultiClass_MultiFile.zip
      works. Does anyone have a sample code that I can look at or can someone please explain how those files should be structured and how they work together?

      Frank

      1 Reply Last reply Reply Quote 0
      • Dan RathbunD Offline
        Dan Rathbun
        last edited by


        If you are having issues with Trimble's signing portal, then the best place to ask is:

        • SketchUp forums: Developers > Extension Warehouse for Developers
          .. or the main developers forum:

        • SketchUp forums: Developers

        ThomThom And Julia monitor those forum categories and should be quick to answer (if the question and answer has not already been posted previously, which might often be the case.)

        Also see newer help pages:

        • Developing Extensions for Extension Warehouse

        • Extension Signing and Encryption

        • Extension Development Best Practices


        That said, the Ruby core Kernel#require method cannot load scrambled ( rbs) or encrypted ( rbe) files.

        You must use the API's Sketchup::require module method andyou need to omit the file extension ( .rb, .rbs or .rbe) when you call the SketchupExtension::new class constructor in your extension registrar script.

        I'm not here much anymore.

        1 Reply Last reply Reply Quote 0
        • F Offline
          Frankn
          last edited by

          Thanks for the info Dan... I'll check out those forums. I wasn't even aware that the Sketchup API had it's own require method and it explains why I'm having problems. I guess I have some more learning and reading to do! 😄

          1 Reply Last reply Reply Quote 0
          • F Offline
            Frankn
            last edited by

            Where can I find info and/or examples on how to set this part of the loader file? I'm searching but not finding anything...

            require "Author_MultiClassPlugin/MultiClassPlugin_SharedConstants.rb"
            
            include SharedConstants # mixin the constant module
            

            And this from the SharedConstants file?

            SOME_SEARCH_PATTERN ||= /^Author/
            

            Thanks

            1 Reply Last reply Reply Quote 0
            • 1 / 1
            • First post
              Last post
            Buy SketchPlus
            Buy SUbD
            Buy WrapR
            Buy eBook
            Buy Modelur
            Buy Vertex Tools
            Buy SketchCuisine
            Buy FormFonts

            Advertisement