Version Control System (VCS):
So What is a vcs? Before jumping into the GitHub markdown files let's understand the term vcs i.e version control system. Version control systems are used to track the code progress of our projects. It tracks every single minor or major changes made. This helps the team which is working on a project to collaborate easily and work together effectively. It is convenient for the Developers as they can revert/go back to an earlier version of the code if any mistake is made by the team while development. Without Vcs it would become troublesome as the team wouldn't know about which code is modified or added and there are also great chances of loosing the source code.
What is GIT & GITHUB:
Now here git comes into play. Git is basically a popular distributed VCS i.e Version Control System which is used in software development. In simpe terms GIT is like a book keeping mechanism where you keep records of what changes have been done on top of each other so that you can remove those changes and go back to the previous program. Linus Torwalds developed it in 2005. Github is used as a code hosting platform to put the code out on web. Git and github are two different things Lets simply understand this with a small eg.
So as we can consider our photos gallery on our phone as Git as both are installed locally on our system. And keep our GoogleCloudphotos as Github as github is hosted on the web. It is cloud-based. Git is used mainly for code sharing whereas GitHub's prime intention is source code hosting i.e hosting repos.
Now what is a Git repo or repository? Repositories are simply collection of files and in these we have different versions of our source code/project.
Now how to create a repository ?
First you need to have a GitHub Account. In the upper-right corner of any page, use the
+
drop-down menu, and select New repository.Now give a short and meaningful name to your repository. And you can also provide a short description of your project.
You can restrict who has access to a repository by choosing a repository's visibility: public or private.
Select Initialize this repository with a README. And then click on the green button saying 'Create Repository'.
Yey! You have successfully created your first repository, and initialized it with a README file.
README.md:
Readme.md
is basically a simple plain text file which has a summary of what's there in the Github project repository. It contains information that is commonly required to understand what the project is about. md
here stands for Markdown. Markdown is a markup language with plain text formatting syntax.
We will now checkout the syntax of writing a readme file.
# - used for H1
## - used for H2
### - used for H3
This continues as H4, H5 till H6 . For writing h6 we use 6hash.
_Batch_
- used for itallic o/p:batch**Batch**
- used for bold or strong. o/p: batch~~99~~
- used as strikethrough. o/p:99Link and image
`highlight` -
the backtick is used to highlight the words.
By using this ``` big code``` we can write multiple lines of code. We can even specify the language for the code written for eg.
``` javascript
let a=100;```
>Quotes -
' > ' is used for quotes.
Tables -
List - list can be created by only naming 1. for the first list item and by hitting the tab the further numbers are generated automatically. Even if we mistake the numbers it automatically gets corrected eg. this list of readme syntax. We can also make sub-list under a list by the same technique.
Badges:
In the form of badges, we are provided with more information, but it comes in a graphical format. Sheilds.co
website produces these kind of badges. It has a label, a message and colour to pick. We need to give these inputs and then click on 'Make Badge' to create a badge.
Now badge gets Created.
Now after creating the badge we need to copy this link and come to readme.md
file.
Moreover, the same process is followed for inserting the badge as we do for inserting an image.
Syntax for the badge :
![](badge link)
Conclusion:
So now we have finally had an overview on what is a Vcs and git and github.We saw how to create a new repository. We also learned about what exactly a readme.md file
is and the Markdown syntax used.
Happy Learning!