X7ROOT File Manager
Current Path:
/usr/share/doc/git-1.8.3.1/technical
usr
/
share
/
doc
/
git-1.8.3.1
/
technical
/
📁
..
📄
api-allocation-growing.html
(17.55 KB)
📄
api-allocation-growing.txt
(1019 B)
📄
api-argv-array.html
(19.44 KB)
📄
api-argv-array.txt
(2.12 KB)
📄
api-builtin.html
(19.43 KB)
📄
api-builtin.txt
(2 KB)
📄
api-config.html
(23.39 KB)
📄
api-config.txt
(5.18 KB)
📄
api-credentials.html
(27.9 KB)
📄
api-credentials.txt
(8.87 KB)
📄
api-decorate.html
(16.23 KB)
📄
api-decorate.txt
(60 B)
📄
api-diff.html
(24.32 KB)
📄
api-diff.txt
(5.22 KB)
📄
api-directory-listing.html
(20.75 KB)
📄
api-directory-listing.txt
(2.71 KB)
📄
api-gitattributes.html
(21.9 KB)
📄
api-gitattributes.txt
(3.62 KB)
📄
api-grep.html
(16.31 KB)
📄
api-grep.txt
(76 B)
📄
api-hash.html
(18.42 KB)
📄
api-hash.txt
(1.4 KB)
📄
api-hashmap.html
(35.57 KB)
📄
api-hashmap.txt
(7.71 KB)
📄
api-history-graph.html
(24.08 KB)
📄
api-history-graph.txt
(5.9 KB)
📄
api-in-core-index.html
(16.96 KB)
📄
api-in-core-index.txt
(457 B)
📄
api-index-skel.txt
(431 B)
📄
api-index.html
(18.45 KB)
📄
api-index.sh
(611 B)
📄
api-index.txt
(1.68 KB)
📄
api-lockfile.html
(20.05 KB)
📄
api-lockfile.txt
(2.92 KB)
📄
api-merge.html
(21.36 KB)
📄
api-merge.txt
(3.3 KB)
📄
api-object-access.html
(16.73 KB)
📄
api-object-access.txt
(342 B)
📄
api-parse-options.html
(31.03 KB)
📄
api-parse-options.txt
(9.36 KB)
📄
api-quote.html
(16.42 KB)
📄
api-quote.txt
(145 B)
📄
api-ref-iteration.html
(19.71 KB)
📄
api-ref-iteration.txt
(2.41 KB)
📄
api-remote.html
(21.26 KB)
📄
api-remote.txt
(3.3 KB)
📄
api-revision-walking.html
(19.76 KB)
📄
api-revision-walking.txt
(2.39 KB)
📄
api-run-command.html
(28.25 KB)
📄
api-run-command.txt
(8.08 KB)
📄
api-setup.html
(16.51 KB)
📄
api-setup.txt
(180 B)
📄
api-sha1-array.html
(19.39 KB)
📄
api-sha1-array.txt
(2.25 KB)
📄
api-sigchain.html
(17.74 KB)
📄
api-sigchain.txt
(1.34 KB)
📄
api-strbuf.html
(32.15 KB)
📄
api-strbuf.txt
(10.17 KB)
📄
api-string-list.html
(26.42 KB)
📄
api-string-list.txt
(6.84 KB)
📄
api-tree-walking.html
(23.17 KB)
📄
api-tree-walking.txt
(4.27 KB)
📄
api-xdiff-interface.html
(16.3 KB)
📄
api-xdiff-interface.txt
(139 B)
📄
index-format.html
(27.12 KB)
📄
index-format.txt
(6.29 KB)
📄
pack-format.html
(24.08 KB)
📄
pack-format.txt
(5.54 KB)
📄
pack-heuristics.html
(42.74 KB)
📄
pack-heuristics.txt
(17.77 KB)
📄
pack-protocol.html
(43.12 KB)
📄
pack-protocol.txt
(20.99 KB)
📄
protocol-capabilities.html
(25.41 KB)
📄
protocol-capabilities.txt
(7.09 KB)
📄
protocol-common.html
(20.08 KB)
📄
protocol-common.txt
(2.7 KB)
📄
racy-git.html
(26.85 KB)
📄
racy-git.txt
(8.63 KB)
📄
send-pack-pipeline.html
(18.73 KB)
📄
send-pack-pipeline.txt
(1.92 KB)
📄
shallow.html
(18.86 KB)
📄
shallow.txt
(2.3 KB)
📄
trivial-merge.html
(21.62 KB)
📄
trivial-merge.txt
(4.16 KB)
Editing: api-merge.txt
merge API ========= The merge API helps a program to reconcile two competing sets of improvements to some files (e.g., unregistered changes from the work tree versus changes involved in switching to a new branch), reporting conflicts if found. The library called through this API is responsible for a few things. * determining which trees to merge (recursive ancestor consolidation); * lining up corresponding files in the trees to be merged (rename detection, subtree shifting), reporting edge cases like add/add and rename/rename conflicts to the user; * performing a three-way merge of corresponding files, taking path-specific merge drivers (specified in `.gitattributes`) into account. Data structures --------------- * `mmbuffer_t`, `mmfile_t` These store data usable for use by the xdiff backend, for writing and for reading, respectively. See `xdiff/xdiff.h` for the definitions and `diff.c` for examples. * `struct ll_merge_options` This describes the set of options the calling program wants to affect the operation of a low-level (single file) merge. Some options: `virtual_ancestor`:: Behave as though this were part of a merge between common ancestors in a recursive merge. If a helper program is specified by the `[merge "<driver>"] recursive` configuration, it will be used (see linkgit:gitattributes[5]). `variant`:: Resolve local conflicts automatically in favor of one side or the other (as in 'git merge-file' `--ours`/`--theirs`/`--union`). Can be `0`, `XDL_MERGE_FAVOR_OURS`, `XDL_MERGE_FAVOR_THEIRS`, or `XDL_MERGE_FAVOR_UNION`. `renormalize`:: Resmudge and clean the "base", "theirs" and "ours" files before merging. Use this when the merge is likely to have overlapped with a change in smudge/clean or end-of-line normalization rules. Low-level (single file) merge ----------------------------- `ll_merge`:: Perform a three-way single-file merge in core. This is a thin wrapper around `xdl_merge` that takes the path and any merge backend specified in `.gitattributes` or `.git/info/attributes` into account. Returns 0 for a clean merge. Calling sequence: * Prepare a `struct ll_merge_options` to record options. If you have no special requests, skip this and pass `NULL` as the `opts` parameter to use the default options. * Allocate an mmbuffer_t variable for the result. * Allocate and fill variables with the file's original content and two modified versions (using `read_mmfile`, for example). * Call `ll_merge()`. * Read the merged content from `result_buf.ptr` and `result_buf.size`. * Release buffers when finished. A simple `free(ancestor.ptr); free(ours.ptr); free(theirs.ptr); free(result_buf.ptr);` will do. If the modifications do not merge cleanly, `ll_merge` will return a nonzero value and `result_buf` will generally include a description of the conflict bracketed by markers such as the traditional `<<<<<<<` and `>>>>>>>`. The `ancestor_label`, `our_label`, and `their_label` parameters are used to label the different sides of a conflict if the merge driver supports this. Everything else --------------- Talk about <merge-recursive.h> and merge_file(): - merge_trees() to merge with rename detection - merge_recursive() for ancestor consolidation - try_merge_command() for other strategies - conflict format - merge options (Daniel, Miklos, Stephan, JC)
Upload File
Create Folder