1

I've been trying to make a commit with my progress using a Terminal. I am relatively new to all that stuff around Git, but following a step-by-step tutorial on GitLab I initialised a Git Repository, added my files to the staging area. From now on all I can see is that (See picture).

I even updated Git on my Mac. Initially, I was using Git that comes preinstalled on every Mac in Terminal. I want to avoid using a graphical programs.

enter image description here

mkrieger1
  • 19,194
  • 5
  • 54
  • 65
  • It looks like you've enabled commit signing without having gpg installed. Did you intend to enable this? – Lasse V. Karlsen May 14 '18 at 18:49
  • What does `git status` tell you? – Daniel R. May 14 '18 at 18:49
  • @LasseVågsætherKarlsen I didn't. I have no idea what's going on tbh. :D –  May 14 '18 at 18:51
  • 1
    Seems an error of gpg. See here https://stackoverflow.com/questions/36941533/git-hub-desktop-on-mac-error-cannot-run-gpg-no-such-file-or-directory – Yuvraj Jaiswal May 14 '18 at 18:51
  • If you don't want to have gpg commit signing enabled you can turn it off with `git config --global commit.gpgsign false` – Lasse V. Karlsen May 14 '18 at 18:52
  • 2
    Possible duplicate of [Git Hub Desktop on Mac, error: cannot run gpg: No such file or directory](https://stackoverflow.com/questions/36941533/git-hub-desktop-on-mac-error-cannot-run-gpg-no-such-file-or-directory) – Alejandro May 14 '18 at 18:54
  • @LasseVågsætherKarlsen thank you. It's working now. –  May 14 '18 at 18:54

1 Answers1

2

You have config.gpgsign set. This means Git will try to cryptographically sign every commit you make with Gnu Privacy Guard which you don't appear to have installed.

This is not necessary to use Git except in certain special circumstances, so it's probably best to turn it off for now.

You can find out where it's set with git config --show-origin commit.gpgsign. You should see something like this.

$ git config --show-origin commit.gpgsign
file:/Users/schwern/.gitconfig  true

If it's in your own global .gitconfig like above, turn it off.

$ git config --global commit.gpgsign false

If it's in the project itself, contact the project and ask if they really require every commit to be signed. If they do, you can install GnuPG on a Mac with GPG Suite and follow their instructions.

Schwern
  • 153,029
  • 25
  • 195
  • 336