-2

https://i.stack.imgur.com/IUpbh.png

Hi I'm able to use the following command when i have plain password.

git pull http://$username:$password@github.com/pulkit889/project1.git

but it fails when password contains special character.

pulkit
  • 47
  • 6

1 Answers1

0

Got The answer. You have to convert whole password in a string of hexadecimal characters separated by '%' sign. Used the following instead of just $password.

$(echo -n $password | hexdump -v -e '"x" 1/1 "%02X"' | tr x %)

found it here: https://stackoverflow.com/a/53519379/11558375

pulkit
  • 47
  • 6