[PATCH v2 0/4] Beginning of new merge strategy: New API, empty implementation

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

 



In this series, I try to show the new merge API I have developed in
merge-ort and show how it differs from that provided by merge-recursive. I
do this in four steps, each corresponding to a patch.

Changes since v1 (thanks to Taylor and Peter for the suggestions in their
reviews):

 * Point out in the first commit message that the next three patches will be
   providing example usage of the new API.
 * Rename a variable away from '_' in a way that continues the "private"
   theme.
 * Unswap function comments that were placed next to the wrong functions.

Elijah Newren (4):
  merge-ort: barebones API of new merge strategy with empty
    implementation
  merge-ort-wrappers: new convience wrappers to mimic the old merge API
  fast-rebase: demonstrate merge-ort's API via temporary/hidden command
  merge,rebase,revert: select ort or recursive by config or environment

 Makefile              |   3 +
 builtin.h             |   1 +
 builtin/fast-rebase.c | 210 ++++++++++++++++++++++++++++++++++++++++++
 builtin/merge.c       |  26 +++++-
 builtin/rebase.c      |   9 +-
 builtin/revert.c      |   2 +
 git.c                 |   1 +
 merge-ort-wrappers.c  |  62 +++++++++++++
 merge-ort-wrappers.h  |  25 +++++
 merge-ort.c           |  52 +++++++++++
 merge-ort.h           |  49 ++++++++++
 sequencer.c           |  71 +++++++++++---
 12 files changed, 496 insertions(+), 15 deletions(-)
 create mode 100644 builtin/fast-rebase.c
 create mode 100644 merge-ort-wrappers.c
 create mode 100644 merge-ort-wrappers.h
 create mode 100644 merge-ort.c
 create mode 100644 merge-ort.h


base-commit: 69986e19ffcfb9af674ae5180689ab7bbf92ed28
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-895%2Fnewren%2Fort-api-with-empty-implementation-v2
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-895/newren/ort-api-with-empty-implementation-v2
Pull-Request: https://github.com/git/git/pull/895

Range-diff vs v1:

 1:  54ef18182c ! 1:  b9e73975ea merge-ort: barebones API of new merge strategy with empty implementation
     @@ Commit message
          can perform a merge between two branches, neither of which match the
          index or the working tree, without clobbering the index or working tree.
      
     +    The next three commits will demonstrate various uses of this new API.
     +
          Signed-off-by: Elijah Newren <newren@xxxxxxxxx>
      
       ## Makefile ##
     @@ merge-ort.h (new)
      +
      +	/*
      +	 * Additional metadata used by merge_switch_to_result() or future calls
     -+	 * to merge_inmemory_*().
     ++	 * to merge_inmemory_*().  Not for external use.
      +	 */
     -+	unsigned _;
      +	void *priv;
     ++	unsigned ate;
      +};
      +
     -+/* rename-detecting three-way merge, no recursion. */
     ++/* rename-detecting three-way merge with recursive ancestor consolidation. */
      +void merge_inmemory_recursive(struct merge_options *opt,
      +			      struct commit_list *merge_bases,
      +			      struct commit *side1,
      +			      struct commit *side2,
      +			      struct merge_result *result);
      +
     -+/* rename-detecting three-way merge with recursive ancestor consolidation. */
     ++/* rename-detecting three-way merge, no recursion. */
      +void merge_inmemory_nonrecursive(struct merge_options *opt,
      +				 struct tree *merge_base,
      +				 struct tree *side1,
 2:  f597609b88 = 2:  a9fff811a2 merge-ort-wrappers: new convience wrappers to mimic the old merge API
 3:  a1357fb3b3 = 3:  f38d140c15 fast-rebase: demonstrate merge-ort's API via temporary/hidden command
 4:  06ecea215f = 4:  5f6c97b889 merge,rebase,revert: select ort or recursive by config or environment

-- 
gitgitgadget



[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