Multiple developers & one project
Best Version Control System overview and Tips 💻
When it comes to situation where multiple programmers work on the same project, communication is the first thing we must take care of. Of course, soft skills are very helpful, but not enough to organise workflow. Version control system, even with one person, is an amazing productivity tool. With two developers, it’s required.
Wamisoftware team uses Git and web-based Git repositories, such as GitLab, to track changes in source code during software development. The GitLab is a central place where developers store, share, test and collaborate on web projects. It doesn’t store data as a series of changesets or differences, but instead as a series of snapshots. When you make a commit, GitLab stores a commit object that contains a pointer to the snapshot of the content you staged. This object also contains the author’s name and email address, the message that you typed, and pointers to the commit or commits that directly came before this commit.
A branch in GitLab is simply a lightweight movable pointer to one of these commits. The default branch name in GitLab is master, but you can change it in repository settings. You can switch back and forth between the branches and merge them together when you’re ready. Branching means you diverge from the main line of development and continue to do work without messing with that main line. In GitLab, branches are a part of your everyday development process. Another cool feature is a built-in Continuous Integration/Delivery.
A developer makes a change in their feature branch and tests it. When they’re happy, they push and make a merge request. At least two developers that work on the project must check the code and approve it, and every change is reviewed by Team Lead. Once the approval rules have been met, the merge request can be merged if there is nothing else blocking it. Undoubtedly, GitLab is doing a fantastic job offering your entire development (and DevOps) teams great tools for more efficient workflows.
AUTOMATE THE BORING STUFF
Instead of constantly sending links by hand and asking for them, automate these steps. For example, our developer Alexey created a Telegram Chatbot that sends a notification whenever someone creates Merge Request, comments etc. Thus, everyone makes better use of their time and knows what’s going on.
GitLab can also send users a notification via email when a pipeline fails and when it has been fixed etc.
DON’T IGNORE CODE REVIEWS
Things that are obvious to experienced developers, may be confusing to newbies. And no matter how experienced we are, we all get tired sometimes. It happens that people keep unnecessary stuff due to tiredness, so it’s always good to have fresh eyes.
Code reviews enable developers to more easily identify bugs, because they’re assessing the code with a fresh perspective. Teams turn to code reviews as a way to share knowledge, mentor newer developers, and ease the burden of development. When everyone reviews code, there is no longer a single point of failure that can halt delivery and risk missing releases or business goals. Code reviews are worth the difficulties, because they help teams collaborate to maintain a clean codebase, learn from each other to develop new skills, and ensure that innovative solutions solve complex problems.
RESPECT PEOPLE’S TIME
Your actions must be clear, so please, follow these rules:
• Send commits frequently
• 1 change = 1 commit, but don’t send insignificant commits (they can fill up the history)
• Comments should start with phrase «This commit will» and be less than 50 characters
We hope you will find this quick overview useful! 👨🏼💻