How does Git differ from other version control systems?
Hi there!
Storing information
CVS, Subversion, Perforce, and other centralized platforms store information as a changelog for files. In contrast, Git considers data to be a set of casts of a small file system.
The principle of data storage in Git
The principle of storing data in other systems
Among other features:
- unlike centralized systems, Git uses only local files and resources for most operations, which makes it possible to work without network access;
- before saving the file, Git calculates the checksum using the SHA-1 hash, and it becomes its index.
How to use it?
Firstly, you need to install Git, then configure it. Specify:
-
user name:
$ git config --global user.name "ra1nbow"
; -
email address:
$ git config --global user.email ra1nbow@example.com;
-
a text editor to work with. For example, if the standard editor does not suit you and you chose Emacs:
$ git config --global core.editor emacs
; -
built-in comparison utility. For example, if you want to use vimdiff
$ git config --global merge.tool vimdiff
. Then check the settings:git config --list
.
How to work with code?
Use the services for project hosting and collaborative development. They usually have access control, bug tracking, task management, a wiki for each project, and a developed community where you can ask for advice.
Among the most popular platforms:
- GitHub;
- Gitlab;
- Bitbucket;
- Gogs;
- SourceForge.
What to learn next?
- Working with repositories: creating, recording changes, viewing commit history, undoing changes, working with remote repositories and tags.
- Branching and merging.
- Git on the server: configuration, working with protocols, generating a public SSH key, GitWeb, Gitosis, Gitolite, Git daemon, Git hosting.
- Git tools.
Where to learn?
- Git Documentation;
- Git Handbook;
- Codecademy
- by thee way, ask me if anything
A little interactive:
- site with search for any shell commands, including Git commands.
I learned everything, what's next?
When you have mastered the basic operations:
- take the tests;
- learn the site with Git exercises;
- Learn the Git encyclopedia: there are guides, cheat sheets and a community where you can ask questions.
Hope you enjoyed my post! Follow my Github <3
Top comments (1)
Make sure also to check out this open-source eBook. It has everything that you need to get started and is not too overwhelming for beginners:
bobbyiliev / introduction-to-git-and-github-ebook
Free Introduction to Git and GitHub eBook
This is an open-source introduction to Git and GitHub guide that will help you learn the basics of version control and start using Git for your SysOps, DevOps, and Dev projects. No matter if you are a DevOps/SysOps engineer, developer, or just a Linux enthusiast, you can use Git to track your code changes and collaborate with other members of your team or open source maintainers.
The guide is suitable for anyone working as a developer, system administrator, or a DevOps engineer and wants to learn the basics of Git, GitHub and version control in general.
To download a copy of the ebook use one of the following links:
Dark mode
Light mode