Where is the repository stored?

Laptop

A repository is all the files under version control, along with their change history and other service information.

You can create a Git repository either by selecting any folder on your computer or by cloning an existing repository, such as an employer’s.

Where is the repository stored?

There are different ways to store and use a repository: local, centralized, and distributed version control systems.

In localized version control systems, the repository is stored and used on a single device, but only one developer can work with the system. In the case of a centralized system, the repository is stored on a single server.

Distributed version control systems, such as Git, are best suited for a large number of developers. This system is a cloud-based repository: each user stores the entire repository on their device, and as changes occur, the repositories are synchronized.

What is commit and commit?

A Git commit is an operation that takes all prepared changes and sends them to the repository as a whole.

Why commit if Git keeps track of all the changes? Commits break down the development process, which consists of a large number of edits, into individual steps. That is, a commit is a logically completed change within the project and a clear (including to other developers) point to which you can return if there are any problems.

Changes within a single commit are subject to certain rules and guidelines established by the development team regarding the naming, description, and content of commits.

As a rule, the workflow is a cycle: commit – file change – commit.