Skip to content

Commit

Permalink
Merge pull request #13 from Learningcomputers777/add_contributing.md
Browse files Browse the repository at this point in the history
Add contributing.md
  • Loading branch information
Alexandrbig1 committed Oct 28, 2023
2 parents 7cac88e + 1ffdd96 commit c370e5a
Showing 1 changed file with 66 additions and 0 deletions.
66 changes: 66 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
### Contribution
Certainly! Here's a step-by-step guide on how to contribute to a GitHub repository using Git:

### 1. **Fork the Repository:**
- Go to the GitHub page of the repository you want to contribute to.
- Click on the "Fork" button in the upper right corner. This creates a personal copy of the repository on your GitHub account.

### 2. **Clone Your Fork:**
- On your forked repository, click the "Code" button and copy the URL.
- Open your terminal or command prompt.
- Use `git clone` followed by the URL to clone the repository to your local machine:
```
git clone https://github.com/your-username/repository.git
```

### 3. **Create a New Branch:**
- Change into the repository directory:
```
cd repository
```
- Create a new branch for your contribution:
```
git checkout -b feature/new-feature
```

### 4. **Make Changes:**
- Make the necessary changes in the code using your preferred code editor.

### 5. **Stage and Commit Changes:**
- Stage your changes:
```
git add .
```
- Commit your changes with a descriptive message:
```
git commit -m "Add new feature"
```

### 6. **Push Changes to Your Fork:**
- Push your changes to your forked repository on GitHub:
```
git push origin feature/new-feature
```

### 7. **Create a Pull Request (PR):**
- Visit your forked repository on GitHub.
- Click on the "New Pull Request" button next to the branch you just pushed.
- Write a clear title and description for your pull request, explaining the changes you made.
- Click on the "Create Pull Request" button to submit your contribution.

### 8. **Respond to Feedback:**
- Be responsive to any feedback or suggestions given by the maintainers. You might need to make additional changes based on the feedback.

### 9. **Merge Changes:**
- Once your pull request is approved, it will be merged into the main repository by the project maintainer(s).

### 10. **Syncing with Upstream (Optional):**
- If the original repository you forked from has new changes and you want to update your fork:
```
git remote add upstream https://github.com/original-repository/repository.git
git fetch upstream
git checkout main
git merge upstream/main
git push origin main
```

0 comments on commit c370e5a

Please sign in to comment.