You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm loving Git::Raw. But so far, it isn't clear to me how to do the moral equivalent of git checkout some_branch. None of the various checkout strategies seem to "do the right thing". In particular, they don't seem to remove files from the work dir that are not in the new tree.
I think part of the problem may be that HEAD needs to be changed to point to the new tree before starting the checkout. So perhaps a binding to git_repository_set_head() is also needed.
Or am I just looking at this in the wrong way entirely?
The text was updated successfully, but these errors were encountered:
Note that I also took the opportunity to sync the checkout strategies in Git::Raw with the new ones in libgit2, so "update_unmodified", "update_missing", "update_modified" and "update_untracked" were removed (but you can now use the "safe" strategy, which is what git checkout does).
Also note that, as of now, the checkout implementation in Git::Raw is quite incomplete (e.g. there's no support for resolving conflicts), so only simple use cases are currently possible.
I'm loving Git::Raw. But so far, it isn't clear to me how to do the moral equivalent of
git checkout some_branch
. None of the various checkout strategies seem to "do the right thing". In particular, they don't seem to remove files from the work dir that are not in the new tree.I think part of the problem may be that HEAD needs to be changed to point to the new tree before starting the checkout. So perhaps a binding to git_repository_set_head() is also needed.
Or am I just looking at this in the wrong way entirely?
The text was updated successfully, but these errors were encountered: