git: 'credential-osxkeychain' is not a git command. See 'git --help'.

2,041 views
Skip to first unread message

Shannon Pekary

unread,
May 17, 2016, 3:48:16 AM5/17/16
to SmartGit
I get this error whenever I push. Pulling is working fine.

Also, I do not get this error when I execute from the command line. Pushing from the command line is working fine, and executing the command that smartgit says it is executing when doing the push is also working fine from the command line.

Git version 2.8.1
SmarGit v7.1.3 #6119

syntevo Support

unread,
May 17, 2016, 4:34:36 AM5/17/16
to smar...@googlegroups.com
> I get this error whenever I push. Pulling is working fine.

In your ~/.gitconfig there should be some configuration like:

credential.helper=credential-osxkeychain

Please locate credential-osxkeychain executable on your machine and make sure that it's on the PATH which SmartGit is using. You may check log.txt in the settings directory (see About dialog) immediately after starting SmartGit for the environment variables it was started with.

--
Best regards,
Marc Strapetz
syntevo GmbH
http://www.syntevo.com
> --
> You received this message because you are subscribed to the Google Groups
> "SmartGit" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
> smartgit+u...@googlegroups.com.
> To post to this group, send email to smar...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/smartgit/5f5494db-dc99-464b-b1a6-d65e8ef85a91%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

Shannon Pekary

unread,
May 17, 2016, 10:29:01 AM5/17/16
to SmartGit
Additional note: This appears to be a github problem. Gitlab is working fine for me.

in .gitconfig, I have:

[credential]

        helper = osxkeychain


I do not have a credential-osxkeychain. Instead its git-credential-osxkeychain. in the /usr/local/bin directory. This I believe was installed by the very latest git mac os x installer.


I do not see anything in the log.txt file that relates to the shell environment itself. Here is the log.txt that is generated around the command that is failing.


30261781 (2016-05-17 07:23:23,987) [WorkerThread-1] INFO                q.exec  - Executing #32 [/Sites/home/qcubed/vendor/qcubed/framework] /usr/local/git/bin/git push --porcelain --progress --recurse-submodules=check github refs/heads/feature-AjaxFiles:refs/heads/feature-AjaxFiles

