Skip to content

Git Installation

DevilXD edited this page Nov 10, 2022 · 1 revision

This is a guide explaining how to install Git on your machine. This process is quite complicated, as you'll be presented with many options to choose from. Some of them are crucial in terms of how you want to utilize Git, others are simply personal-preference or experimental things. This guide shows a classic command line installation, but also highlights options that I personally recommend for general development using Git. When noted though, you're free to select other options as well. Just keep in mind some of them may alter your development process later on, so it's best to know what each option really does before selecting it. If you're unsure, just stick to the ones shown here.

Also, a caution note - the Git installer constantly evolves and later editions may include options that are not shown here. You'll have to use your best judgement to deal with those. Usually, just leaving everything as-is works okay.

You can obtain a Git installer here: https://git-scm.com/downloads

It's recommended to launch the installer with Administrator rights, and then perform an all-users installation into the Program Files folder. If you're unable to obtain administrator rights, you may get away with installing Git into a folder in a local profile folder - however, I've never done so, and don't really know how it can differ (or if it's even possible). The rest of this guide assumes you're performing an all-users installation.

Screen1

On the first screen, you'll be presented with the license - just click Next.

Screen2

Second screen will prompt you for an installation path. The default one presented is just fine.

Screen3

Next screen. Here, it's recommended to uncheck the "Windows Explorer integration" option, to avoid cluttering your right-click folder menu. I've literally never had a need to use those, but if you feel like you'd like to for some reason, you can leave those checked. Same goes for a desktop icon, never needed it, you may like it. Checking "Check daily for Git for Windows updates" will allow your Git installation to occasionally prompt you for an update installation confirmation shortly after booting up your PC - this happens only once every few weeks though. If you'd prefer not to receive those, you can leave the option unchecked. Any other option not mentioned here should be set as shown on the picture. Any leftover options not shown on the picture are usually new or experimental ones, and it's recommended not to change their status - regardless if they start checked or unchecked, leave them be like they are.

Screen4

Next screen. Simple - if you, for whatever reason, want to be able to search for and run git from the start menu, you can leave everything as-is. If you're unsure though, I recommend checking the "Don't create a Start Menu folder" option to avoid unnecessary system clutter.

Screen5

Next screen. This one is one of those personal choice ones. Depending on which text editors you have installed on your system, you may see several different options. Some of them should include: Sublime, Atom, Vim, Nano, Wordpad, VSCodium, Notepad, Notepad++ or Visual Studio Code. My personal choice is Visual Studio Code, but Notepad++ is also popular. If you don't have access to either of these nor the other ones listed, selecting Notepad should work as a last resort option. Pick one you know how to work with, and it should do.

Screen6

Another personal choice one. Either of the options is fine, you can stick with the usual "master" branch naming, or choose the recently-suggested "main" naming. If unsure, leave as the picture shows.

Screen7

This one is important. The usual case for Git usage is being able to access it from the command line, hence why you should stick with the 2nd option here. All of the steps of this guide assume this kind of installation. Only use the other options if you have a need for them and you know what you're doing.

Screen8

If you have an external OpenSSH installation, you can use the 3rd option to specify it and avoid having a duplicated install of it. Otherwise, just stick with the 1st option.

Screen9

Never really had any experience with this one. Unless you're sure of a reason to go with the 2nd one, 1st one works perfectly fine here.

Screen10

This is a half personal-preference, half a mandatory thing. The 1st option should be you go-to here, as that's what everyone else expects you to choose. If you know what you're doing, feel free to select a different setting - otherwise, stick to the 1st one please.

Screen11

Purely personal-preference thing. Never really had to use Git Bash, so it doesn't affected me. I prefer simple cmd over installing additional things, hence why I went with the 2nd option. Go with either, stick with 2nd like me if you're unsure.

Screen12

Another personal-preference thing. The 3rd option can be used for people who like to be extremely careful and safe, however it requires extra steps to get where the 1st and 2nd option will normally take you on their own. The default 1st fast-forward or merge is perfectly fine. If you're one of those people who prefer clean commit history and no merge commits, 2nd option is just as good. I'm still split between using either first or the second, but ultimately ended up using the first one for now. Pick either, stick with the 1st if unsure.

Screen13

Recommended to keep this one enabled, for easy Github integration and management of whatever projects you might be interfacing with later on.

Screen14

Always left those at default as the picture shows. Performance boost sounds good, and never had to use symbolic links on a serious scale. 'nuf said.

Screen15

The file system watcher offers a performance boost, hence why I checked it. You can do it too, but don't have to, these features are experimental after all. Do what you want here.

Screen16

That's it! 15 screens full of options later, Git is finally installing! You made it, Congratulations! Seriously though, this is probably the most option-rich installer for a small application I've ever seen, and if you did everything correctly, you should have a working git available from the console anywhere you go from now on. Assuming your PATH variable is updated first, of course - for that, see below.

Screen17

Uncheck both and click on "Finish" to finish the installation =)

Final note

As the installer alters the PATH variable, an explorer.exe process restart is required for these changes to take an effect. You can do so from the Task Manager if you know how, but otherwise, a simple computer reboot/restart works just fine for this purpose. Make sure you don't want to install any other software that'd alter the PATH variable (such as Python) beforehand, to avoid having to repeat this procedure.

Clone this wiki locally