我最近克隆了一個回購到我的本地驅動器,但現在我試圖推動所有更改到一個完整的新回購。然而,git一直告訴我,權限被拒絕,這是因爲它試圖推向最初克隆的回購。如何切換到新的遠程git存儲庫
詳情:
我最初從https://github.com/taylonr/intro-to-protractor克隆(即,基於一個Pluralsight當然在https://app.pluralsight.com/library/courses/protractor-introduction/table-of-contents)。
現在,我已經完成了課程,我想起來把我定型的代碼我自己的混帳回購協議(這只是我在GitHub上創建):
https://github.com/robertmazzo/intro-to-protractor
當我使用下面的git命令:
git的遠程添加原產https://github.com/robertmazzo/intro-to-protractor.git
它告訴我remote origin already exists
,我想這很好,因爲我已經在github.com上創建了它。
但是,當我推進我的更改,我得到一個異常。
混帳推起源主
remote: Permission to taylonr/intro-to-protractor.git denied to robertmazzo. fatal: unable to access 'https://github.com/taylonr/intro-to-protractor.git/': The requested URL returned error: 403
所以我調查我如何可以切換到我的新的存儲庫,但是這也正是我的問題。我無法弄清楚這一部分。
可能的複製[更改遠程Git倉庫的URI(URL)(HTTP ://stackoverflow.com/questions/2432764/change-the-uri-url-for-a-remote-git-repository) –