30262344 (2016-05-17 07:23:24,550) [QThreadPoolThread-6 (stderr-#32 /usr/local/git/bin/git push --porcelain --progress --recurse-submodules=check github refs/heads/feat)] INFO  smartgit.command.logging  - stderr: git: 'credential-osxkeychain' is not a git command. See 'git --help'.

30262352 (2016-05-17 07:23:24,558) [QThreadPoolThread-6 (stderr-#32 /usr/local/git/bin/git push --porcelain --progress --recurse-submodules=check github refs/heads/feat)] INFO  smartgit.command.logging  - stderr: git: 'credential-osxkeychain' is not a git command. See 'git --help'.

30262474 (2016-05-17 07:23:24,680) [QThreadPoolThread-2 (smartgit.aVX)] INFO       smartgit.server  - Received command 'get-http-credentials'

30262475 (2016-05-17 07:23:24,681) [QThreadPoolThread-2 (smartgit.aVX)] INFO       smartgit.server  -   params: id=1554002987743444725;remoteId=https://github.com/spekary/qcubed.git;username=<unset>

30262476 (2016-05-17 07:23:24,682) [QThreadPoolThread-2 (smartgit.aVX)] INFO         smartgit.http  - Authenticating at https://github.com/spekary/qcubed.git using auto-generated credentials

30262604 (2016-05-17 07:23:24,810) [QThreadPoolThread-2 (smartgit.aVX)] INFO       smartgit.server  - Received command 'get-http-credentials'

30262604 (2016-05-17 07:23:24,810) [QThreadPoolThread-2 (smartgit.aVX)] INFO       smartgit.server  -   params: id=1554002987743444725;remoteId=https://github.com/spekary/qcubed.git;username=<unset>

30262605 (2016-05-17 07:23:24,811) [QThreadPoolThread-2 (smartgit.aVX)] INFO         smartgit.http  - Authenticating at https://github.com/spekary/qcubed.git using auto-generated credentials

30263113 (2016-05-17 07:23:25,319) [QThreadPoolThread-6 (stderr-#32 /usr/local/git/bin/git push --porcelain --progress --recurse-submodules=check github refs/heads/feat)] INFO  smartgit.command.logging  - stderr: git: 'credential-osxkeychain' is not a git command. See 'git --help'.

30263120 (2016-05-17 07:23:25,326) [QThreadPoolThread-6 (stderr-#32 /usr/local/git/bin/git push --porcelain --progress --recurse-submodules=check github refs/heads/feat)] INFO  smartgit.command.logging  - stderr: git: 'credential-osxkeychain' is not a git command. See 'git --help'.

30263120 (2016-05-17 07:23:25,326) [QThreadPoolThread-6 (stderr-#32 /usr/local/git/bin/git push --porcelain --progress --recurse-submodules=check github refs/heads/feat)] INFO  smartgit.command.logging  - stderr: remote: Anonymous access to spekary/qcubed.git denied.

30263121 (2016-05-17 07:23:25,327) [QThreadPoolThread-6 (stderr-#32 /usr/local/git/bin/git push --porcelain --progress --recurse-submodules=check github refs/heads/feat)] INFO  smartgit.command.logging  - stderr: fatal: Authentication failed for 'https://github.com/spekary/qcubed.git/'

30263122 (2016-05-17 07:23:25,328) [WorkerThread-1] ERROR     smartgit.command  - Authentication failed for 'https://github.com/spekary/qcubed.git/'

smartgit.ff: Authentication failed for 'https://github.com/spekary/qcubed.git/'


I can't tell exactly, but my guess is that after it fails with OS X-credentials, it then tries to use credentials it stores. And it is not using the user name in the smartgit settings for the user name.

syntevo Support

unread,
May 18, 2016, 7:24:57 AM5/18/16
to smar...@googlegroups.com
> I do not have a credential-osxkeychain. Instead its git-credential-osxkeychain.

I see ... I think that's the expected name.

You are running SmartGit with its bundled Git, right? So I think all of the following options should work:

(1) switch SmartGit to your system Git in the Preferences, section Executables

(2) create a symlink from SmartGit's bundled Git to git-credential-osxkeychain; something like the following should work:

ln -s /usr/local/bin/git-credential-osxkeychain /Applications/SmartGit.app/Contents/Resources/git/bin/git-credential-osxkeychain

(3) Get rid of the [credential]-section from your .gitconfig

--
Best regards,
Marc Strapetz
syntevo GmbH
http://www.syntevo.com



> --
> You received this message because you are subscribed to the Google Groups
> "SmartGit" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
> smartgit+u...@googlegroups.com.
> To post to this group, send email to smar...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/smartgit/536c8665-0476-498e-b981-6221fedc91f2%40googlegroups.com.

Shannon Pekary

unread,
May 18, 2016, 1:01:08 PM5/18/16
to SmartGit, smar...@syntevo.com
No joy, see below.


On Wednesday, May 18, 2016 at 4:24:57 AM UTC-7, syntevo Support wrote:
> I do not have a credential-osxkeychain. Instead its git-credential-osxkeychain.

I see ... I think that's the expected name.

You are running SmartGit with its bundled Git, right? So I think all of the following options should work:

(1) switch SmartGit to your system Git in the Preferences, section Executables

I was already running it with the system git in Preferences. Removing it brings up a dialog that says I must install git command line tools to make SmartGit work. Perhaps it is ignoring this setting?
 

(2) create a symlink from SmartGit's bundled Git to git-credential-osxkeychain; something like the following should work:

ln -s /usr/local/bin/git-credential-osxkeychain /Applications/SmartGit.app/Contents/Resources/git/bin/git-credential-osxkeychain

I needed SmartGit 2 in the path. First time I tried it, it said there was one already there. I renamed it and did the link again. No change, still not working with the same message. 

(3) Get rid of the [credential]-section from your .gitconfig

Did that. Still not working, but with a different message:

157777 (2016-05-18 09:57:07,435) [main] INFO              q.dialog  - Show (warn): Command Failed - Authentication failed for 'https://github.com/spekary/qcubed.git/' - git: 'credential-osxkeychain' is not a git command. See 'git --help'.
git: 'credential-osxkeychain' is not a git command. See 'git --help'.
remote: Anonymous access to spekary/qcubed.git denied.

So, fewer of the messages. But still not working.

syntevo Support

unread,
May 18, 2016, 1:28:18 PM5/18/16
to smar...@googlegroups.com
> >
> > (3) Get rid of the [credential]-section from your .gitconfig
> >
>
> Did that. Still not working, but with a different message:
>
> 157777 (2016-05-18 09:57:07,435) [main] INFO q.dialog - Show
> (warn): Command Failed - Authentication failed for
> 'https://github.com/spekary/qcubed.git/' - git: 'credential-osxkeychain' is
> not a git command. See 'git --help'.
> git: 'credential-osxkeychain' is not a git command. See 'git --help'.
> remote: Anonymous access to spekary/qcubed.git denied.

What's the exact content of your ~/.gitconfig now? Is your repository's .git/config possibly containing a [credentials]-section, too?

Please also send me log.txt*-files (from the settings directory, see About dialog) compressed to smar...@syntevo.com .

--
Best regards,
Marc Strapetz
syntevo GmbH
http://www.syntevo.com



> > > smartgit+u...@googlegroups.com <javascript:>.
> > > To post to this group, send email to smar...@googlegroups.com
> > <javascript:>.
> > > To view this discussion on the web visit
> > >
> > https://groups.google.com/d/msgid/smartgit/536c8665-0476-498e-b981-6221fedc91f2%40googlegroups.com.
> >
> > > For more options, visit https://groups.google.com/d/optout.
> > >
>
> --
> You received this message because you are subscribed to the Google Groups
> "SmartGit" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
> smartgit+u...@googlegroups.com.
> To post to this group, send email to smar...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/smartgit/45c22021-5385-410f-8967-4b4bdd325bba%40googlegroups.com.

Shannon Pekary

unread,
May 19, 2016, 11:11:59 AM5/19/16
to SmartGit, smar...@syntevo.com
I was able to get up and running by removing the credential section from both the local .gitignore, and the system wide config file /usr/local/bin/etc/gitconfig. Thanks for your help.
Reply all
Reply to author
Forward
0 new messages