diff --git a/README.md b/README.md index d3ba77c..a426d1d 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,51 @@ # How to contribute + This is CyberInfo's public Gitea instance. Feel free to download and use any -code you find in the public repositories. +code you find useful in the public repositories. -If you wish to contribute to any of these projects, you can either send me an -email with a patch by following these instructions. +If you wish to contribute to any of these projects, you can send me an email +with a patch by following these instructions: -* Send me email with a patch, and I'll apply it. See the instructions below. +1. First, clone the repository to your local computer. For example: + `git clone https://git.cyberinfo.se/jackbenny/autotape.git` -## Sending patching by email +2. Then, make your changes to the code. +Now it's time to prepare the patch. Run the following commands: + +```bash +git add +git commit -m "Write a good commit message here" +git format-patch -1 +``` + +Git will now create a `.patch` file in the current directory. + +3. Attach this `.patch` file in an email to me at + [jack-benny@cyberinfo.se](mailto:jack-benny@cyberinfo.se). + **Leave the filename as it is**. I'll apply the patch and push it to the repository. + In your email, please tell me the name of the repository. + +4. Once you’ve sent the email, you can delete the patch file from your computer. + +## Multiple commits +If you've made multiple commits to a project that you want to contribute, +simply change git format-patch -1 to reflect the number of commits. + +For example, if you've made four commits, run: + +```bash +git format-patch -4 +``` + +This will produce four separate `.patch` files. **Email me all of them, with +their filenames intact**. The filenames tell me the order in which to apply +them, as well as the commit messages. + +Also, please include the repository name in your email. + +I'll apply the patches and push them to the repository. + +## Good to know +Your name and email (as configured in your local Git) will appear in the +commit history.