Cjku/git: Difference between revisions

44 bytes removed ,  1 November 2014
Line 432: Line 432:
#* A[No]  B[N/A] C[No]  Pass. After checkout done, keep change in working directory.
#* A[No]  B[N/A] C[No]  Pass. After checkout done, keep change in working directory.


10 out of 18 cases pass conflict test. 2 of these 10 cases keep your change in cache. In 1 of these 10 cases, you still lose the change in working directory immidiately after checkout, very 囧 ... If you checkout from a dirty branch with no conflict, many unexpected symptoms appears. Such as commit an unexpected file which was added from another branch. My suggestion is create a git alias, do some status checking before checkout. Here is a simple examle: https://github.com/CJKu/git_utils/blob/master/command/git-clean-checkout
10 out of 18 cases pass conflict test. 2 of these 10 cases keep your change in cache. In 1 of these 10 cases, you still lose the change in working directory immidiately after checkout, very 囧 ... If you checkout from a dirty branch with no conflict, many unexpected symptoms appears. Such as commit an unexpected file which was added from another branch. My suggestion is create a git alias, do some status checking before checkout. Here is an examle
  https://github.com/CJKu/git_utils


So, how to resolve aborting? Different strategies for different situations
So, how to resolve aborting? Different strategies for different situations
Confirmed users
1,643

edits