LC101- Ind - 22.6.1 Exercises: Git - Working in Local Directory - how to run get config to tell who you are

Problem: When attempting first commit Step 4 GitBash terminal states: Author identity unknown ***Please tell me who you are… fatal: unable to auto-detect email address (got ‘ebbie@DESKTOP-8R633NI.(none)’). A portion of the email address verbiage is what appeared on my GitBash prompt line when I did the CH 19.5 Exercises: Terminal and is appearing again in below Visual Studio Code cut/paste on GitBash terminal prompt line. How do I run git config (per below cut/paste) to set my account’s default identity? I have completed thru Step 3 and it appears exercises.txt is a new file ready to commit. Did anyone else get this? Please help.
I cannot get screen shot from Visual Studio Code - here’s copy/paste:
ebbie@DESKTOP-8R633NI MINGW64 ~/Documents/LC101/Git_Exercises (master)
$ git status
On branch master
No commits yet
Changes to be committed:
(use “git rm --cached …” to unstage)
new file: exercises.txt
ebbie@DESKTOP-8R633NI MINGW64 ~/Documents/LC101/Git_Exercises (master)
$ git commit -m “Commit local change set-up exerdcises.txt file”
Author identity unknown
*** Please tell me who you are.
Run
git config --global user.email “you@example.com
git config --global user.name “Your Name”
to set your account’s default identity.
Omit --global to set the identity only in this repository.
fatal: unable to auto-detect email address (got ‘ebbie@DESKTOP-8R633NI.(none)’)

You need to config your git account on your computer so it knows to attribute the commits to you.
Type both commands with the required info:
git config --global user.email type your email here
git config --global user.name type your name here

then you can go back to your commits. You can add whatever info you want, that’s up to you. You also don’t have to make it global you can just add this info for this project only but it’ll ask you again on the next.
I am pretty sure that’s what it means & I had this experience too.

1 Like

@StephNau - thanks much! I believe this will happen to many…appreciated.
Save too All - don’t forget to save the Hello World! change (File>Save) you make to exercises.txt (@ 1) in the console (vs. terminal); this then enables you to commit your local change (in the terminal) using the git commit procedures.

1 Like