2

I am trying to set up a Jenkins Windows slave which will pull from GitHub using Git Bash. I have installed Git Bash on my Windows server so it is available through the Windows command prompt. When I try to invoke any Git command that goes to GitHub it always asks for my credentials.

How can I set this up so it does not ask for my credentials?

Points to note:

I am testing it by invoking from the Windows cmd and not the Git Bash shell as I believe this is how Jenkins will call it.

If it isn't possible, how do you connect to GitHub from a Jenkins slave via Git Bash without it asking for credentials?

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
user1107753
  • 1,566
  • 4
  • 24
  • 36

2 Answers2

2

I had a browse around and managed to find my answer. It is solved by the following post

Is there a way to skip password typing when using https:// on GitHub?

Works a treat!!

Community
  • 1
  • 1
user1107753
  • 1,566
  • 4
  • 24
  • 36
0

See Git Bash at https://msysgit.github.io

It's a Linux-like console for Windows.

You will need to generate SSH keys which will be in your HOME_DIR/.ssh folder.

As an example, see Working with Git on Windows.

After generating keys, install it to the GitHub account.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Vitalii Velikodnyi
  • 1,312
  • 11
  • 18