當我第一次安裝git時,我使用了一個錯誤的存儲庫鏈接。我可以安全地從git配置文件中刪除舊的存儲庫鏈接嗎?
我可以看到,在我的Android Studio項目git的文件夾中找到我的配置文件中有如下設置:
ignorecase = true
[remote "origin"]
url = https://github.com/NrkSensors/Android.git
fetch = +refs/heads/*:refs/remotes/origin/*
[branch]
autosetuprebase = always
[branch "master"]
rebase = true
remote = origin
merge = refs/heads/master
[remote "github"]
url = https://github.com/Muuddz/AndroidApp.git
fetch = +refs/heads/*:refs/remotes/github/*
我想這個去掉https://github.com/Muuddz/AndroidApp.git ,因爲這個倉庫不到風度存在了。我無法在Android Studio中找到任何方法來更改它。我應該從文件中刪除什麼纔不會破壞任何東西?
打開你的'config'文件'vi .git/config'並刪除行'[remote'github'] url = https://github.com/Muuddz/AndroidApp.git fetch = + refs/heads/*:refs/remotes/github/*' – VKatz
你會告訴你想要設置哪個來源 – VKatz
'https:// github.com/NrkSensors/Android.git'是在[[remote'origin]之下的正確的] ' – Muddz