FYI: Retired programmer, linux platform, bash terminal. Some experience with SSH, new to git and bitbucket. Have followed a tutorial which steps through creating and pushing to repositories. Repositories were deleted and a new one created. I have generated a new SSH key, ssh-agent and ssh-add were used as per the bitbucket instructions and added public key to my bitbucket profile.
I can 't even manage to execute an initial push to that new repository. The following code was attempted with user and repository name obfuscated. (please advise me if such obfuscation is not necessary).
git remote add origin git@bitbucket.org:myusername/mypository.git
fatal: remote origin already exists.
git remote set-url origin git@bitbucket.org:myusername/mypository.git
returns nothing and appears to log me in.
the following three commands are all unsuccessful:
git push -f origin master
Unauthorized
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
git push -u origin master
Unauthorized
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
git push -u origin --all
Unauthorized
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
.... and same issue with -f flag.
Please advise, I am also unfamiliar with formatting protocols here. So Sorry.
I'm speculating that my key may not be readable, but if so, don't know where to change settings.
Thanks,
Tim