-
-
Notifications
You must be signed in to change notification settings - Fork 954
-
Beta Was this translation helpful? Give feedback.
All reactions
Which way around is right has always been troublesome for me as diff
doesn't convey the direction into which the diff should go, at least not without prior training.
In gitoxide
, I use tree.(get_)changes_to_obtain(other_tree)
which makes clear what needs to be done to turn tree
into other_tree
. Without the notion of direction, things can look reversed pretty quickly.
Changing anything in GitPython would be a breaking change and thus can't be done, but either one can add new names to make direction clear, or code has to be adjusted to be target.diff(index)
.
Replies: 1 comment
-
Which way around is right has always been troublesome for me as diff
doesn't convey the direction into which the diff should go, at least not without prior training.
In gitoxide
, I use tree.(get_)changes_to_obtain(other_tree)
which makes clear what needs to be done to turn tree
into other_tree
. Without the notion of direction, things can look reversed pretty quickly.
Changing anything in GitPython would be a breaking change and thus can't be done, but either one can add new names to make direction clear, or code has to be adjusted to be target.diff(index)
.
Beta Was this translation helpful? Give feedback.