Github Sketchup repo

Hi all,

I need a small advise on github for Sketchup extension.

How you manage your extension on github?
I use github for RoR where I push an entire project folder but for Sketchup extension I push folder and main file manually.
What’s your best way push it ?

Do you mean push changes to the Git repo - or how to load the extension from the repo into Sketchup?

I keep all my extensions in Git/Mercurial - and I have a folder where each project is. I then have a file in the Plugins folder which adds the path to each extension to $LOAD_PATH and then require it.

I’n not sure if that answered your question…?

1 Like

hi Tomthom,
That exactly what i’m looking for !

Thanks a lot

Just as an example - this is one of my loader-scripts:

SOURCE = File.join(ENV["HOME"], "SourceTree").freeze

# Load platform neutral extensions.
paths = [
  "#{SOURCE}/Classifier Properties/src",
  "#{SOURCE}/Template Translation",

# Load all Ruby files in the external paths.
paths.each { |path|
  $LOAD_PATH << path
  Dir.glob("#{path}/*.{rb,rbs}").each { |file|
    rescue LoadError => error
      p error
      puts "\tfrom #{error.backtrace.join("\n\tfrom ")}"

I use Atlassins SourceTree to manage my git repos - so whenever I setup a new one I need to use I just add another line to the loader script.

1 Like

Thanks Tomthom.
i finaly make a script that copy and push extension. I feel more confortable with it.

Hi all

I’m just starting to experimenting with Git and will therefore restructure my plugin directories.

Thomthom: I’m a little curious why you manually define an array of paths. Has it any advantages over Dir.glob("#{SOURCE}//src/.{rb,rbs}") ?