We assume that you have called your remote of the official repo "official". We will call the repository "yourfork" and the branch with the bugfix or new feature "yourbranch". To submit a pull request, you will need to have a Github account and a repository "forked" from the offical angband repository. (Ideally you should commit any changes in the current branch before switching branches, but git does not like people undoing things so read up on git stash if you need to switch branches and don't want to either commit or lose the current changes.) Submitting a pull request There is no limit to the number of branches you can have, and you can use git checkout branchname to switch between branches at any time. Create one called 'stores' if you want to make changes to stores. Create a branch called 'docs' if you want to work on some docs. Keep your thinking clear: separate your work into different branches for different things. (It is advisable, but not essential, to use ssh keys for access to Github.) Assuming you have created a new branch and made your changes as described above, you can publish your changes to the world by using git push origin newbranch - this will make your new branch appear on Github for others to test. Once you have tested your commits to your satisfaction, you can share them.
Use git commit -a to commit your changes to your new branch and then build and test them. Create a new branch using git checkout -b newbranch, and do your work there. (release branches and other things you don't need to worry about)ĭo NOT do your work in your master branch: this is asking for trouble.This will create a local repository with several branches. This is the one you should clone locally using git clone git:///yourlogin/angband.git.
Instead, get an account at Github, go to the official angband/angband repository and click Fork. But if you want to participate in development, it is best not to do this straight away. To create a local copy of the official angband repository, use git clone git:///angband/angband.git. This advice assumes you are using git on the command line (a terminal in Linux or MacOS, or a tool like Github's git shell for Windows).
Git is a version control system designed to keep track of the progress of a software codebase. The preferred way to do this is to submit a pull request on Github. When you've fixed a bug or implemented a new feature, please let us know. It is largely a compilation of previous advice from various authors, updated as needed. This document is a guide to contributing to Angband.