This is a read-only snapshot of the ComputerCraft forums,
taken in April 2020.
Github?
Started by CreeperWiz, 10 March 2015 - 11:41 PMPosted 11 March 2015 - 12:41 AM
How can I get my project on github and then made my computer copy it from github? please ntoe one of my first times using github so i dont know much.
Edited on 10 March 2015 - 11:42 PM
Posted 11 March 2015 - 01:01 AM
Posted 11 March 2015 - 01:25 AM
Helpful but at same time not what i was looking for. so Thanky you
Posted 11 March 2015 - 01:45 AM
1. Get github account
2. Create Repository
3. Copy/Paste files into repository
4. Manually copy the url leading to the plaintext version of each file into your program*
5. Put program on pastebin
6. download program from pastebin using normal pastebin command
7. run program
*example (doesn't actually work, the URL is fake):
2. Create Repository
3. Copy/Paste files into repository
4. Manually copy the url leading to the plaintext version of each file into your program*
5. Put program on pastebin
6. download program from pastebin using normal pastebin command
7. run program
*example (doesn't actually work, the URL is fake):
local files = {
["filename"] = "https://www.githubusercontent.com/MyUsername/MyRepo/filename.lua"
}
for k, v in pairs( files ) do
local h = http.get( v )
if h then
local f = fs.open( k, "w" )
f.write( h.readAll() )
f.close()
h.close()
else
error( "couldn't connect" )
end
end
Posted 11 March 2015 - 02:20 PM
Also be sure in newer versions to check, whether github is acutally on the http whitelist.
Posted 13 March 2015 - 02:35 AM
Thank you but how do I put files on github?(IK IM A NOOB)
Thank you but how do I put files on github?(IK IM A NOOB)
1. Get github account
2. Create Repository
3. Copy/Paste files into repository
4. Manually copy the url leading to the plaintext version of each file into your program*
5. Put program on pastebin
6. download program from pastebin using normal pastebin command
7. run program
*example (doesn't actually work, the URL is fake):local files = { ["filename"] = "https://www.githubusercontent.com/MyUsername/MyRepo/filename.lua" } for k, v in pairs( files ) do local h = http.get( v ) if h then local f = fs.open( k, "w" ) f.write( h.readAll() ) f.close() h.close() else error( "couldn't connect" ) end end
Posted 13 March 2015 - 02:44 AM
https://guides.github.com/activities/hello-world/
You can skip creating issues, branches, and pull requests. Other than that, it's pretty strait forward.
You can skip creating issues, branches, and pull requests. Other than that, it's pretty strait forward.
Posted 13 March 2015 - 02:49 AM
helpful but i still don't get how to put my code and stuff inhttps://guides.githu...es/hello-world/
You can skip creating issues, branches, and pull requests. Other than that, it's pretty strait forward.
Posted 13 March 2015 - 03:26 AM
Step 1: Create a Repository.
…
Do you have a repository? If not, click the + next to your name in the upper right hand side of the website
It'll drop down two options.
Select New Repository
Give it a name
Check the box next to "Initialize this repository with a README"
Click the big green create button
Now, next to your repository name there will be a +
Click it
Name file, copy and paste file contents into file
Click "Commit New File"
Repeat
…
Do you have a repository? If not, click the + next to your name in the upper right hand side of the website
It'll drop down two options.
Select New Repository
Give it a name
Check the box next to "Initialize this repository with a README"
Click the big green create button
Now, next to your repository name there will be a +
Click it
Name file, copy and paste file contents into file
Click "Commit New File"
Repeat
Posted 13 March 2015 - 05:05 AM
This is exactly what you're looking for. Have you followed this guide, step by step yet? Try it. Do the whole thing. Once you've done every bit of it, maybe with some placeholder code or something just to try it out, then come back and link us to the github repo that was created in the process and tell us how it differed from what you were trying to do.
Posted 13 March 2015 - 07:54 AM
making an assumption on your OS preference here, but if you want to develop on your pc then you may want this (do the tutorials above me first though) https://windows.github.com/
Posted 13 March 2015 - 09:05 AM
I would recommend GitHub for Windows/Mac if you have those operating systems. Git's main website has a pretty good tutorial for the command line, you probably don't need to go beyond the first couple of 'levels'. Generally setting up is composed of:
git init # Create new repo
git add -A # Adds everything
git remote add origin https://github.com/<User>/<Repo>.git # (Adds the origin - the server that you push to - see more here https://help.github.com/articles/adding-a-remote/)
git commit # Code is managed in commits - you type a message here
git push -u origin master # Push to the origin on the master branch -u sets the 'upstream' branch - the branch that you push to.