TUTORIAL: Using git to make changes to minetest

For people working on the C++ code.
abcd_z
Member
 
Posts: 13
Joined: Mon Sep 05, 2011 05:07

TUTORIAL: Using git to make changes to minetest

by abcd_z » Mon Sep 05, 2011 05:16

This is how I did it. I run on a linux box, so your experience may be slightly different.

1) Fork the minetest master. That means logging in to github, going to https://github.com/celeron55/minetest and clicking the "fork" button in the upper-right.

2) From your root directory, clone your forked minetest git to your local hard drive with the command "git clone git://github.com/your_user_name/minetest.git foldername" minus quotes. That should copy everything to the root directory under the folder name you decide on. If you leave <foldername> blank, the folder will automatically be named "minetest".

3) Copy the minetest folder. For this example let's call the new folder "minetest-copy".

4) Compile the source in minetest-copy and make changes as needed, making sure to keep records of everything you change.

If you don't want to keep records, you can always fiddle around with diff/patch files after you've made the changes, but I never really got the hang of them.

5) Once you have the compiled binary working the way you want, duplicate the changes you made (manually or via patch) in the minetest folder.

NOTE: you don't want to compile the source in the original minetest folder, because doing so will create a bunch of new files that shouldn't be in the repository.

6) Commit the changes by entering the command "git commit -a". A text editor will show up. At the bottom of the screen, below all the lines that start with "#", type a one-line description of the changes you made.

6) Push the changes from your hard drive to your fork with the command "git push"

7) Login to the minetest wiki and create a link to your patchset on the patchset page here:
http://91.155.42.12/~celeron55/minetest/wiki/doku.php?id=patchsets

8) Keep track of the patchset page and the IRC log page
http://2pktfkt.de/irc/minetest-delta/

If your patchset didn't get merged at the same time as several of the others, it probably means celeron55 had problems with it. At this point, get on IRC and talk to him to see what needs to be fixed.
Keep in mind 3 important points:

First, he may be on the server but not in the #minetest-delta room. Ask around in #minetest-delta, somebody should know. If nobody is online, "/whois celeron55" to see if he's currently online and message him that way.

Second, the most common times for people to chat are 11:00 to 22:00, CEST. (Use wolframalpha.com to convert it to your time zone.) I had problems syncing schedules because because I live on the far western border of the United States.

Third, celeron can be an antisocial dick, but his goal is to make the best program he can. That means that if your change doesnt "[make] sense and is awesome and adds to the gameplay", he may decide not to add it. That's his call. It may be open source, but it's his project.

Good luck!
Last edited by abcd_z on Thu Sep 08, 2011 07:05, edited 1 time in total.
 

No-Half-Measures
Member
 
Posts: 149
Joined: Tue Jul 26, 2011 00:42

by No-Half-Measures » Mon Sep 05, 2011 07:25

|This topic Does not belong here please Delete it and redo it in General Discussion.
 

abcd_z
Member
 
Posts: 13
Joined: Mon Sep 05, 2011 05:07

by abcd_z » Mon Sep 05, 2011 08:04

I disagree. Where else should a tutorial go about helping to develop the game but in the Development section of the board?
 


Return to Partly official engine development



Who is online

Users browsing this forum: No registered users and 2 guests