I am working on a project of mine and I got the codes uploaded in github. I started working in this project from Win10 os and currently I’m working in Arch linux. In windows it didn’t use to ask me for any password but it does now.
I’ve never pushed from my linux before. Today when I tried to push the terminal and VB code both are asking for my github username and password.
I kept a backup of this project at my usb hard drive and currently I pasted it in my linux ssd. What I’m saying is I didn’t clone it from the repo. As far as my global username & user email are concerned both are accurate. I’m not using any SSH so when I type git remote -v
in my terminal it shows https link as the origin for both fetch and push.
Why is it asking for my username and password? Is it secure to provide my password? In case if I provide my credentials then do I have to provide it every time I push? How to fix this?
I have searched stackoverflow for solution but the other questions that I have found doesn’t match my criteria cause in windows it was working fine without asking any credentials.
Advertisement
Answer
So, I have updated my origin
remote from https to ssh and added a ssh public key to my github account after creating one which is well defined by github finally my problem solved and now I can push to my repo without any credential prompt by the terminal. Thank you Code-Apprentice.