a----b \----c Given the graph above, I want to create a commit b1 on top of c, where b1 and b have the same content. i.e. a----b \----c----b1 ( content(b) == content(b1) ) If there are no untracked files in the working directory, i can do git checkout b git reset c git add . git commit -m "the copy of b" Is there any simpler way? And if there are untracked files in the working directory, how to do it? Ping Yin -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html