Tech Junkie Blog - Real World Tutorials, Happy Coding!: git & github : Setup User Name And Git Editor

Tuesday, September 28, 2021

git & github : Setup User Name And Git Editor

In the previous post we installed Git on Windows.  On this post we are going to set up Git with our user name and assign Bracks as our Git editor so that we don't have to edit git through the command line console all the time.

Here are the steps to setup your user name and editor for git:

1. First let's set our user name, with the command git config --global user.name "Your name goes here"









You can also set your e-mail with the command git config --global user.email "Your e-mail goes here"

2. When you want to add your favorite text editor in the environment variables "Path", in my case it's brackets





































3. Create a folder call git and go into it in the command line, this will be your git sandbox sort of speak.  Now run this command git init this will create an initial .git repository so that you won't run into an issue when you assign an editor to git

4. Run the command git config core.editor "brackets --multiInst -nosession" this command will open up the text editor that you assigned every time you want to edit a resource in git, in a new instance


5. Now let's test it out by editing the .gitconfig file with this command git config --edit --global














the file should be opened in the text editor that you assigned









Previous: Installing Git For Windows

No comments:

Post a Comment

Search This Blog