Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6822011
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T21:36:46+00:00 2026-05-26T21:36:46+00:00

I just started learning Git and to do so, I started reading the Git

  • 0

I just started learning Git and to do so, I started reading the Git Community Book, and in this book they say that SVN and CVS store the difference between files and that Git stores a snapshot of all the files.

But I didn’t really get what they mean by snapshot. Does Git really make a copy of all the files in each commit? Because that’s what I understood from their explanation.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T21:36:46+00:00Added an answer on May 26, 2026 at 9:36 pm

    Git does include for each commit a full copy of all the files, except that, for the content already present in the Git repo, the snapshot will simply point to said content rather than duplicate it.
    That also means that several files with the same content are stored only once.

    So a snapshot is basically a commit, referring to the content of a directory structure.

    Some good references are:

    • git.github.io/git-reference

    You tell Git you want to save a snapshot of your project with the git commit command and it basically records a manifest of what all of the files in your project look like at that point

    • 2020: "A commit in Git: Is it a snapshot/state/image or is it a change/diff/patch/delta?"
    • git immersion

    Lab 12 illustrates how to get previous snapshots

    • "You could have invented git (and maybe you already have!)"

    • What is a git “Snapshot”?

    • Learn GitHub


    The progit book has the more comprehensive description of a snapshot:

    The major difference between Git and any other VCS (Subversion and friends included) is the way Git thinks about its data.
    Conceptually, most other systems store information as a list of file-based changes. These systems (CVS, Subversion, Perforce, Bazaar, and so on) think of the information they keep as a set of files and the changes made to each file over time

    delta-based VCS

    Git doesn’t think of or store its data this way. Instead, Git thinks of its data more like a set of snapshots of a mini filesystem.
    Every time you commit, or save the state of your project in Git, it basically takes a picture of what all your files look like at that moment and stores a reference to that snapshot.
    To be efficient, if files have not changed, Git doesn’t store the file again—just a link to the previous identical file it has already stored.
    Git thinks about its data more like as below:

    snapshot-based VCS

    This is an important distinction between Git and nearly all other VCSs. It makes Git reconsider almost every aspect of version control that most other systems copied from the previous generation. This makes Git more like a mini filesystem with some incredibly powerful tools built on top of it, rather than simply a VCS.

    See also:

    • "If git functions off of snapshots of files, why doesn’t .git/ become huge over time?"
    • "What information is stored as each git commit’s tree object content"

    Jan Hudec adds this important comment:

    While that’s true and important on the conceptual level, it is NOT true at the storage level.
    Git does use deltas for storage.
    Not only that, but it’s more efficient in it than any other system. Because it does not keep per-file history, when it wants to do delta compression, it takes each blob, selects some blobs that are likely to be similar (using heuristics that includes the closest approximation of previous version and some others), tries to generate the deltas and picks the smallest one. This way it can (often, depends on the heuristics) take advantage of other similar files or older versions that are more similar than the previous. The "pack window" parameter allows trading performance for delta compression quality. The default (10) generally gives decent results, but when space is limited or to speed up network transfers, git gc --aggressive uses value 250, which makes it run very slow, but provide extra compression for history data.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've just started learning Git, and the tutorial I'm using says that when cloning
I just started learning C but I don't understand this part of the code.
I've just started learning linq and lambda expressions, and they seem to be a
Just started learning Groovy, got the PragProg book Programming Groovy and had a problem
I just started learning Python... I am writing a simple program that will take
I just started learning C++ couple of weeks ago. So now I have this
I just started learning C++ and I wrote this sample program from the text
Just started learning Haskell. I have an empty source file with this inside: pe
I just started learning some ruby, and I want to do something like this:
I just started learning swing, and couldn't find any clear instructions for this: I'd

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.