看板 Linux 關於我們 聯絡資訊
http://ppt.cc/vT2O 請問我想將遠端的 3daf2ce eb49fde 兩個commit刪除 簡單來說就是 origin/weather 這個支線完全都不要了 我的做法是 git checkout 3daf2ce git rebase -i 3cf7de6 然後在介面中只留下 pick 8d1fd33 結束後執行 git rebase --continue 不過看來好像不行 所以不太敢push上去 請問我是不是哪裡有做錯 或是觀念有問題 請糾正我謝謝 如果不適合在這邊問請跟我說 我自刪 -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 111.250.8.69 ※ 文章網址: http://www.ptt.cc/bbs/Linux/M.1413887570.A.2D9.html
asilzheng: git push origin :weather 10/21 18:38
asilzheng: 刪除 branch 限定 10/21 18:39
ireullin: 但是這種方式刪除了branch,可是commit還會在不是嗎 10/21 18:58
ireullin: 我希望是連commit都沒有 10/21 18:58
gkk886: branch刪除後沒被reference到的local commit可被git gc 10/21 21:48
gkk886: 清掉 remote端預設好像自動會做 有誤請指正.. 10/21 21:49
ireullin: 是的沒錯,謝謝大家囉 10/22 11:31