Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to fetch the old code from git repository

I think this is the simplest question but i am very first to the git . So can you please any body help me out. That is how to fetch the old code from the git repository and how to get the old code from the local(git repo in on my machine) repository

like image 662
neotam Avatar asked Oct 22 '25 21:10

neotam


1 Answers

With git, you always have a copy of the complete repository including the history.

First, clone your repository:

git clone <repo_url>

Then checkout the old commit

git checkout <commit>
like image 91
Daniel Hepper Avatar answered Oct 24 '25 11:10

Daniel Hepper



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!