 Hi, I'm Chantastic and you're joining us for day two of a series on Vim, a very entry-level series that I'm calling Vim Alphabet because we're going from A to Z with the exception of quit I want to make sure that you know how to get in and out of Vim without any trouble before we start anything else Now if you have a Mac, you can open up a terminal I'm gonna be using the just default built-in terminal and Typing in the word Vim now all of this is Pre-configured on your Mac. It might be a later version or earlier version But you should have Vim ready to go if you open up a terminal now on other systems I really don't know I think like Linux and Linux might have vi which is like a Precursor to Vim you might need to install it with app get or however you get applications And I don't know at all how you would do it on Windows So I'm gonna assume that if you're using Windows you haven't figured out and you're already at the stage where you can open Vim we've opened Vim and one thing that I always thought was particularly Hilarious is that people have a hard time getting out of them because right up front when you open Vim by itself It gives you this thing that says right up front. This is how you exit Vim you type colon q enter That's how you exit and if you need help you say colon help Enter that'll take you the help, but you can also do a term so Anyway, that is how you navigate your way into learning Vim So we're just gonna start with colon q enter great. We got in and out of Vim awesome We've already learned what we wanted to learn today now. You can also get into Vim and Open a new file. So if we give it a file name It's going to create a buffer for a new file for us and we can say Hello, how are you today? Now? You'll note that I had to change modes to go into insert mode in order to type this text now We'll cover that in the next lesson how to enter insert mode But today I just wanted to put some text in there to show you some other options for quitting So I'm back in command mode. Now if I try to do colon q It's going to give me an error. It says no right since last change add Bang to override or the exclamation point if I want to leave Vim I have to assert that I do not want to save these changes to this new file And I can do that and we can see that if we type Vim test MD again It's going to be as if we create a new file because the last one never saved so Multipe I'm doing great again. I have to go to insert mode Now this time I do want to save this into test So I'm going to use another Vim command called right quit or WQ That's for right and then quit now that will save my test md file I can look at that. I'm doing great perfect So if you've ever tried to add something that's not gonna work get add And then get commit You see this you're like where the heck am I and I want to get out and I don't want to do any of this I want to abort well You colon Q bang and that's gonna get you out without having committed anything. Okay, so let's say you want to do that again I commit it takes you into this commit screen Commit the thing now. We do want to save it. So we're gonna say colon WQ for right right Right quit so we're gonna write and then we're gonna quit okay now that may that commit so Q exclamation point or Q bang is on the way to get out without making the change and Right quit is how you exit with making the change. I want to show you one last thing Let's just open Vim if we ever have questions about what we can do with quit We can use this help command so we can type in the whole world word help or we can just type in H as a shorthand And we can say quit so I want the help documentation on quit Now you can navigate this with your arrows You'll learn how to do that in a more Vim way soon, but you can navigate this with arrows, too So we can see that we do Q bang or we can optionally type in the Quit word as a whole and bang and that'll still work We saw there's a WQ which we learned about and WQ bang So there's tons of ways to quit Vim And if we want to quit this little pop-up display get back to our file And again quit so explore how to quit Vim explore how to get in and out of Vim You can open multiple files, which I will leave that as an exercise to you So yeah, have fun getting in and out of Vim tomorrow. We will start with the letter a Don't know if that's the right Direction for you, but a is the letter we're gonna start with see you tomorrow