Sometimes I have seen students struggle with version controlling of their project. Git is the most useful tool to maintain the VCS. Where Github introduce you to the world of remote gits and open source. Github is more likely a code sharing space, and each repository is a git repository. But Github has much more than only git.
Before we deep dive into VCS, we’ll try to figure out WHY part of the topic. Let’s try to answer below questions:
- Have you ever made a change to code, realised it was a mistake and wanted to revert back?
- Have you ever had to maintain multiple versions of a product?
- Do you want to prove that a particular change broke or fixed a piece of code?
- Have you ever wanted to review the history of some code?
- Have you ever lost code or had a backup that was too old?
- Have you ever wanted to see how much work is being done, and where, when and by whom?
- Have you ever wanted to submit a change to someone else's code?
- Have you ever wanted to share your code, or let other people work on your code simultaneously?
- Have you ever wanted to experiment with a new feature without interfering with working code?
If you have experienced difficulties due to any of the above condition then that’s an indicator to use Version Control in your project.
Version Control, also known as Revision Control or Source Code Management, is the management of changes to documents, computer programs, websites or other collection of information.
These changes are often identified as numbers or letter code, termed as revision number. Each revision is associated with meta data like timestamp, author(a person who made changes), etc. Revisions can be compared, restored or merged.
Git is the most commonly used version control system. Git tracks the changes you make to files, so you have a record of what has been done, and you can revert to specific versions should you ever need to. Git also makes collaboration easier, allowing changes by multiple people to all be merged into one source.
GitHub is a web-based interface that uses Git, the open source version control software that lets multiple people make separate changes to web pages at the same time. As Carpenter notes, because it allows for real-time collaboration, GitHub encourages teams to work together to build and edit their site content.
- Learners will understand the need of version control system.
- Learners will learn about cloning and forking.
- Learners will be able to create a pull request.
- Get the slides here.
- Repository link
- Fork this repository
- Clone the forked repository
- Choose your preffered language and update the code of the program.
- Create a pull request.
Author Sudip Mondal