How Can I Get Scripts From A GitHub Repo?

Hello! I have seen this in some scripts that people get scripts from a Github Repo. I was wondering how I could do that.

The above will then create a folder somewhere and then a .Lua file in that folder called something will have code in it.
Example Code: print("DevForum Is Sickly Cool")

Is this possible? (Probably. I’ve Seen It In A Lot Of Models)

1 Like

You can use loadstring to do this, It must be enabled via ServerScriptService tho!

EDIT: Then you would do loadstring(“”)


So then it will get the code from it?

Yes, it would get the code from it and then run the script.

Is there anyways for it to create instances of it though?

What do you mean by Instances?

1 Like

Like below:

Screen Shot 2020-05-10 at 2.38.20 pm

loadstring requires a string of valid Lua code. You need to make a GET request to to get its contents.

local HttpService = game:GetService("HttpService")
local code = HttpService:GetAsync("", true)
local f = loadstring(code)

@Aiden_12114 no, but loadstring returns a function. You then call the function to execute the given code.


Ah my bad, Havnt used loadstring in a while. Im used to just requring the code.

1 Like

@sjr04 I saw that RoStrap get’s models from GitHub and imports them into Roblox Studio. So it must be possible, right?

(Such As Installing CmdR)

1 Like

How can I use this with an access token?