Obviously we use Git to keep tracking of version history for the project. And if you read that you are surely on Github, the software we use on top of that.
We set some rules for the way we use branching model and naming.
The master
branch is the principal one, it’s directly linked to the server on production, so we never work directly on it, except for hot fixes.
The most important branch is staging
, is the main development branch. We always branch from it to develop a new feature.
Production version
Staging version
Any new feature should be develop on the branch (from staging
) and have a name like feature/add-login-button
for example. This will help to keep all ongoing feature in the feature
folder (if you are using a git client)
If you need to work on a bug, you can name your branch fix/wrong-redirection-on-newsletter-form
for example.
Use docs
convention name for any change, add or deletion if it’s related to a readme file, code documentation or any documentation related change.
If you need to code on any kind of improvement, like testing, refactoring, optimise performances,… You can use the imp
convention (for improvement). Example: imp/add-testing-for-service-creation
If you need to develop anything, be sure to always branch from staging
(Don’t forget to be up-to-date pulling the last version).
draft
pull request to the target branch (could be staging or any other sub-branch, but never master) to get review during the development process.Be sure to always be clear in your commit messages:
DO:
Add sign-up button on the home-page
, Redesign the navbar\n\nAdding stickyness and better color contrast, now the top bar is more visible and user understand better how to navigate
DON’T:
console.log()
Styling
, Add feature