Git Product home page Git Product logo

Comments (5)

GoogleCodeExporter avatar GoogleCodeExporter commented on July 22, 2024
Hmm, but Git is a DVCS, how can I know that you didn't do some sort of crazy 
merge or backing-out or switching branches, etc.?

Original comment by [email protected] on 25 Apr 2011 at 5:30

from bugzilla-vcs.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 22, 2024
This is what I did:

mkdir test
cd test
git init
touch test.txt
git add .
git commit -m"one"
git log
echo "First line of code" >> test.txt
git add .
git commit -m"two"
git log
git branch crazy
git checkout crazy
echo "Second line of code" >> test.txt
git add .
git commit -m"crazy one"
git log
git log 46ba136687..           {this is commit "one"}
git checkout master
git merge --no-ff crazy
git log
git log 46ba136687..           {this is commit "one"}


The log shows info as expected.
I didn't test any "crazy" stuff. Limited knowledge of git :(.

Original comment by [email protected] on 25 Apr 2011 at 5:53

from bugzilla-vcs.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 22, 2024
Oh, no, I wasn't accusing you of doing crazy stuff. I was saying in general, I 
need to rescan the whole repository, because I can't know what the user has 
done with it.

Original comment by [email protected] on 26 Apr 2011 at 5:27

from bugzilla-vcs.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 22, 2024
I understand and I didn't think you accused me of anything :)

What I tried to demonstrate is that when you branch and merge, "git log from.." 
will show the comments from withing the branch as well.

The only problem I see (with my limited knowledge of git) is when you have 
stored commit id 46ba136687 in DB and someone removed that commit from the 
repo. In that case "git log 46ba136687.." will tell you that such commit 
doesn't exist and I guess will return -1 which would trigger full scan?

Original comment by [email protected] on 26 Apr 2011 at 6:00

from bugzilla-vcs.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 22, 2024
Ah, it's actually worse than that. You could change the HEAD pointer to point 
to another branch with an identical commit at the top but different commits 
underneath it.

Original comment by [email protected] on 27 Apr 2011 at 7:21

from bugzilla-vcs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.