Re: [RFC] origin link for cherry-pick and revert

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> - At the time of creation, the origin field contains a hash B which refers
>   to a reachable commit pair (B, B~1).  If B has multiple parents and the pair
>   being referred to needs to be e.g. (B, B~2), then the hash is followed by
>   a space and followed by an integer (base10, two in this case),
>   which designates the proper parentnr of B (see: mainline in git
>   cherry-pick/revert).

What about just storing *two* hashes?  This way cherry-pick can store
B~1..B and revert can store B..B~1.  The two cases can be distinguished
by checking which commit is an ancestor of which.

> - git cherry-pick/revert allow for the creation of origin links only if
>   the object they are referring to is presently reachable.

Will cherry-pick -x create origin links?  Also, does the origin link
propagate through multiple cherry picks?  If not, how can the origin
object not be reachable?

> [snip good stuff]

git cherry will use origin links to mark a commit as present, and will
only use patch-ids for commits that have no origin links.  Bonus points
for an extra command-line/configuration option to only use origin links:

  --source=default	  << default: get setting from core.cherrysource
  --source=patch-id
  --source=origin
  --source=origin,patch-id

  core.cherrysource = patch-id
  core.cherrysource = origin
  core.cherrysource = origin,patch-id

Thanks!

Paolo
--
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

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux