Git is the most popular version control system out there and for good reason. In this video, we’ll go over the basics of what git is and how to use it within the command-line. There are several GUI tools out there to help you get started with git, but it can be extremely beneficial to learn git from the command-line as early as possible.

Some of the images used in this video are from the “Pro Git” book. These are licensed under creative-commons. You can find the book at:

✅ Support My Channel Through Patreon:

✅ Become a Channel Member:

✅ One-Time Contribution Through PayPal:

✅ Cryptocurrency Donations:
Bitcoin Wallet – 3MPH8oY2EAgbLVy7RBMinwcBntggi7qeG3
Ethereum Wallet – 0x151649418616068fB46C3598083817101d3bCD33
Litecoin Wallet – MPvEBY5fxGkmPQgocfJbxP6EmTo5UUXMot

✅ Corey’s Public Amazon Wishlist

✅ Equipment I Use and Books I Recommend:

▶️ You Can Find Me On:
My Website –
My Second Channel –
Facebook –
Twitter –
Instagram –

#Git

Nguồn: https://codeigniterbrasil.com

Xem thêm bài viết khác: https://codeigniterbrasil.com/lap-trinh-linux/

35 Comments

Jonathan C. Soares

April 16, 2020

well explained. thanks from brazil!

Reply

Conor Tobin

April 16, 2020

Would I be correct to assume that cloning a repository automatically adds a .git file to that cloned set of files on your local machine? Or was that one that you added yourself, when working on it prior to cloning?

Reply

krishna kumar

April 16, 2020

Thanks a lot Corey for this crisp and clear introduction to Git! Was really helpful to get me started 🙂

Reply

neeraj sharma

April 16, 2020

this comment is for those who are looking for best content available in youtube for coding: only few channels are here who really have great content one is corey schafer and other is sentdex both of you guys are awesome. You both have taught me alot. Thanks, sir.

Reply

rahul chilupuri

April 16, 2020

I get this error after the command : git push origin master

remote: error: refusing to update checked out branch: refs/heads/master
remote: error: By default, updating the current branch in a non-bare repository
remote: is denied, because it will make the index and work tree inconsistent
remote: with what you pushed, and will require 'git reset –hard' to match
remote: the work tree to HEAD.
remote:
remote: You can set the 'receive.denyCurrentBranch' configuration variable
remote: to 'ignore' or 'warn' in the remote repository to allow pushing into
remote: its current branch; however, this is not recommended unless you
remote: arranged to update its work tree to match what you pushed in some
remote: other way.
remote:
remote: To squelch this message and still keep the default behaviour, set
remote: 'receive.denyCurrentBranch' configuration variable to 'refuse'.
To /home/rahul/Desktop/GitBasics/Cloned-repo/../remote_repo.git
! [remote rejected] master -> master (branch is currently checked out)
error: failed to push some refs to '/home/rahul/Desktop/GitBasics/Cloned-repo/../remote_repo.git'

Reply

Taahir khan

April 16, 2020

Great video there. There's this one thing that I didn't understand. Assuming, I started to edit a piece of code in a file and completed it. I am ready to push this code to the server but, as it turns out my friend edited another piece of code in the same file that I was working on and pushed the changes to the remote repository. If I did "git pull" now, will the changes I made be gone because I started working on the code before someone changed it. Is there a way to keep my changes but also the changes made by the other person? And if it's by branching, wouldn't merging the branch cause the same problem?

Reply

david tang

April 16, 2020

how you create remote_repo.git file and what is the content?

Reply

SKTTWkartrider

April 16, 2020

I am wondering how to enable the hover window preview on Dock…. Any one knows?

Reply

S. T. JIANG

April 16, 2020

Very helpful Corey! Thanks

Reply

Hari Thapliyal

April 16, 2020

I would recommend this as a shortest video to learn git. Thank you so much for this work.

Reply

Kotel TV

April 16, 2020

how did you get your terminal window to look like that? mine has all green letters on a black background

Reply

Jatin Chhabra

April 16, 2020

Thanks Coery, Watched your video as it was part of The Odin Project. Will be true here, not got the whole ideo, especially Brand, but have bookmarked it and when the time comes that I will use GIT, this video will be very useful.

Reply

thanh nguyen

April 16, 2020

Thanks for a really useful tut. Could you make one for gitlab?

Reply

Ishan Pandey

April 16, 2020

Sir, just one question how do you make it so easy to understand????? You're super awesome.

Reply

Reema Aladham

April 16, 2020

Awesome easy explanation. Cheers

Reply

Abhijeet Bodas

April 16, 2020

With " learn X in Y minutes" kind of tutorials getting millions of views these days, its great to see this no-nonsense, content-first channel. Good job! Keep it up!

Reply

Ivan Popov

April 16, 2020

I nominate this video for The-Most-Important-Video-on-the-Internet … award? No – not award – just staus … like in status-quo. This is the best-concentrated piece of knowledge I've seen on the subject matter for the past several years. And even if it could be divided into several parts (for the newcomers mostly), it's still introductory enough for any person who uses a computer and in some sense works with files (documents-in-motion) …

Reply

Kshitij Jain

April 16, 2020

Thanks! This was really helpful.
One thing you can do is pull up GitHub. I tried to push it but it showed that I did not have a remote repo selected so I had to go and make a repo and copy its URL to my terminal. Some people might run into the same problem

Reply

Peter Torres

April 16, 2020

3+ years later this video is still super helpful. Thank you very much!

Reply

Pace De La Cruz

April 16, 2020

Second question: I'm lazy and it's why I'm a developer. Wouldn't there be a way to create a gui where we'd just enter the altered file and where a batch file would do the rest for us? The get this, get that, pull this, pull that?? Seriously. This looks like it's an unbelievable waste of time.

Reply

Pace De La Cruz

April 16, 2020

Question (but first, thank you for this video)

Why would we delete the branch from the master? Wouldn't that delete all the updates we'd done to given files? What did I misunderstand?

I got the rest of it, very straight forward and very well presented, thank you yet again.

Reply

Kurmi Yadla

April 16, 2020

excellent tutorial for git! Thanks !

Reply

Yannick Labrie

April 16, 2020

vraiment excellente vidéo la traduction française serait bien tout de même!!

Reply

FoolProof Dude

April 16, 2020

Dude, to be honest this is the best video that explained the concepts very clearly. I was having hard time to understand the git and how to work with it. But this tutorial made things clear for me. Thanks a lot for this.

Reply

Mahesh Bhaske

April 16, 2020

thanxxxxx……. man it ws very useful

Reply

Hyller Vianna

April 16, 2020

Thanks for that!

Reply

Ultimate Technology

April 16, 2020

wow! what a fantastic presentation and a full of information about git.

Reply

vishal singh

April 16, 2020

thank you man!

Reply

Abhinav Jain

April 16, 2020

Best git video on the internet….

Reply

web全栈之路

April 16, 2020

git from entry to master: https://www.youtube.com/watch?v=gUgGmETun8E&feature=youtu.be

Reply

Marilena Souza Da Silva

April 16, 2020

Very useful tutorial. Thank you so much!

Reply

Brian Evans

April 16, 2020

git clone https://YouTube.com
git add video.mp4
git commit -m "uploaded video"
git push -v origin master

Reply

Jack Seibert

April 16, 2020

best git tutorial i have seen

Reply

John Wasula

April 16, 2020

Great introduction video!

Reply

Alessandro Rezzi

April 16, 2020

Nice video I saw it

Reply

Leave a Reply