Relevance

As the GitHub Manager I have to make sure our repositories don't have issues and that everyone is aware of how to work with Git to where they can get their code up on a branch. If there are issues on GitHub or with Git I'm responsible for helping people fix them. This role was originally Mahaveers however during one of the sprints Mahaveer mentioned that he has no experience with GitHub so I didn't see a reason for him to keep this role.

Technical Challenges

Rare Issues: I have the capacity to teach someone how to use Git to a satisfactory level and maybe help resolve issues. Recently however Mahaveer and Rod have come up with issues with GitHub that I have never come across and I need to ask Jeremy for help so we need to pair up usually to fix these rare issues

 

Github and Why?

GitHub is a web-based platform that offers version control and collaboration features using Git. It helps developers manage and share code efficiently, enabling them to work together on projects seamlessly.

We use GitHub for several reasons:

  • Version control: GitHub helps us track changes in our codebase, maintain multiple versions, and revert to previous versions if needed, ensuring a stable and organized development process.
  • Collaboration: GitHub simplifies team collaboration, allowing multiple developers to work on a project simultaneously, merge changes, and resolve conflicts with ease.
  • Code review: With GitHub, we can perform code reviews, catch bugs, and improve code quality before merging changes into the main branch.
  • Integration: GitHub integrates with various tools and services, streamlining the development workflow and enhancing productivity.

What are Pull Requests

Pull requests, in a simple manner, are a feature in GitHub that allows developers to propose changes to a codebase. They enable team members to review, discuss, and approve modifications before merging them into the main branch.

Pull requests provide protection for Guidify in several ways:

  • Code review: Pull requests ensure that changes are reviewed by other team members, catching potential bugs or issues before they become part of the main codebase. This improves the overall code quality and stability of Guidify.

  • Accountability: By using pull requests, all changes made to the codebase are documented, making it easier to track who made specific modifications and why. This transparency encourages accountability and adherence to best practices.

  • Controlled merging: Pull requests help maintain the integrity of the main branch by only allowing approved changes to be merged, reducing the risk of introducing breaking changes or conflicts in the codebase of Guidify.

All of our Pull Requests start off like this from a template that I created at the beginning

 

This is what a typical Pull Request looks like.
A summary of the changes and then allowing the creator to include extra Details if necessary.

Webhooks and Why

Webhooks are a common way of allowing 2 separate applications to communicate together.

The reason we would want to use Webhooks is to add redundancy to how we notify of Pull Requests

Webhook setup GitHub

In order to set up WebHooks on GitHub I have to go into Settings > Webhooks > Add Webhook. Then when I have to insert the URL into the Payload URL section.
This URL is acquired from Discord mentioned below.

webhook highlighted git.png

In this scenario I want GitHub to communicate with Discord when certain events happen on GitHub.
I want Github to send an automatic message when a Pull Request is created and closed.

I will choose Let me select individual events and then a checkbox system comes up to choose what events I want to get notified for,
where I choose Pull Requests, now I will get a notification in discord when any of the events get fired off under that category.

select event.png    select event.png.1

 

 

Webhook setup discord

webhook dsicord.png.1

Discord is the main form of communication that we the team use and Discord allows for the integration of Webhooks where messages will get sent notifying the whole team of an event, in our case it will be anything related to a Pull Request.

In order to setup A webhook for Discord we go into the settings tab of a server, we then go into Integrations where we can manage all of our WebHooks on the server. Create a Webhook pressing New Webhook, we then select what Channel we want the notifications to come into, it is better to create a dedicated channel so as to not bury other messages in the channels. When all of this is done we Copy Webhook URL then we take this URL into GitHub and put it into the field that asks for the URL.
Now the setup is done and notification will start sending into discord to notify the team of events.

 

 

Webhooks displayed

Now that these notification are being sent it will be more difficult to miss the event of a PR and PR's can get reviewed more quickly and changes can be merged.
Below is an image of Pull Requests being open and closed after they have been merged.

https://i.imgur.com/DIHxc0D.png