Collaborators contribution workflow - HerCerM/uady-gdhe GitHub Wiki

Overview

The workflow presented here is a simpler version of the already simple GitHub Flow. The aim of the simplified workflow is to accelerate development by removing unnecessary complexity, while maintaining an understandable history and clear distinction in which commits built which feature/fix/enhancement.

The main branch is master (there is no develop) and every branch branches off of master (no sub-sub-branches).

Process

#1 Create a descriptive branch off of master

The first rule here is to always create a branch off of master (never branch out from a feature, fix or enhancement branch). The next rule regards descriptive names. Every branch must be named according to the following syntax:

(feature|fix|enhancement)/<target-artifact>

Examples of descriptive names include feature/login-front, fix/service-GET_classrooms, enhancement/refactor-Utility.

🏗 When the branch holds maintenance work, use this naming convention instead:

mr/<mr-three-digit-number-identifier>/<brief-description-of-the-solution>

Examples of valid maintenance branches: mr/002/fix-sidebar-superposition, mr/012/refactor-services-to-promises.

#2 Keep yourself updated and make your work visible

Constantly make sure your work is updated regarding master. To accomplish that, run the following command while you are in your branch:

$ git pull origin master

To keep your work visible to others and backed up, regularly push your work to the origin repository.

$ git push origin <my-branch>

#3 Open a pull request (PR) for approval of your branch

If you are unsure about your work, you can always request someone to check it via a PR marked as WIP. This is not requesting approval, only a check. If however, you would like your work to be approved to be merged into master, do open a PR but don't mark it as WIP. An approving review is necessary for the merge.

🏗 If the PR is for maintenance work, use the following naming convention for the title (use Spanish):

MR: <mr-three-digit-number-identifier>, (perfectivo | preventivo | correctivo | adaptativo), <brief-description>

Example of valid PR title: MR: 002, correctivo, arreglar superposición de barra lateral

#4 When your branch is merged into master, delete your branch

Simply delete your local branch and start with a new feature/fix/enhancement.

⚠️ **GitHub.com Fallback** ⚠️