就我的理解...
先加 remote repogit remote add origin https://git...
如果分之名稱不一樣可能要改一下git branch -m main
然後看你要怎麼處理 commit
push --force
(以你的敘述應該是這個,遠端如果有 commit 會直接被蓋掉)
pull --force
或 fetch
+ reset --hard
pull --rebase