0

I am trying to upload an HTML file for a Github repository. I am trying to commit using Visual Studio Code's GUI.

I wil explain what I have done so far.

  1. Created a Git repository. i.e. PHP_Development
  2. Repository URL. https://github.com/ChiranthakaJ/PHP_Development.git
  3. Added the folder in my PC where my source codes are located. i.e. D:\MyDev\PHP-Dev
  4. Added a remote repository location named 'MyPHPDev'& added the repository URL as for the remote location.
  5. Then I tried to do the initial commit using CTRL + ENTER key combination. Unfortunately it didn't go as planned and instead I got an error like the below screenshot.

    enter image description here

  6. Then I did a small edit to the same file and tried to commit again and got the same error message as the above.

    1. However the 'Stage changes' were captured properly. Please refer the below screenshot as well.

enter image description here

  1. Please refer the screenshot of the 'Git Log'.

enter image description here

I can't understand what I have done wrong here?

Please help me.

Thanks and regards, Chiranthaka

4
  • 1
    It looks like you've turned on commit signing somewhere, commit -S. Have you done that deliberately? There's also a config option "commit.gpgsign" - can you check you don't have that set as a local or global config option in git? Commented Feb 20, 2020 at 19:06
  • 2
    it's funny, you spent a lot of time to brush out the email on the picture, but forgot it in the log. Commented Feb 20, 2020 at 20:29
  • @Rup I have checked the repository's Master branch and the 'Require igned commits' is diabled. Then what would be the cause for this error? Commented Mar 7, 2020 at 10:13
  • I think it's something in your client side configuration, not set on the server. (If it was server configuration then you'd be able to commit OK but it would reject a push that contained unsigned commits.) In Visual Studio try Team Explorer, Project Settings, Repository Settings, Other and look for commit.gpgsign = true Commented Mar 8, 2020 at 10:52

1 Answer 1

1

You gotta tell the git client about the GPG key that you are using. Either commit the change manually by CLI without signing the commit using the command

git commit 

You can setup the GPG keys and try again. For more info on how to setup the GPG keys, you can visit Here

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.