revision-history

Go to particular revision

为君一笑 提交于 2019-11-26 06:52:46
问题 I cloned a git repository of a certain project. Can I turn the files to the initial state and when I review the files go to revision 2, 3, 4 ... most recent? I\'d like to have an overview of how the project was evolving. 回答1: Use git checkout <sha1> to check out a particular commit. 回答2: To go to a particular version/commit run following commands. HASH-CODE you can get from git log --oneline -n 10 git reset --hard HASH-CODE Note - After reset to particular version/commit you can run git pull

Create a submodule repository from a folder and keep its git commit history

天大地大妈咪最大 提交于 2019-11-26 05:57:09
问题 I have a web application that explores other web applications in a particular way. It contains some web demos in a demos folder and one of the demo should now have it\'s own repository. I would like to create a separate repository for this demo application and make it a subpackage submodule from main repository without loosing its commit history. Is it possible to keep the commit history from the files in a repository\'s folder and create a repository from it and use it as a submodule instead

What is the Git equivalent for revision number?

ε祈祈猫儿з 提交于 2019-11-26 04:29:44
问题 We use SVN at work, but for my personal projects I decided to use Git. So I installed Git yesterday, and I wonder what is the revision number equivalent in Git . Let\'s say we work on version 3.0.8 and every bug fix has its own revision number we can use when we talk about this bug fix. So if I tag the code in Git to 3.0.8 what then I can use as a revision number or some other more detailed kind of identification? I find the hash not so user friendly for humans. 回答1: Good or bad news for you,