Compare commits

..

26 Commits

Author SHA1 Message Date
e4f4299859 Git 2.28.1
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:50:10 +01:00
3f01e56686 Sync with 2.27.1
* maint-2.27:
  Git 2.27.1
  Git 2.26.3
  Git 2.25.5
  Git 2.24.4
  Git 2.23.4
  Git 2.22.5
  Git 2.21.4
  Git 2.20.5
  Git 2.19.6
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:50:09 +01:00
6ff7f46039 Git 2.27.1
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:50:05 +01:00
2d1142a3e8 Sync with 2.26.3
* maint-2.26:
  Git 2.26.3
  Git 2.25.5
  Git 2.24.4
  Git 2.23.4
  Git 2.22.5
  Git 2.21.4
  Git 2.20.5
  Git 2.19.6
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:50:04 +01:00
a79fd20c71 Git 2.26.3
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:50:00 +01:00
8f80393c14 Sync with 2.25.5
* maint-2.25:
  Git 2.25.5
  Git 2.24.4
  Git 2.23.4
  Git 2.22.5
  Git 2.21.4
  Git 2.20.5
  Git 2.19.6
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:49:59 +01:00
42ce4c7930 Git 2.25.5
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:49:55 +01:00
97d1dcb1ef Sync with 2.24.4
* maint-2.24:
  Git 2.24.4
  Git 2.23.4
  Git 2.22.5
  Git 2.21.4
  Git 2.20.5
  Git 2.19.6
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:49:55 +01:00
06214d171b Git 2.24.4
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:49:50 +01:00
92ac04b8ee Sync with 2.23.4
* maint-2.23:
  Git 2.23.4
  Git 2.22.5
  Git 2.21.4
  Git 2.20.5
  Git 2.19.6
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:49:50 +01:00
d60b6a96f0 Git 2.23.4
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:49:46 +01:00
4bd06fd490 Sync with 2.22.5
* maint-2.22:
  Git 2.22.5
  Git 2.21.4
  Git 2.20.5
  Git 2.19.6
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:49:45 +01:00
c753e2a7a8 Git 2.22.5
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:49:41 +01:00
bcf08f33d8 Sync with 2.21.4
* maint-2.21:
  Git 2.21.4
  Git 2.20.5
  Git 2.19.6
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:49:41 +01:00
c735d7470e Git 2.21.4
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:49:36 +01:00
b1726b1a38 Sync with 2.20.5
* maint-2.20:
  Git 2.20.5
  Git 2.19.6
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:49:35 +01:00
8b1a5f33d3 Git 2.20.5
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:49:17 +01:00
804963848e Sync with 2.19.6
* maint-2.19:
  Git 2.19.6
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:49:17 +01:00
9fb2a1fb08 Git 2.19.6
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:47:48 +01:00
fb049fd85b Sync with 2.18.5
* maint-2.18:
  Git 2.18.5
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:47:47 +01:00
6eed462c8f Git 2.18.5
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:47:43 +01:00
9b77cec89b Sync with 2.17.6
* maint-2.17:
  Git 2.17.6
  unpack_trees(): start with a fresh lstat cache
  run-command: invalidate lstat cache after a command finished
  checkout: fix bug that makes checkout follow symlinks in leading path
2021-02-12 15:47:42 +01:00
6b82d3eea6 Git 2.17.6
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:47:02 +01:00
22539ec3b5 unpack_trees(): start with a fresh lstat cache
We really want to avoid relying on stale information.

Signed-off-by: Matheus Tavares <matheus.bernardino@usp.br>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:47:02 +01:00
0d58fef58a run-command: invalidate lstat cache after a command finished
In the previous commit, we intercepted calls to `rmdir()` to invalidate
the lstat cache in the successful case, so that the lstat cache could
not have the idea that a directory exists where there is none.

The same situation can arise, of course, when a separate process is
spawned (most notably, this is the case in `submodule_move_head()`).
Obviously, we cannot know whether a directory was removed in that
process, therefore we must invalidate the lstat cache afterwards.

Note: in contrast to `lstat_cache_aware_rmdir()`, we invalidate the
lstat cache even in case of an error: the process might have removed a
directory and still have failed afterwards.

Co-authored-by: Matheus Tavares <matheus.bernardino@usp.br>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-02-12 15:47:02 +01:00
684dd4c2b4 checkout: fix bug that makes checkout follow symlinks in leading path
Before checking out a file, we have to confirm that all of its leading
components are real existing directories. And to reduce the number of
lstat() calls in this process, we cache the last leading path known to
contain only directories. However, when a path collision occurs (e.g.
when checking out case-sensitive files in case-insensitive file
systems), a cached path might have its file type changed on disk,
leaving the cache on an invalid state. Normally, this doesn't bring
any bad consequences as we usually check out files in index order, and
therefore, by the time the cached path becomes outdated, we no longer
need it anyway (because all files in that directory would have already
been written).

But, there are some users of the checkout machinery that do not always
follow the index order. In particular: checkout-index writes the paths
in the same order that they appear on the CLI (or stdin); and the
delayed checkout feature -- used when a long-running filter process
replies with "status=delayed" -- postpones the checkout of some entries,
thus modifying the checkout order.

When we have to check out an out-of-order entry and the lstat() cache is
invalid (due to a previous path collision), checkout_entry() may end up
using the invalid data and thrusting that the leading components are
real directories when, in reality, they are not. In the best case
scenario, where the directory was replaced by a regular file, the user
will get an error: "fatal: unable to create file 'foo/bar': Not a
directory". But if the directory was replaced by a symlink, checkout
could actually end up following the symlink and writing the file at a
wrong place, even outside the repository. Since delayed checkout is
affected by this bug, it could be used by an attacker to write
arbitrary files during the clone of a maliciously crafted repository.

Some candidate solutions considered were to disable the lstat() cache
during unordered checkouts or sort the entries before passing them to
the checkout machinery. But both ideas include some performance penalty
and they don't future-proof the code against new unordered use cases.

Instead, we now manually reset the lstat cache whenever we successfully
remove a directory. Note: We are not even checking whether the directory
was the same as the lstat cache points to because we might face a
scenario where the paths refer to the same location but differ due to
case folding, precomposed UTF-8 issues, or the presence of `..`
components in the path. Two regression tests, with case-collisions and
utf8-collisions, are also added for both checkout-index and delayed
checkout.

Note: to make the previously mentioned clone attack unfeasible, it would
be sufficient to reset the lstat cache only after the remove_subtree()
call inside checkout_entry(). This is the place where we would remove a
directory whose path collides with the path of another entry that we are
currently trying to check out (possibly a symlink). However, in the
interest of a thorough fix that does not leave Git open to
similar-but-not-identical attack vectors, we decided to intercept
all `rmdir()` calls in one fell swoop.

This addresses CVE-2021-21300.

Co-authored-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Matheus Tavares <matheus.bernardino@usp.br>
2021-02-12 15:47:02 +01:00
1410 changed files with 79907 additions and 151638 deletions

1
.gitattributes vendored
View File

@ -6,7 +6,6 @@
*.pm eol=lf diff=perl *.pm eol=lf diff=perl
*.py eol=lf diff=python *.py eol=lf diff=python
*.bat eol=crlf *.bat eol=crlf
CODE_OF_CONDUCT.md -whitespace
/Documentation/**/*.txt eol=lf /Documentation/**/*.txt eol=lf
/command-list.txt eol=lf /command-list.txt eol=lf
/GIT-VERSION-GEN eol=lf /GIT-VERSION-GEN eol=lf

View File

@ -1,71 +0,0 @@
name: check-whitespace
# Get the repo with the commits(+1) in the series.
# Process `git log --check` output to extract just the check errors.
# Add a comment to the pull request with the check errors.
on:
pull_request:
types: [opened, synchronize]
jobs:
check-whitespace:
runs-on: ubuntu-latest
steps:
- name: Set commit count
shell: bash
run: echo "COMMIT_DEPTH=$((1+$COMMITS))" >>$GITHUB_ENV
env:
COMMITS: ${{ github.event.pull_request.commits }}
- uses: actions/checkout@v2
with:
fetch-depth: ${{ env.COMMIT_DEPTH }}
- name: git log --check
id: check_out
run: |
log=
commit=
while read dash etc
do
case "${dash}" in
"---")
commit="${etc}"
;;
"")
;;
*)
if test -n "${commit}"
then
log="${log}\n${commit}"
echo ""
echo "--- ${commit}"
fi
commit=
log="${log}\n${dash} ${etc}"
echo "${dash} ${etc}"
;;
esac
done <<< $(git log --check --pretty=format:"---% h% s" -${{github.event.pull_request.commits}})
if test -n "${log}"
then
echo "::set-output name=checkout::"${log}""
exit 2
fi
- name: Add Check Output as Comment
uses: actions/github-script@v3
id: add-comment
env:
log: ${{ steps.check_out.outputs.checkout }}
with:
script: |
await github.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: `Whitespace errors found in workflow ${{ github.workflow }}:\n\n\`\`\`\n${process.env.log.replace(/\\n/g, "\n")}\n\`\`\``
})
if: ${{ failure() }}

View File

@ -7,74 +7,34 @@ env:
jobs: jobs:
ci-config: ci-config:
runs-on: ubuntu-latest runs-on: ubuntu-latest
outputs: outputs:
enabled: ${{ steps.check-ref.outputs.enabled }}${{ steps.skip-if-redundant.outputs.enabled }} enabled: ${{ steps.check-ref.outputs.enabled }}
steps: steps:
- name: try to clone ci-config branch - name: try to clone ci-config branch
run: | continue-on-error: true
git -c protocol.version=2 clone \ run: |
--no-tags \ git -c protocol.version=2 clone \
--single-branch \ --no-tags \
-b ci-config \ --single-branch \
--depth 1 \ -b ci-config \
--no-checkout \ --depth 1 \
--filter=blob:none \ --no-checkout \
https://github.com/${{ github.repository }} \ --filter=blob:none \
config-repo && https://github.com/${{ github.repository }} \
cd config-repo && config-repo &&
git checkout HEAD -- ci/config || : ignore cd config-repo &&
- id: check-ref git checkout HEAD -- ci/config
name: check whether CI is enabled for ref - id: check-ref
run: | name: check whether CI is enabled for ref
enabled=yes run: |
if test -x config-repo/ci/config/allow-ref && enabled=yes
! config-repo/ci/config/allow-ref '${{ github.ref }}' if test -x config-repo/ci/config/allow-ref &&
then ! config-repo/ci/config/allow-ref '${{ github.ref }}'
enabled=no then
fi enabled=no
echo "::set-output name=enabled::$enabled" fi
- name: skip if the commit or tree was already tested echo "::set-output name=enabled::$enabled"
id: skip-if-redundant
uses: actions/github-script@v3
if: steps.check-ref.outputs.enabled == 'yes'
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
try {
// Figure out workflow ID, commit and tree
const { data: run } = await github.actions.getWorkflowRun({
owner: context.repo.owner,
repo: context.repo.repo,
run_id: context.runId,
});
const workflow_id = run.workflow_id;
const head_sha = run.head_sha;
const tree_id = run.head_commit.tree_id;
// See whether there is a successful run for that commit or tree
const { data: runs } = await github.actions.listWorkflowRuns({
owner: context.repo.owner,
repo: context.repo.repo,
per_page: 500,
status: 'success',
workflow_id,
});
for (const run of runs.workflow_runs) {
if (head_sha === run.head_sha) {
core.warning(`Successful run for the commit ${head_sha}: ${run.html_url}`);
core.setOutput('enabled', ' but skip');
break;
}
if (run.head_commit && tree_id === run.head_commit.tree_id) {
core.warning(`Successful run for the tree ${tree_id}: ${run.html_url}`);
core.setOutput('enabled', ' but skip');
break;
}
}
} catch (e) {
core.warning(e);
}
windows-build: windows-build:
needs: ci-config needs: ci-config
@ -123,7 +83,6 @@ jobs:
runs-on: windows-latest runs-on: windows-latest
needs: [windows-build] needs: [windows-build]
strategy: strategy:
fail-fast: false
matrix: matrix:
nr: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] nr: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
steps: steps:
@ -186,6 +145,13 @@ jobs:
## Unzip and remove the artifact ## Unzip and remove the artifact
unzip artifacts.zip unzip artifacts.zip
rm artifacts.zip rm artifacts.zip
- name: generate Visual Studio solution
shell: powershell
run: |
& .\git-sdk-64-minimal\usr\bin\bash.exe -lc @"
make NDEBUG=1 DEVELOPER=1 vcxproj
"@
if (!$?) { exit(1) }
- name: download vcpkg artifacts - name: download vcpkg artifacts
shell: powershell shell: powershell
run: | run: |
@ -196,17 +162,7 @@ jobs:
Expand-Archive compat.zip -DestinationPath . -Force Expand-Archive compat.zip -DestinationPath . -Force
Remove-Item compat.zip Remove-Item compat.zip
- name: add msbuild to PATH - name: add msbuild to PATH
uses: microsoft/setup-msbuild@v1 uses: microsoft/setup-msbuild@v1.0.0
- name: copy dlls to root
shell: powershell
run: |
& compat\vcbuild\vcpkg_copy_dlls.bat release
if (!$?) { exit(1) }
- name: generate Visual Studio solution
shell: bash
run: |
cmake `pwd`/contrib/buildsystems/ -DCMAKE_PREFIX_PATH=`pwd`/compat/vcbuild/vcpkg/installed/x64-windows \
-DMSGFMT_EXE=`pwd`/git-sdk-64-minimal/mingw64/bin/msgfmt.exe -DPERL_TESTS=OFF -DPYTHON_TESTS=OFF -DCURL_NO_CURL_CMAKE=ON
- name: MSBuild - name: MSBuild
run: msbuild git.sln -property:Configuration=Release -property:Platform=x64 -maxCpuCount:4 -property:PlatformToolset=v142 run: msbuild git.sln -property:Configuration=Release -property:Platform=x64 -maxCpuCount:4 -property:PlatformToolset=v142
- name: bundle artifact tar - name: bundle artifact tar
@ -215,6 +171,8 @@ jobs:
MSVC: 1 MSVC: 1
VCPKG_ROOT: ${{github.workspace}}\compat\vcbuild\vcpkg VCPKG_ROOT: ${{github.workspace}}\compat\vcbuild\vcpkg
run: | run: |
& compat\vcbuild\vcpkg_copy_dlls.bat release
if (!$?) { exit(1) }
& git-sdk-64-minimal\usr\bin\bash.exe -lc @" & git-sdk-64-minimal\usr\bin\bash.exe -lc @"
mkdir -p artifacts && mkdir -p artifacts &&
eval \"`$(make -n artifacts-tar INCLUDE_DLLS_IN_ARTIFACTS=YesPlease ARTIFACTS_DIRECTORY=artifacts 2>&1 | grep ^tar)\" eval \"`$(make -n artifacts-tar INCLUDE_DLLS_IN_ARTIFACTS=YesPlease ARTIFACTS_DIRECTORY=artifacts 2>&1 | grep ^tar)\"
@ -228,7 +186,6 @@ jobs:
runs-on: windows-latest runs-on: windows-latest
needs: [vs-build, windows-build] needs: [vs-build, windows-build]
strategy: strategy:
fail-fast: false
matrix: matrix:
nr: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] nr: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
steps: steps:
@ -246,7 +203,7 @@ jobs:
- name: extract build artifacts - name: extract build artifacts
shell: bash shell: bash
run: tar xf artifacts.tar.gz run: tar xf artifacts.tar.gz
- name: test - name: test (parallel)
shell: powershell shell: powershell
env: env:
MSYSTEM: MINGW64 MSYSTEM: MINGW64
@ -257,24 +214,16 @@ jobs:
# Let Git ignore the SDK and the test-cache # Let Git ignore the SDK and the test-cache
printf '%s\n' /git-sdk-64-minimal/ /test-cache/ >>.git/info/exclude printf '%s\n' /git-sdk-64-minimal/ /test-cache/ >>.git/info/exclude
ci/run-test-slice.sh ${{matrix.nr}} 10 cd t &&
PATH=\"`$PWD/helper:`$PATH\" &&
test-tool.exe run-command testsuite --jobs=10 -V -x --write-junit-xml \
`$(test-tool.exe path-utils slice-tests \
${{matrix.nr}} 10 t[0-9]*.sh)
"@ "@
- name: ci/print-test-failures.sh
if: failure()
shell: powershell
run: |
& .\git-sdk-64-minimal\usr\bin\bash.exe -lc ci/print-test-failures.sh
- name: Upload failed tests' directories
if: failure() && env.FAILED_TEST_ARTIFACTS != ''
uses: actions/upload-artifact@v1
with:
name: failed-tests-windows
path: ${{env.FAILED_TEST_ARTIFACTS}}
regular: regular:
needs: ci-config needs: ci-config
if: needs.ci-config.outputs.enabled == 'yes' if: needs.ci-config.outputs.enabled == 'yes'
strategy: strategy:
fail-fast: false
matrix: matrix:
vector: vector:
- jobname: linux-clang - jobname: linux-clang
@ -289,7 +238,7 @@ jobs:
- jobname: osx-gcc - jobname: osx-gcc
cc: gcc cc: gcc
pool: macos-latest pool: macos-latest
- jobname: linux-gcc-default - jobname: GETTEXT_POISON
cc: gcc cc: gcc
pool: ubuntu-latest pool: ubuntu-latest
env: env:
@ -312,7 +261,6 @@ jobs:
needs: ci-config needs: ci-config
if: needs.ci-config.outputs.enabled == 'yes' if: needs.ci-config.outputs.enabled == 'yes'
strategy: strategy:
fail-fast: false
matrix: matrix:
vector: vector:
- jobname: linux-musl - jobname: linux-musl
@ -340,7 +288,7 @@ jobs:
if: needs.ci-config.outputs.enabled == 'yes' if: needs.ci-config.outputs.enabled == 'yes'
env: env:
jobname: StaticAnalysis jobname: StaticAnalysis
runs-on: ubuntu-18.04 runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v1 - uses: actions/checkout@v1
- run: ci/install-dependencies.sh - run: ci/install-dependencies.sh

10
.gitignore vendored
View File

@ -67,7 +67,6 @@
/git-filter-branch /git-filter-branch
/git-fmt-merge-msg /git-fmt-merge-msg
/git-for-each-ref /git-for-each-ref
/git-for-each-repo
/git-format-patch /git-format-patch
/git-fsck /git-fsck
/git-fsck-objects /git-fsck-objects
@ -91,7 +90,6 @@
/git-ls-tree /git-ls-tree
/git-mailinfo /git-mailinfo
/git-mailsplit /git-mailsplit
/git-maintenance
/git-merge /git-merge
/git-merge-base /git-merge-base
/git-merge-index /git-merge-index
@ -115,6 +113,7 @@
/git-pack-redundant /git-pack-redundant
/git-pack-objects /git-pack-objects
/git-pack-refs /git-pack-refs
/git-parse-remote
/git-patch-id /git-patch-id
/git-prune /git-prune
/git-prune-packed /git-prune-packed
@ -134,6 +133,8 @@
/git-remote-ftps /git-remote-ftps
/git-remote-fd /git-remote-fd
/git-remote-ext /git-remote-ext
/git-remote-testpy
/git-remote-testsvn
/git-repack /git-repack
/git-replace /git-replace
/git-request-pull /git-request-pull
@ -146,9 +147,11 @@
/git-rm /git-rm
/git-send-email /git-send-email
/git-send-pack /git-send-pack
/git-serve
/git-sh-i18n /git-sh-i18n
/git-sh-i18n--envsubst /git-sh-i18n--envsubst
/git-sh-setup /git-sh-setup
/git-sh-i18n
/git-shell /git-shell
/git-shortlog /git-shortlog
/git-show /git-show
@ -194,7 +197,6 @@
/git.spec /git.spec
*.exe *.exe
*.[aos] *.[aos]
*.o.json
*.py[co] *.py[co]
.depend/ .depend/
*.gcda *.gcda
@ -216,7 +218,6 @@
/tags /tags
/TAGS /TAGS
/cscope* /cscope*
/compile_commands.json
*.hcc *.hcc
*.obj *.obj
*.lib *.lib
@ -239,4 +240,3 @@ Release/
/git.VC.VC.opendb /git.VC.VC.opendb
/git.VC.db /git.VC.db
*.dSYM *.dSYM
/contrib/buildsystems/out

View File

@ -16,7 +16,7 @@ compiler:
matrix: matrix:
include: include:
- env: jobname=linux-gcc-default - env: jobname=GETTEXT_POISON
os: linux os: linux
compiler: compiler:
addons: addons:

View File

@ -8,64 +8,73 @@ this code of conduct may be banned from the community.
## Our Pledge ## Our Pledge
We as members, contributors, and leaders pledge to make participation in our In the interest of fostering an open and welcoming environment, we as
community a harassment-free experience for everyone, regardless of age, body contributors and maintainers pledge to make participation in our project and
size, visible or invisible disability, ethnicity, sex characteristics, gender our community a harassment-free experience for everyone, regardless of age,
identity and expression, level of experience, education, socio-economic status, body size, disability, ethnicity, sex characteristics, gender identity and
nationality, personal appearance, race, religion, or sexual identity expression, level of experience, education, socio-economic status,
and orientation. nationality, personal appearance, race, religion, or sexual identity and
orientation.
We pledge to act and interact in ways that contribute to an open, welcoming,
diverse, inclusive, and healthy community.
## Our Standards ## Our Standards
Examples of behavior that contributes to a positive environment for our Examples of behavior that contributes to creating a positive environment
community include: include:
* Demonstrating empathy and kindness toward other people * Using welcoming and inclusive language
* Being respectful of differing opinions, viewpoints, and experiences * Being respectful of differing viewpoints and experiences
* Giving and gracefully accepting constructive feedback * Gracefully accepting constructive criticism
* Accepting responsibility and apologizing to those affected by our mistakes, * Focusing on what is best for the community
and learning from the experience * Showing empathy towards other community members
* Focusing on what is best not just for us as individuals, but for the
overall community
Examples of unacceptable behavior include: Examples of unacceptable behavior by participants include:
* The use of sexualized language or imagery, and sexual attention or * The use of sexualized language or imagery and unwelcome sexual attention or
advances of any kind advances
* Trolling, insulting or derogatory comments, and personal or political attacks * Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment * Public or private harassment
* Publishing others' private information, such as a physical or email * Publishing others' private information, such as a physical or electronic
address, without their explicit permission address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a * Other conduct which could reasonably be considered inappropriate in a
professional setting professional setting
## Enforcement Responsibilities ## Our Responsibilities
Community leaders are responsible for clarifying and enforcing our standards of Project maintainers are responsible for clarifying the standards of acceptable
acceptable behavior and will take appropriate and fair corrective action in behavior and are expected to take appropriate and fair corrective action in
response to any behavior that they deem inappropriate, threatening, offensive, response to any instances of unacceptable behavior.
or harmful.
Community leaders have the right and responsibility to remove, edit, or reject Project maintainers have the right and responsibility to remove, edit, or
comments, commits, code, wiki edits, issues, and other contributions that are reject comments, commits, code, wiki edits, issues, and other contributions
not aligned to this Code of Conduct, and will communicate reasons for moderation that are not aligned to this Code of Conduct, or to ban temporarily or
decisions when appropriate. permanently any contributor for other behaviors that they deem inappropriate,
threatening, offensive, or harmful.
## Scope ## Scope
This Code of Conduct applies within all community spaces, and also applies when This Code of Conduct applies within all project spaces, and it also applies
an individual is officially representing the community in public spaces. when an individual is representing the project or its community in public
Examples of representing our community include using an official e-mail address, spaces. Examples of representing a project or community include using an
posting via an official social media account, or acting as an appointed official project e-mail address, posting via an official social media account,
representative at an online or offline event. or acting as an appointed representative at an online or offline event.
Representation of a project may be further defined and clarified by project
maintainers.
## Enforcement ## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported to the community leaders responsible for enforcement at reported by contacting the project team at git@sfconservancy.org. All
complaints will be reviewed and investigated and will result in a response
that is deemed necessary and appropriate to the circumstances. The project
team is obligated to maintain confidentiality with regard to the reporter of
an incident. Further details of specific enforcement policies may be posted
separately.
Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.
The project leadership team can be contacted by email as a whole at
git@sfconservancy.org, or individually: git@sfconservancy.org, or individually:
- Ævar Arnfjörð Bjarmason <avarab@gmail.com> - Ævar Arnfjörð Bjarmason <avarab@gmail.com>
@ -73,73 +82,12 @@ git@sfconservancy.org, or individually:
- Jeff King <peff@peff.net> - Jeff King <peff@peff.net>
- Junio C Hamano <gitster@pobox.com> - Junio C Hamano <gitster@pobox.com>
All complaints will be reviewed and investigated promptly and fairly.
All community leaders are obligated to respect the privacy and security of the
reporter of any incident.
## Enforcement Guidelines
Community leaders will follow these Community Impact Guidelines in determining
the consequences for any action they deem in violation of this Code of Conduct:
### 1. Correction
**Community Impact**: Use of inappropriate language or other behavior deemed
unprofessional or unwelcome in the community.
**Consequence**: A private, written warning from community leaders, providing
clarity around the nature of the violation and an explanation of why the
behavior was inappropriate. A public apology may be requested.
### 2. Warning
**Community Impact**: A violation through a single incident or series
of actions.
**Consequence**: A warning with consequences for continued behavior. No
interaction with the people involved, including unsolicited interaction with
those enforcing the Code of Conduct, for a specified period of time. This
includes avoiding interactions in community spaces as well as external channels
like social media. Violating these terms may lead to a temporary or
permanent ban.
### 3. Temporary Ban
**Community Impact**: A serious violation of community standards, including
sustained inappropriate behavior.
**Consequence**: A temporary ban from any sort of interaction or public
communication with the community for a specified period of time. No public or
private interaction with the people involved, including unsolicited interaction
with those enforcing the Code of Conduct, is allowed during this period.
Violating these terms may lead to a permanent ban.
### 4. Permanent Ban
**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
individual, or aggression toward or disparagement of classes of individuals.
**Consequence**: A permanent ban from any sort of public interaction within
the community.
## Attribution ## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage], This Code of Conduct is adapted from the [Contributor Covenant][homepage],
version 2.0, available at version 1.4, available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
[https://www.contributor-covenant.org/version/2/0/code_of_conduct.html][v2.0].
Community Impact Guidelines were inspired by
[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
For answers to common questions about this code of conduct, see the FAQ at
[https://www.contributor-covenant.org/faq][FAQ]. Translations are available
at [https://www.contributor-covenant.org/translations][translations].
[homepage]: https://www.contributor-covenant.org [homepage]: https://www.contributor-covenant.org
[v2.0]: https://www.contributor-covenant.org/version/2/0/code_of_conduct.html
[Mozilla CoC]: https://github.com/mozilla/diversity
[FAQ]: https://www.contributor-covenant.org/faq
[translations]: https://www.contributor-covenant.org/translations
For answers to common questions about this code of conduct, see
https://www.contributor-covenant.org/faq

View File

@ -17,11 +17,9 @@ MAN1_TXT += git.txt
MAN1_TXT += gitk.txt MAN1_TXT += gitk.txt
MAN1_TXT += gitweb.txt MAN1_TXT += gitweb.txt
# man5 / man7 guides (note: new guides should also be added to command-list.txt)
MAN5_TXT += gitattributes.txt MAN5_TXT += gitattributes.txt
MAN5_TXT += githooks.txt MAN5_TXT += githooks.txt
MAN5_TXT += gitignore.txt MAN5_TXT += gitignore.txt
MAN5_TXT += gitmailmap.txt
MAN5_TXT += gitmodules.txt MAN5_TXT += gitmodules.txt
MAN5_TXT += gitrepository-layout.txt MAN5_TXT += gitrepository-layout.txt
MAN5_TXT += gitweb.conf.txt MAN5_TXT += gitweb.conf.txt
@ -273,9 +271,7 @@ install-html: html
../GIT-VERSION-FILE: FORCE ../GIT-VERSION-FILE: FORCE
$(QUIET_SUBDIR0)../ $(QUIET_SUBDIR1) GIT-VERSION-FILE $(QUIET_SUBDIR0)../ $(QUIET_SUBDIR1) GIT-VERSION-FILE
ifneq ($(MAKECMDGOALS),clean)
-include ../GIT-VERSION-FILE -include ../GIT-VERSION-FILE
endif
# #
# Determine "include::" file references in asciidoc files. # Determine "include::" file references in asciidoc files.
@ -289,9 +285,7 @@ doc.dep : $(docdep_prereqs) $(wildcard *.txt) $(wildcard config/*.txt) build-doc
$(PERL_PATH) ./build-docdep.perl >$@+ $(QUIET_STDERR) && \ $(PERL_PATH) ./build-docdep.perl >$@+ $(QUIET_STDERR) && \
mv $@+ $@ mv $@+ $@
ifneq ($(MAKECMDGOALS),clean)
-include doc.dep -include doc.dep
endif
cmds_txt = cmds-ancillaryinterrogators.txt \ cmds_txt = cmds-ancillaryinterrogators.txt \
cmds-ancillarymanipulators.txt \ cmds-ancillarymanipulators.txt \
@ -300,7 +294,6 @@ cmds_txt = cmds-ancillaryinterrogators.txt \
cmds-plumbingmanipulators.txt \ cmds-plumbingmanipulators.txt \
cmds-synchingrepositories.txt \ cmds-synchingrepositories.txt \
cmds-synchelpers.txt \ cmds-synchelpers.txt \
cmds-guide.txt \
cmds-purehelpers.txt \ cmds-purehelpers.txt \
cmds-foreignscminterface.txt cmds-foreignscminterface.txt
@ -308,7 +301,7 @@ $(cmds_txt): cmd-list.made
cmd-list.made: cmd-list.perl ../command-list.txt $(MAN1_TXT) cmd-list.made: cmd-list.perl ../command-list.txt $(MAN1_TXT)
$(QUIET_GEN)$(RM) $@ && \ $(QUIET_GEN)$(RM) $@ && \
$(PERL_PATH) ./cmd-list.perl ../command-list.txt $(cmds_txt) $(QUIET_STDERR) && \ $(PERL_PATH) ./cmd-list.perl ../command-list.txt $(QUIET_STDERR) && \
date >$@ date >$@
mergetools_txt = mergetools-diff.txt mergetools-merge.txt mergetools_txt = mergetools-diff.txt mergetools-merge.txt
@ -385,10 +378,7 @@ SubmittingPatches.txt: SubmittingPatches
$(QUIET_GEN) cp $< $@ $(QUIET_GEN) cp $< $@
XSLT = docbook.xsl XSLT = docbook.xsl
XSLTOPTS = XSLTOPTS = --xinclude --stringparam html.stylesheet docbook-xsl.css
XSLTOPTS += --xinclude
XSLTOPTS += --stringparam html.stylesheet docbook-xsl.css
XSLTOPTS += --param generate.consistent.ids 1
user-manual.html: user-manual.xml $(XSLT) user-manual.html: user-manual.xml $(XSLT)
$(QUIET_XSLTPROC)$(RM) $@+ $@ && \ $(QUIET_XSLTPROC)$(RM) $@+ $@ && \

View File

@ -249,7 +249,7 @@ component you're working on, followed by a blank line (always required) and then
the body of your commit message, which should provide the bulk of the context. the body of your commit message, which should provide the bulk of the context.
Remember to be explicit and provide the "Why" of your change, especially if it Remember to be explicit and provide the "Why" of your change, especially if it
couldn't easily be understood from your diff. When editing your commit message, couldn't easily be understood from your diff. When editing your commit message,
don't remove the `Signed-off-by` trailer which was added by `-s` above. don't remove the Signed-off-by line which was added by `-s` above.
---- ----
psuh: add a built-in by popular demand psuh: add a built-in by popular demand
@ -319,14 +319,14 @@ function body:
... ...
git_config(git_default_config, NULL); git_config(git_default_config, NULL);
if (git_config_get_string_tmp("user.name", &cfg_name) > 0) if (git_config_get_string_const("user.name", &cfg_name) > 0)
printf(_("No name is found in config\n")); printf(_("No name is found in config\n"));
else else
printf(_("Your name: %s\n"), cfg_name); printf(_("Your name: %s\n"), cfg_name);
---- ----
`git_config()` will grab the configuration from config files known to Git and `git_config()` will grab the configuration from config files known to Git and
apply standard precedence rules. `git_config_get_string_tmp()` will look up apply standard precedence rules. `git_config_get_string_const()` will look up
a specific key ("user.name") and give you the value. There are a number of a specific key ("user.name") and give you the value. There are a number of
single-key lookup functions like this one; you can see them all (and more info single-key lookup functions like this one; you can see them all (and more info
about how to use `git_config()`) in `Documentation/technical/api-config.txt`. about how to use `git_config()`) in `Documentation/technical/api-config.txt`.
@ -507,9 +507,6 @@ documentation is consistent with other Git and UNIX manpages; this makes life
easier for your user, who can skip to the section they know contains the easier for your user, who can skip to the section they know contains the
information they need. information they need.
NOTE: Before trying to build the docs, make sure you have the package `asciidoc`
installed.
Now that you've written your manpage, you'll need to build it explicitly. We Now that you've written your manpage, you'll need to build it explicitly. We
convert your AsciiDoc to troff which is man-readable like so: convert your AsciiDoc to troff which is man-readable like so:
@ -525,6 +522,8 @@ $ make -C Documentation/ git-psuh.1
$ man Documentation/git-psuh.1 $ man Documentation/git-psuh.1
---- ----
NOTE: You may need to install the package `asciidoc` to get this to work.
While this isn't as satisfying as running through `git help`, you can at least While this isn't as satisfying as running through `git help`, you can at least
check that your help page looks right. check that your help page looks right.
@ -664,7 +663,7 @@ mention the right animal somewhere:
---- ----
test_expect_success 'runs correctly with no args and good output' ' test_expect_success 'runs correctly with no args and good output' '
git psuh >actual && git psuh >actual &&
grep Pony actual test_i18ngrep Pony actual
' '
---- ----
@ -1143,25 +1142,11 @@ After a few days, you will hopefully receive a reply to your patchset with some
comments. Woohoo! Now you can get back to work. comments. Woohoo! Now you can get back to work.
It's good manners to reply to each comment, notifying the reviewer that you have It's good manners to reply to each comment, notifying the reviewer that you have
made the change suggested, feel the original is better, or that the comment made the change requested, feel the original is better, or that the comment
inspired you to do something a new way which is superior to both the original inspired you to do something a new way which is superior to both the original
and the suggested change. This way reviewers don't need to inspect your v2 to and the suggested change. This way reviewers don't need to inspect your v2 to
figure out whether you implemented their comment or not. figure out whether you implemented their comment or not.
Reviewers may ask you about what you wrote in the patchset, either in
the proposed commit log message or in the changes themselves. You
should answer these questions in your response messages, but often the
reason why reviewers asked these questions to understand what you meant
to write is because your patchset needed clarification to be understood.
Do not be satisfied by just answering their questions in your response
and hear them say that they now understand what you wanted to say.
Update your patches to clarify the points reviewers had trouble with,
and prepare your v2; the words you used to explain your v1 to answer
reviewers' questions may be useful thing to use. Your goal is to make
your v2 clear enough so that it becomes unnecessary for you to give the
same explanation to the next person who reads it.
If you are going to push back on a comment, be polite and explain why you feel If you are going to push back on a comment, be polite and explain why you feel
your original is better; be prepared that the reviewer may still disagree with your original is better; be prepared that the reviewer may still disagree with
you, and the rest of the community may weigh in on one side or the other. As you, and the rest of the community may weigh in on one side or the other. As

View File

@ -182,6 +182,30 @@ its `init_log_defaults()` sets its own state (`decoration_style`) and asks
`grep` and `diff` to initialize themselves by calling each of their `grep` and `diff` to initialize themselves by calling each of their
initialization functions. initialization functions.
For our first example within `git walken`, we don't intend to use any other
components within Git, and we don't have any configuration to do. However, we
may want to add some later, so for now, we can add an empty placeholder. Create
a new function in `builtin/walken.c`:
----
static void init_walken_defaults(void)
{
/*
* We don't actually need the same components `git log` does; leave this
* empty for now.
*/
}
----
Make sure to add a line invoking it inside of `cmd_walken()`.
----
int cmd_walken(int argc, const char **argv, const char *prefix)
{
init_walken_defaults();
}
----
==== Configuring From `.gitconfig` ==== Configuring From `.gitconfig`
Next, we should have a look at any relevant configuration settings (i.e., Next, we should have a look at any relevant configuration settings (i.e.,
@ -364,9 +388,17 @@ Next, let's try to filter the commits we see based on their author. This is
equivalent to running `git log --author=<pattern>`. We can add a filter by equivalent to running `git log --author=<pattern>`. We can add a filter by
modifying `rev_info.grep_filter`, which is a `struct grep_opt`. modifying `rev_info.grep_filter`, which is a `struct grep_opt`.
First some setup. Add `grep_config()` to `git_walken_config()`: First some setup. Add `init_grep_defaults()` to `init_walken_defaults()` and add
`grep_config()` to `git_walken_config()`:
---- ----
static void init_walken_defaults(void)
{
init_grep_defaults(the_repository);
}
...
static int git_walken_config(const char *var, const char *value, void *cb) static int git_walken_config(const char *var, const char *value, void *cb)
{ {
grep_config(var, value, cb); grep_config(var, value, cb);

View File

@ -0,0 +1,16 @@
Git v2.17.6 Release Notes
=========================
This release addresses the security issues CVE-2021-21300.
Fixes since v2.17.5
-------------------
* CVE-2021-21300:
On case-insensitive file systems with support for symbolic links,
if Git is configured globally to apply delay-capable clean/smudge
filters (such as Git LFS), Git could be fooled into running
remote code during a clone.
Credit for finding and fixing this vulnerability goes to Matheus
Tavares, helped by Johannes Schindelin.

View File

@ -0,0 +1,6 @@
Git v2.18.5 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6 to address
the security issue CVE-2021-21300; see the release notes for that
version for details.

View File

@ -0,0 +1,6 @@
Git v2.19.6 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6 and
v2.18.5 to address the security issue CVE-2021-21300; see the
release notes for these versions for details.

View File

@ -0,0 +1,6 @@
Git v2.20.5 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6, v2.18.5
and v2.19.6 to address the security issue CVE-2021-21300; see
the release notes for these versions for details.

View File

@ -0,0 +1,6 @@
Git v2.21.4 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6, v2.18.5,
v2.19.6 and v2.20.5 to address the security issue CVE-2021-21300;
see the release notes for these versions for details.

View File

@ -0,0 +1,7 @@
Git v2.22.5 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6,
v2.18.5, v2.19.6, v2.20.5 and v2.21.4 to address the security
issue CVE-2021-21300; see the release notes for these versions
for details.

View File

@ -0,0 +1,7 @@
Git v2.23.4 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6, v2.18.5,
v2.19.6, v2.20.5, v2.21.4 and v2.22.5 to address the security
issue CVE-2021-21300; see the release notes for these versions
for details.

View File

@ -0,0 +1,7 @@
Git v2.24.4 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6, v2.18.5,
v2.19.6, v2.20.5, v2.21.4, v2.22.5 and v2.23.4 to address the
security issue CVE-2021-21300; see the release notes for these
versions for details.

View File

@ -0,0 +1,7 @@
Git v2.25.5 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6, v2.18.5,
v2.19.6, v2.20.5, v2.21.4, v2.22.5, v2.23.4 and v2.24.4 to address
the security issue CVE-2021-21300; see the release notes for
these versions for details.

View File

@ -0,0 +1,7 @@
Git v2.26.3 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6, v2.18.5,
v2.19.6, v2.20.5, v2.21.4, v2.22.5, v2.23.4, v2.24.4 and v2.25.5
to address the security issue CVE-2021-21300; see the release
notes for these versions for details.

View File

@ -0,0 +1,7 @@
Git v2.27.1 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6, v2.18.5,
v2.19.6, v2.20.5, v2.21.4, v2.22.5, v2.23.4, v2.24.4, v2.25.5
and v2.26.3 to address the security issue CVE-2021-21300; see
the release notes for these versions for details.

View File

@ -0,0 +1,7 @@
Git v2.28.1 Release Notes
=========================
This release merges up the fixes that appear in v2.17.6, v2.18.5,
v2.19.6, v2.20.5, v2.21.4, v2.22.5, v2.23.4, v2.24.4, v2.25.5,
v2.26.3 and v2.27.1 to address the security issue CVE-2021-21300;
see the release notes for these versions for details.

View File

@ -1,514 +0,0 @@
Git 2.29 Release Notes
======================
Updates since v2.28
-------------------
UI, Workflows & Features
* "git help log" has been enhanced by sharing more material from the
documentation for the underlying "git rev-list" command.
* "git for-each-ref --format=<>" learned %(contents:size).
* "git merge" learned to selectively omit " into <branch>" at the end
of the title of default merge message with merge.suppressDest
configuration.
* The component to respond to "git fetch" request is made more
configurable to selectively allow or reject object filtering
specification used for partial cloning.
* Stop when "sendmail.*" configuration variables are defined, which
could be a mistaken attempt to define "sendemail.*" variables.
* The existing backends for "git mergetool" based on variants of vim
have been refactored and then support for "nvim" has been added.
* "git bisect" learns the "--first-parent" option to find the first
breakage along the first-parent chain.
* "git log --first-parent -p" showed patches only for single-parent
commits on the first-parent chain; the "--first-parent" option has
been made to imply "-m". Use "--no-diff-merges" to restore the
previous behaviour to omit patches for merge commits.
* The commit labels used to explain each side of conflicted hunks
placed by the sequencer machinery have been made more readable by
humans.
* The "--batch-size" option of "git multi-pack-index repack" command
is now used to specify that very small packfiles are collected into
one until the total size roughly exceeds it.
* The recent addition of SHA-256 support is marked as experimental in
the documentation.
* "git fetch" learned --no-write-fetch-head option to avoid writing
the FETCH_HEAD file.
* Command line completion (in contrib/) usually omits redundant,
deprecated and/or dangerous options from its output; it learned to
optionally include all of them.
* The output from the "diff" family of the commands had abbreviated
object names of blobs involved in the patch, but its length was not
affected by the --abbrev option. Now it is.
* "git worktree" gained a "repair" subcommand to help users recover
after moving the worktrees or repository manually without telling
Git. Also, "git init --separate-git-dir" no longer corrupts
administrative data related to linked worktrees.
* The "--format=" option to the "for-each-ref" command and friends
learned a few more tricks, e.g. the ":short" suffix that applies to
"objectname" now also can be used for "parent", "tree", etc.
* "git worktree add" learns that the "-d" is a synonym to "--detach"
option to create a new worktree without being on a branch.
* "format-patch --range-diff=<prev> <origin>..HEAD" has been taught
not to ignore <origin> when <prev> is a single version.
* "add -p" now allows editing paths that were only added in intent.
* The 'meld' backend of the "git mergetool" learned to give the
underlying 'meld' the '--auto-merge' option, which would help
reduce the amount of text that requires manual merging.
* "git for-each-ref" and friends that list refs used to allow only
one --merged or --no-merged to filter them; they learned to take
combination of both kind of filtering.
* "git maintenance", a "git gc"'s big brother, has been introduced to
take care of more repository maintenance tasks, not limited to the
object database cleaning.
* "git receive-pack" that accepts requests by "git push" learned to
outsource most of the ref updates to the new "proc-receive" hook.
* "git push" that wants to be atomic and wants to send push
certificate learned not to prepare and sign the push certificate
when it fails the local check (hence due to atomicity it is known
that no certificate is needed).
* "git commit-graph write" learned to limit the number of bloom
filters that are computed from scratch with the --max-new-filters
option.
* The transport protocol v2 has become the default again.
* The installation procedure learned to optionally omit "git-foo"
executable files for each 'foo' built-in subcommand, which are only
required by old timers that still rely on the age old promise that
prepending "git --exec-path" output to PATH early in their script
will keep the "git-foo" calls they wrote working.
* The command line completion (in contrib/) learned that "git restore
-s <TAB>" is often followed by a refname.
* "git shortlog" has been taught to group commits by the contents of
the trailer lines, like "Reviewed-by:", "Coauthored-by:", etc.
* "git archive" learns the "--add-file" option to include untracked
files into a snapshot from a tree-ish.
* "git fetch" and "git push" support negative refspecs.
* "git format-patch" learns to take "whenAble" as a possible value
for the format.useAutoBase configuration variable to become no-op
when the automatically computed base does not make sense.
* Credential helpers are now allowed to terminate lines with CRLF
line ending, as well as LF line ending.
Performance, Internal Implementation, Development Support etc.
* The changed-path Bloom filter is improved using ideas from an
independent implementation.
* Updates to the changed-paths bloom filter.
* The test framework has been updated so that most tests will run
with predictable (artificial) timestamps.
* Preliminary clean-up of the refs API in preparation for adding a
new refs backend "reftable".
* Dev support to limit the use of test_must_fail to only git commands.
* While packing many objects in a repository with a promissor remote,
lazily fetching missing objects from the promissor remote one by
one may be inefficient---the code now attempts to fetch all the
missing objects in batch (obviously this won't work for a lazy
clone that lazily fetches tree objects as you cannot even enumerate
what blobs are missing until you learn which trees are missing).
* The pretend-object mechanism checks if the given object already
exists in the object store before deciding to keep the data
in-core, but the check would have triggered lazy fetching of such
an object from a promissor remote.
* The argv_array API is useful for not just managing argv but any
"vector" (NULL-terminated array) of strings, and has seen adoption
to a certain degree. It has been renamed to "strvec" to reduce the
barrier to adoption.
* The final leg of SHA-256 transition plus doc updates. Note that
there is no interoperability between SHA-1 and SHA-256
repositories yet.
* CMake support to build with MSVC for Windows bypassing the Makefile.
* A new helper function has_object() has been introduced to make it
easier to mark object existence checks that do and don't want to
trigger lazy fetches, and a few such checks are converted using it.
* A no-op replacement function implemented as a C preprocessor macro
does not perform as good a job as one implemented as a "static
inline" function in catching errors in parameters; replace the
former with the latter in <git-compat-util.h> header.
* Test framework update.
(merge d572f52a64 es/test-cmp-typocatcher later to maint).
* Updates to "git merge" tests, in preparation for a new merge
strategy backend.
* midx and commit-graph files now use the byte defined in their file
format specification for identifying the hash function used for
object names.
* The FETCH_HEAD is now always read from the filesystem regardless of
the ref backend in use, as its format is much richer than the
normal refs, and written directly by "git fetch" as a plain file..
* An unused binary has been discarded, and and a bunch of commands
have been turned into into built-in.
* A handful of places in in-tree code still relied on being able to
execute the git subcommands, especially built-ins, in "git-foo"
form, which have been corrected.
* When a packfile is removed by "git repack", multi-pack-index gets
cleared; the code was taught to do so less aggressively by first
checking if the midx actually refers to a pack that no longer
exists.
* Internal API clean-up to handle two options "diff-index" and "log"
have, which happen to share the same short form, more sensibly.
* The "add -i/-p" machinery has been written in C but it is not used
by default yet. It is made default to those who are participating
in feature.experimental experiment.
* Allow maintainers to tweak $(TAR) invocations done while making
distribution tarballs.
* "git index-pack" learned to resolve deltified objects with greater
parallelism.
* "diff-highlight" (in contrib/) had a logic to flush its output upon
seeing a blank line but the way it detected a blank line was broken.
* The logic to skip testing on the tagged commit and the tag itself
was not quite consistent which led to failure of Windows test
tasks. It has been revamped to consistently skip revisions that
have already been tested, based on the tree object of the revision.
Fixes since v2.28
-----------------
* The "mediawiki" remote backend which lives in contrib/mw-to-git/
and is not built with git by default, had an RCE bug allowing a
malicious MediaWiki server operator to inject arbitrary commands
for execution by a cloning client. This has been fixed.
The bug was discovered and reported by Joern Schneeweisz of GitLab
to the git-security mailing list. Its practical impact due to the
obscurity of git-remote-mediawiki was deemed small enough to forgo
a dedicated security release.
* "git clone --separate-git-dir=$elsewhere" used to stomp on the
contents of the existing directory $elsewhere, which has been
taught to fail when $elsewhere is not an empty directory.
(merge dfaa209a79 bw/fail-cloning-into-non-empty later to maint).
* With the base fix to 2.27 regresion, any new extensions in a v0
repository would still be silently honored, which is not quite
right. Instead, complain and die loudly.
(merge ec91ffca04 jk/reject-newer-extensions-in-v0 later to maint).
* Fetching from a lazily cloned repository resulted at the server
side in attempts to lazy fetch objects that the client side has,
many of which will not be available from the third-party anyway.
(merge 77aa0941ce jt/avoid-lazy-fetching-upon-have-check later to maint).
* Fix to an ancient bug caused by an over-eager attempt for
optimization.
(merge a98f7fb366 rs/add-index-entry-optim-fix later to maint).
* Pushing a ref whose name contains non-ASCII character with the
"--force-with-lease" option did not work over smart HTTP protocol,
which has been corrected.
(merge cd85b447bf bc/push-cas-cquoted-refname later to maint).
* "git mv src dst", when src is an unmerged path, errored out
correctly but with an incorrect error message to claim that src is
not tracked, which has been clarified.
(merge 9b906af657 ct/mv-unmerged-path-error later to maint).
* Fix to a regression introduced during 2.27 cycle.
(merge cada7308ad en/fill-directory-exponential later to maint).
* Command line completion (in contrib/) update.
(merge 688b87c81b mp/complete-show-color-moved later to maint).
* All "mergy" operations that internally use the merge-recursive
machinery should honor the merge.renormalize configuration, but
many of them didn't.
* Doc cleanup around "worktree".
(merge dc9c144be5 es/worktree-doc-cleanups later to maint).
* The "git blame --first-parent" option was not documented, but now
it is.
(merge 11bc12ae1e rp/blame-first-parent-doc later to maint).
* The logic to find the ref transaction hook script attempted to
cache the path to the found hook without realizing that it needed
to keep a copied value, as the API it used returned a transitory
buffer space. This has been corrected.
(merge 09b2aa30c9 ps/ref-transaction-hook later to maint).
* Recent versions of "git diff-files" shows a diff between the index
and the working tree for "intent-to-add" paths as a "new file"
patch; "git apply --cached" should be able to take "git diff-files"
and should act as an equivalent to "git add" for the path, but the
command failed to do so for such a path.
(merge 4c025c667e rp/apply-cached-with-i-t-a later to maint).
* "git diff [<tree-ish>] $path" for a $path that is marked with i-t-a
bit was not showing the mode bits from the working tree.
(merge cb0dd22b82 rp/ita-diff-modefix later to maint).
* Ring buffer with size 4 used for bin-hex translation resulted in a
wrong object name in the sequencer's todo output, which has been
corrected.
(merge 5da69c0dac ak/sequencer-fix-find-uniq-abbrev later to maint).
* When given more than one target line ranges, "git blame -La,b
-Lc,d" was over-eager to coalesce groups of original lines and
showed incorrect results, which has been corrected.
(merge c2ebaa27d6 jk/blame-coalesce-fix later to maint).
* The regexp to identify the function boundary for FORTRAN programs
has been updated.
(merge 75c3b6b2e8 pb/userdiff-fortran-update later to maint).
* A few end-user facing messages have been updated to be
hash-algorithm agnostic.
(merge 4279000d3e jc/object-names-are-not-sha-1 later to maint).
* "unlink" emulation on MinGW has been optimized.
(merge 680e0b4524 jh/mingw-unlink later to maint).
* The purpose of "git init --separate-git-dir" is to initialize a
new project with the repository separate from the working tree,
or, in the case of an existing project, to move the repository
(the .git/ directory) out of the working tree. It does not make
sense to use --separate-git-dir with a bare repository for which
there is no working tree, so disallow its use with bare
repositories.
(merge ccf236a23a es/init-no-separate-git-dir-in-bare later to maint).
* "ls-files -o" mishandled the top-level directory of another git
working tree that hangs in the current git working tree.
(merge ab282aa548 en/dir-nonbare-embedded later to maint).
* Fix some incorrect UNLEAK() annotations.
(merge 3e19816dc0 jk/unleak-fixes later to maint).
* Use more buffered I/O where we used to call many small write(2)s.
(merge a698d67b08 rs/more-buffered-io later to maint).
* The patch-id computation did not ignore the "incomplete last line"
marker like whitespaces.
(merge 82a62015a7 rs/patch-id-with-incomplete-line later to maint).
* Updates into a lazy/partial clone with a submodule did not work
well with transfer.fsckobjects set.
* The parser for "git for-each-ref --format=..." was too loose when
parsing the "%(trailers...)" atom, and forgot that "trailers" and
"trailers:<modifiers>" are the only two allowed forms, which has
been corrected.
(merge 2c22e102f8 hv/ref-filter-trailers-atom-parsing-fix later to maint).
* Long ago, we decided to use 3 threads by default when running the
index-pack task in parallel, which has been adjusted a bit upwards.
(merge fbff95b67f jk/index-pack-w-more-threads later to maint).
* "git restore/checkout --no-overlay" with wildcarded pathspec
mistakenly removed matching paths in subdirectories, which has been
corrected.
(merge bfda204ade rs/checkout-no-overlay-pathspec-fix later to maint).
* The description of --cached/--index options in "git apply --help"
has been updated.
(merge d064702be3 rp/apply-cached-doc later to maint).
* Feeding "$ZERO_OID" to "git log --ignore-missing --stdin", and
running "git log --ignore-missing $ZERO_OID" fell back to start
digging from HEAD; it has been corrected to become a no-op, like
"git log --tags=no-tag-matches-this-pattern" does.
(merge 04a0e98515 jk/rev-input-given-fix later to maint).
* Various callers of run_command API have been modernized.
(merge afbdba391e jc/run-command-use-embedded-args later to maint).
* List of options offered and accepted by "git add -i/-p" were
inconsistent, which have been corrected.
(merge ce910287e7 pw/add-p-allowed-options-fix later to maint).
* "git diff --stat -w" showed 0-line changes for paths whose changes
were only whitespaces, which was not intuitive. We now omit such
paths from the stat output.
(merge 1cf3d5db9b mr/diff-hide-stat-wo-textual-change later to maint).
* It was possible for xrealloc() to send a non-NULL pointer that has
been freed, which has been fixed.
(merge 6479ea4a8a jk/xrealloc-avoid-use-after-free later to maint).
* "git status" has trouble showing where it came from by interpreting
reflog entries that record certain events, e.g. "checkout @{u}", and
gives a hard/fatal error. Even though it inherently is impossible
to give a correct answer because the reflog entries lose some
information (e.g. "@{u}" does not record what branch the user was
on hence which branch 'the upstream' needs to be computed, and even
if the record were available, the relationship between branches may
have changed), at least hide the error and allow "status" to show its
output.
* "git status --short" quoted a path with SP in it when tracked, but
not those that are untracked, ignored or unmerged. They are all
shown quoted consistently.
* "git diff/show" on a change that involves a submodule used to read
the information on commits in the submodule from a wrong repository
and gave a wrong information when the commit-graph is involved.
(merge 85a1ec2c32 mf/submodule-summary-with-correct-repository later to maint).
* Unlike "git config --local", "git config --worktree" did not fail
early and cleanly when started outside a git repository.
(merge 378fe5fc3d mt/config-fail-nongit-early later to maint).
* There is a logic to estimate how many objects are in the
repository, which is meant to run once per process invocation, but
it ran every time the estimated value was requested.
(merge 67bb65de5d jk/dont-count-existing-objects-twice later to maint).
* "git remote set-head" that failed still said something that hints
the operation went through, which was misleading.
(merge 5a07c6c3c2 cs/don-t-pretend-a-failed-remote-set-head-succeeded later to maint).
* "git fetch --all --ipv4/--ipv6" forgot to pass the protocol options
to instances of the "git fetch" that talk to individual remotes,
which has been corrected.
(merge 4e735c1326 ar/fetch-ipversion-in-all later to maint).
* The "unshelve" subcommand of "git p4" incorrectly used commit^N
where it meant to say commit~N to name the Nth generation
ancestor, which has been corrected.
(merge 0acbf5997f ld/p4-unshelve-fix later to maint).
* "git clone" that clones from SHA-1 repository, while
GIT_DEFAULT_HASH set to use SHA-256 already, resulted in an
unusable repository that half-claims to be SHA-256 repository
with SHA-1 objects and refs. This has been corrected.
* Adjust sample hooks for hash algorithm other than SHA-1.
(merge d8d3d632f4 dl/zero-oid-in-hooks later to maint).
* "git range-diff" showed incorrect diffstat, which has been
corrected.
* Earlier we taught "git pull" to warn when the user does not say the
histories need to be merged, rebased or accepts only fast-
forwarding, but the warning triggered for those who have set the
pull.ff configuration variable.
(merge 54200cef86 ah/pull later to maint).
* Compilation fix around type punning.
(merge 176380fd11 jk/drop-unaligned-loads later to maint).
* "git blame --ignore-rev/--ignore-revs-file" failed to validate
their input are valid revision, and failed to take into account
that the user may want to give an annotated tag instead of a
commit, which has been corrected.
(merge 610e2b9240 jc/blame-ignore-fix later to maint).
* "git bisect start X Y", when X and Y are not valid committish
object names, should take X and Y as pathspec, but didn't.
(merge 73c6de06af cc/bisect-start-fix later to maint).
* The explanation of the "scissors line" has been clarified.
(merge 287416dba6 eg/mailinfo-doc-scissors later to maint).
* A race that leads to an access to a free'd data was corrected in
the codepath that reads pack files.
(merge bda959c476 mt/delta-base-cache-races later to maint).
* in_merge_bases_many(), a way to see if a commit is reachable from
any commit in a set of commits, was totally broken when the
commit-graph feature was in use, which has been corrected.
(merge 8791bf1841 ds/in-merge-bases-many-optim-bug later to maint).
* "git submodule update --quiet" did not squelch underlying "rebase"
and "pull" commands.
(merge 3ad0401e9e td/submodule-update-quiet later to maint).
* The lazy fetching done internally to make missing objects available
in a partial clone incorrectly made permanent damage to the partial
clone filter in the repository, which has been corrected.
* "log -c --find-object=X" did not work well to find a merge that
involves a change to an object X from only one parent.
(merge 957876f17d jk/diff-cc-oidfind-fix later to maint).
* Other code cleanup, docfix, build fix, etc.
(merge 84544f2ea3 sk/typofixes later to maint).
(merge b17f411ab5 ar/help-guides-doc later to maint).
(merge 98c6871fad rs/grep-simpler-parse-object-or-die-call later to maint).
(merge 861c4ce141 en/typofixes later to maint).
(merge 60e47f6773 sg/ci-git-path-fix-with-pyenv later to maint).
(merge e2bfa50ac3 jb/doc-packfile-name later to maint).
(merge 918d8ff780 es/worktree-cleanup later to maint).
(merge dc156bc31f ma/t1450-quotefix later to maint).
(merge 56e743426b en/merge-recursive-comment-fixes later to maint).
(merge 7d23ff818f rs/bisect-oid-to-hex-fix later to maint).
(merge de20baf2c9 ny/notes-doc-sample-update later to maint).
(merge f649aaaf82 so/rev-parser-errormessage-fix later to maint).
(merge 6103d58b7f bc/sha-256-cvs-svn-updates later to maint).
(merge ac900fddb7 ma/stop-progress-null-fix later to maint).
(merge e767963ab6 rs/upload-pack-sigchain-fix later to maint).
(merge a831908599 rs/preserve-merges-unused-code-removal later to maint).
(merge 6dfefe70a9 jb/commit-graph-doc-fix later to maint).
(merge 847b37271e pb/set-url-docfix later to maint).
(merge 748f733d54 mt/checkout-entry-dead-code-removal later to maint).
(merge ce820cbd58 dl/subtree-docs later to maint).
(merge 55fe225dde jk/leakfix later to maint).
(merge ee22a29215 so/pretty-abbrev-doc later to maint).
(merge 3100fd5588 jc/post-checkout-doc later to maint).
(merge 17bae89476 pb/doc-external-diff-env later to maint).
(merge 27ed6ccc12 jk/worktree-check-clean-leakfix later to maint).
(merge 1302badd16 ea/blame-use-oideq later to maint).
(merge e6d5a11fed al/t3200-back-on-a-branch later to maint).
(merge 324efcf6b6 pw/add-p-leakfix later to maint).
(merge 1c6ffb546b jk/add-i-fixes later to maint).
(merge e40e936551 cd/commit-graph-doc later to maint).
(merge 0512eabd91 jc/sequencer-stopped-sha-simplify later to maint).
(merge d01141de5a so/combine-diff-simplify later to maint).
(merge 3be01e5ab1 sn/fast-import-doc later to maint).

View File

@ -1,11 +0,0 @@
Git v2.29.1 Release Notes
=========================
This is to fix the build procedure change in 2.28 where we failed to
install a few programs that should be installed in /usr/bin (namely,
receive-pack, upload-archive and upload-pack) when the non-default
SKIP_DASHED_BUILT_INS installation option is in effect.
A minor glitch in a non-default installation may usually not deserve
a hotfix, but I know Git for Windows ship binaries built with this
option, so let's make an exception.

View File

@ -1,12 +0,0 @@
Git v2.29.2 Release Notes
=========================
This release is primarily to fix brown-paper-bag breakages in the
2.29.0 release.
Fixes since v2.29.1
-------------------
* In 2.29, "--committer-date-is-author-date" option of "rebase" and
"am" subcommands lost the e-mail address by mistake, which has been
corrected.

View File

@ -1,401 +0,0 @@
Git 2.30 Release Notes
======================
Updates since v2.29
-------------------
UI, Workflows & Features
* Userdiff for PHP update.
* Userdiff for Rust update.
* Userdiff for CSS update.
* The command line completion script (in contrib/) learned that "git
stash show" takes the options "git diff" takes.
* "git worktree list" now shows if each worktree is locked. This
possibly may open us to show other kinds of states in the future.
* "git maintenance", an extended big brother of "git gc", continues
to evolve.
* "git push --force-with-lease[=<ref>]" can easily be misused to lose
commits unless the user takes good care of their own "git fetch".
A new option "--force-if-includes" attempts to ensure that what is
being force-pushed was created after examining the commit at the
tip of the remote ref that is about to be force-replaced.
* "git clone" learned clone.defaultremotename configuration variable
to customize what nickname to use to call the remote the repository
was cloned from.
* "git checkout" learned to use checkout.guess configuration variable
and enable/disable its "--[no-]guess" option accordingly.
* "git resurrect" script (in contrib/) learned that the object names
may be longer than 40-hex depending on the hash function in use.
* "git diff A...B" learned "git diff --merge-base A B", which is a
longer short-hand to say the same thing.
* A sample 'push-to-checkout' hook, that performs the same as
what the built-in default action does, has been added.
* "git diff" family of commands learned the "-I<regex>" option to
ignore hunks whose changed lines all match the given pattern.
* The userdiff pattern learned to identify the function definition in
POSIX shells and bash.
* "git checkout-index" did not consistently signal an error with its
exit status, but now it does.
* A commit and tag object may have CR at the end of each and
every line (you can create such an object with hash-object or
using --cleanup=verbatim to decline the default clean-up
action), but it would make it impossible to have a blank line
to separate the title from the body of the message. We are now
more lenient and accept a line with lone CR on it as a blank line,
too.
* Exit codes from "git remote add" etc. were not usable by scripted
callers, but now they are.
* "git archive" now allows compression level higher than "-9"
when generating tar.gz output.
* Zsh autocompletion (in contrib/) update.
* The maximum length of output filenames "git format-patch" creates
has become configurable (used to be capped at 64).
* "git rev-parse" learned the "--end-of-options" to help scripts to
safely take a parameter that is supposed to be a revision, e.g.
"git rev-parse --verify -q --end-of-options $rev".
* The command line completion script (in contrib/) learned to expand
commands that are alias of alias.
* "git update-ref --stdin" learns to take multiple transactions in a
single session.
* Various subcommands of "git config" that take value_regex
learned the "--literal-value" option to take the value_regex option
as a literal string.
* The transport layer was taught to optionally exchange the session
ID assigned by the trace2 subsystem during fetch/push transactions.
* "git imap-send" used to ignore configuration variables like
core.askpass; this has been corrected.
* "git $cmd $args", when $cmd is not a recognised subcommand, by
default tries to see if $cmd is a typo of an existing subcommand
and optionally executes the corrected command if there is only one
possibility, depending on the setting of help.autocorrect; the
users can now disable the whole thing, including the cycles spent
to find a likely typo, by setting the configuration variable to
'never'.
* "@" sometimes worked (e.g. "git push origin @:there") as a part of
a refspec element, but "git push origin @" did not work, which has
been corrected.
Performance, Internal Implementation, Development Support etc.
* Use "git archive" more to produce the release tarball.
* GitHub Actions automated test improvement to skip tests on a tree
identical to what has already been tested.
* Test-coverage for running commit-graph task "git maintenance" has
been extended.
* Our test scripts can be told to run only individual pieces while
skipping others with the "--run=..." option; they were taught to
take a substring of test title, in addition to numbers, to name the
test pieces to run.
* Adjust tests so that they won't scream when the default initial
branch name is different from 'master'.
* Rewriting "git bisect" in C continues.
* More preliminary tests have been added to document desired outcomes
of various "directory rename" situations.
* Micro clean-up of a couple of test scripts.
* "git diff" and other commands that share the same machinery to
compare with working tree files have been taught to take advantage
of the fsmonitor data when available.
* The code to detect premature EOF in the sideband demultiplexer has
been cleaned up.
* "git fetch --depth=<n>" over the stateless RPC / smart HTTP
transport handled EOF from the client poorly at the server end.
* A specialization of hashmap that uses a string as key has been
introduced. Hopefully it will see wider use over time.
* "git bisect start/next" in a large span of history spends a lot of
time trying to come up with exactly the half-way point; this can be
optimized by stopping when we see a commit that is close enough to
the half-way point.
* A lazily defined test prerequisite can now be defined in terms of
another lazily defined test prerequisite.
* Expectation for the original contributor after responding to a
review comment to use the explanation in a patch update has been
described.
* Multiple "credential-store" backends can race to lock the same
file, causing everybody else but one to fail---reattempt locking
with some timeout to reduce the rate of the failure.
* "git-parse-remote" shell script library outlived its usefulness.
* Like die() and error(), a call to warning() will also trigger a
trace2 event.
* Use of non-reentrant localtime() has been removed.
* Non-reentrant time-related library functions and ctime/asctime with
awkward calling interfaces are banned from the codebase.
Fixes since v2.29
-----------------
* In 2.29, "--committer-date-is-author-date" option of "rebase" and
"am" subcommands lost the e-mail address by mistake, which has been
corrected.
(merge 5f35edd9d7 jk/committer-date-is-author-date-fix later to maint).
* "git checkout -p A...B [-- <path>]" did not work, even though the
same command without "-p" correctly used the merge-base between
commits A and B.
(merge 35166b1fb5 dl/checkout-p-merge-base later to maint).
* The side-band status report can be sent at the same time as the
primary payload multiplexed, but the demultiplexer on the receiving
end incorrectly split a single status report into two, which has
been corrected.
(merge 712b0377db js/avoid-split-sideband-message later to maint).
* "git fast-import" wasted a lot of memory when many marks were in use.
(merge 3f018ec716 jk/fast-import-marks-alloc-fix later to maint).
* A test helper "test_cmp A B" was taught to diagnose missing files A
or B as a bug in test, but some tests legitimately wanted to notice
a failure to even create file B as an error, in addition to leaving
the expected result in it, and were misdiagnosed as a bug. This
has been corrected.
(merge 262d5ad5a5 es/test-cmp-typocatcher later to maint).
* When "git commit-graph" detects the same commit recorded more than
once while it is merging the layers, it used to die. The code now
ignores all but one of them and continues.
(merge 85102ac71b ds/commit-graph-merging-fix later to maint).
* The meaning of a Signed-off-by trailer can vary from project to
project; this and also what it means to this project has been
clarified in the documentation.
(merge 3abd4a67d9 bk/sob-dco later to maint).
* "git credential' didn't honor the core.askPass configuration
variable (among other things), which has been corrected.
(merge 567ad2c0f9 tk/credential-config later to maint).
* Dev support to catch a tentative definition of a variable in our C
code as an error.
(merge 5539183622 jk/no-common later to maint).
* "git rebase --rebase-merges" did not correctly pass --gpg-sign
command line option to underlying "git merge" when replaying a merge
using non-default merge strategy or when replaying an octopus merge
(because replaying a two-head merge with the default strategy was
done in a separate codepath, the problem did not trigger for most
users), which has been corrected.
(merge 43ad4f2eca sc/sequencer-gpg-octopus later to maint).
* "git apply -R" did not handle patches that touch the same path
twice correctly, which has been corrected. This is most relevant
in a patch that changes a path from a regular file to a symbolic
link (and vice versa).
(merge b0f266de11 jt/apply-reverse-twice later to maint).
* A recent oid->hash conversion missed one spot, breaking "git svn".
(merge 03bb366de4 bc/svn-hash-oid-fix later to maint).
* The documentation on the "--abbrev=<n>" option did not say the
output may be longer than "<n>" hexdigits, which has been
clarified.
(merge cda34e0d0c jc/abbrev-doc later to maint).
* "git p4" now honors init.defaultBranch configuration.
(merge 1b09d1917f js/p4-default-branch later to maint).
* Recently the format of an internal state file "rebase -i" uses has
been tightened up for consistency, which would hurt those who start
"rebase -i" with old git and then continue with new git. Loosen
the reader side a bit (which we may want to tighten again in a year
or so).
(merge c779386182 jc/sequencer-stopped-sha-simplify later to maint).
* The code to see if "git stash drop" can safely remove refs/stash
has been made more careful.
(merge 4f44c5659b rs/empty-reflog-check-fix later to maint).
* "git log -L<range>:<path>" is documented to take no pathspec, but
this was not enforced by the command line option parser, which has
been corrected.
(merge 39664cb0ac jc/line-log-takes-no-pathspec later to maint).
* "git format-patch --output=there" did not work as expected and
instead crashed. The option is now supported.
(merge dc1672dd10 jk/format-patch-output later to maint).
* Define ARM64 compiled with MSVC to be little-endian.
(merge 0c038fc65a dg/bswap-msvc later to maint).
* "git rebase -i" did not store ORIG_HEAD correctly.
(merge 8843302307 pw/rebase-i-orig-head later to maint).
* "git blame -L :funcname -- path" did not work well for a path for
which a userdiff driver is defined.
* "make DEVELOPER=1 sparse" used to run sparse and let it emit
warnings; now such warnings will cause an error.
(merge 521dc56270 jc/sparse-error-for-developer-build later to maint).
* "git blame --ignore-revs-file=<file>" learned to ignore a
non-existent object name in the input, instead of complaining.
(merge c714d05875 jc/blame-ignore-fix later to maint).
* Running "git diff" while allowing external diff in a state with
unmerged paths used to segfault, which has been corrected.
(merge d66851806f jk/diff-release-filespec-fix later to maint).
* Build configuration cleanup.
(merge b990f02fd8 ab/config-mak-uname-simplify later to maint).
* Fix regression introduced when nvimdiff support in mergetool was added.
(merge 12026f46e7 pd/mergetool-nvimdiff later to maint).
* The exchange between receive-pack and proc-receive hook did not
carefully check for errors.
* The code was not prepared to deal with pack .idx file that is
larger than 4GB.
(merge 81c4c5cf2e jk/4gb-idx later to maint).
* Since jgit does not yet work with SHA-256 repositories, mark the
tests that use it not to run unless we are testing with ShA-1
repositories.
(merge ea699b4adc sg/t5310-jgit-wants-sha1 later to maint).
* Config parser fix for "git notes".
(merge 45fef1599a na/notes-displayref-is-not-boolean later to maint).
* Move a definition of compatibility wrapper from cache.h to
git-compat-util.h
(merge a76b138daa hn/sleep-millisec-decl later to maint).
* Error message fix.
(merge eaf5341538 km/stash-error-message-fix later to maint).
* "git pull --rebase --recurse-submodules" checked for local changes
in a wrong range and failed to run correctly when it should.
(merge 5176f20ffe pb/pull-rebase-recurse-submodules later to maint).
* "git push" that is killed may leave a pack-objects process behind,
still computing to find a good compression, wasting cycles. This
has been corrected.
(merge 8b59935114 jk/stop-pack-objects-when-push-is-killed later to maint).
* "git fetch" that is killed may leave a pack-objects process behind,
still computing to find a good compression, wasting cycles. This
has been corrected.
(merge 309a4028e7 jk/stop-pack-objects-when-fetch-is-killed later to maint).
* "git add -i" failed to honor custom colors configured to show
patches, which has been corrected.
(merge 96386faa03 js/add-i-color-fix later to maint).
* Processes that access packdata while the .idx file gets removed
(e.g. while repacking) did not fail or fall back gracefully as they
could.
(merge 506ec2fbda tb/idx-midx-race-fix later to maint).
* "git apply" adjusted the permission bits of working-tree files and
directories according to core.sharedRepository setting by mistake and
for a long time, which has been corrected.
(merge eb3c027e17 mt/do-not-use-scld-in-working-tree later to maint).
* "fetch-pack" could pass NULL pointer to unlink(2) when it sees an
invalid filename; the error checking has been tightened to make
this impossible.
(merge 6031af387e rs/fetch-pack-invalid-lockfile later to maint).
* "git maintenance run/start/stop" needed to be run in a repository
to hold the lockfile they use, but didn't make sure they are
actually in a repository, which has been corrected.
* The glossary described a branch as an "active" line of development,
which is misleading---a stale and non-moving branch is still a
branch.
(merge eef1ceabd8 so/glossary-branch-is-not-necessarily-active later to maint).
* Newer versions of xsltproc can assign IDs in HTML documents it
generates in a consistent manner. Use the feature to help format
HTML version of the user manual reproducibly.
(merge 3569e11d69 ae/doc-reproducible-html later to maint).
* Tighten error checking in the codepath that responds to "git fetch".
(merge d43a21bdbb jk/check-config-parsing-error-in-upload-pack later to maint).
* "git pack-redundant" when there is only one packfile used to crash,
which has been corrected.
(merge 0696232390 jx/pack-redundant-on-single-pack later to maint).
* Other code cleanup, docfix, build fix, etc.
(merge 3e0a5dc9af cc/doc-filter-branch-typofix later to maint).
(merge 32c83afc2c cw/ci-ghwf-check-ws-errors later to maint).
(merge 5eb2ed691b rs/tighten-callers-of-deref-tag later to maint).
(merge 6db29ab213 jk/fast-import-marks-cleanup later to maint).
(merge e5cf6d3df4 nk/dir-c-comment-update later to maint).
(merge 5710dcce74 jk/report-fn-typedef later to maint).
(merge 9a82db1056 en/sequencer-rollback-lock-cleanup later to maint).
(merge 4e1bee9a99 js/t7006-cleanup later to maint).
(merge f5bcde6c58 es/tutorial-mention-asciidoc-early later to maint).
(merge 714d491af0 so/format-patch-doc-on-default-diff-format later to maint).
(merge 0795df4b9b rs/clear-commit-marks-in-repo later to maint).
(merge 9542d56379 sd/prompt-local-variable later to maint).
(merge 06d43fad18 rs/pack-write-hashwrite-simplify later to maint).
(merge b7e20b4373 mc/typofix later to maint).
(merge f6bcd9a8a4 js/test-whitespace-fixes later to maint).
(merge 53b67a801b js/test-file-size later to maint).
(merge 970909c2a7 rs/hashwrite-be64 later to maint).
(merge 5a923bb1f0 ma/list-object-filter-opt-msgfix later to maint).
(merge 1c3e412916 rs/archive-plug-leak-refname later to maint).
(merge d44e5267ea rs/plug-diff-cache-leak later to maint).
(merge 793c1464d3 ab/gc-keep-base-option later to maint).
(merge b86339b12b mt/worktree-error-message-fix later to maint).
(merge e01ae2a4a7 js/pull-rebase-use-advise later to maint).
(merge e63d774242 sn/config-doc-typofix later to maint).
(merge 08e9df2395 jk/multi-line-indent-style-fix later to maint).
(merge e66590348a da/vs-build-iconv-fix later to maint).
(merge 7fe07275be js/cmake-extra-built-ins-fix later to maint).
(merge 633eebe142 jb/midx-doc-update later to maint).
(merge 5885367e8f jh/index-v2-doc-on-fsmn later to maint).
(merge 14639a4779 jc/compat-util-setitimer-fix later to maint).
(merge 56f56ac50b ab/unreachable-break later to maint).
(merge 731d578b4f rb/nonstop-config-mak-uname-update later to maint).
(merge f4698738f9 es/perf-export-fix later to maint).
(merge 773c694142 nk/refspecs-negative-fix later to maint).

View File

@ -1,55 +0,0 @@
Git v2.30.1 Release Notes
=========================
This release is primarily to merge fixes accumulated on the 'master'
front to prepare for 2.31 release that are still relevant to 2.30.x
maintenance track.
Fixes since v2.30
-----------------
* "git fetch --recurse-submodules" failed to update a submodule
when it has an uninitialized (hence of no interest to the user)
sub-submodule, which has been corrected.
* Command line error of "git rebase" are diagnosed earlier.
* "git stash" did not work well in a sparsely checked out working
tree.
* Some tests expect that "ls -l" output has either '-' or 'x' for
group executable bit, but setgid bit can be inherited from parent
directory and make these fields 'S' or 's' instead, causing test
failures.
* "git for-each-repo --config=<var> <cmd>" should not run <cmd> for
any repository when the configuration variable <var> is not defined
even once.
* "git mergetool --tool-help" was broken in 2.29 and failed to list
all the available tools.
* Fix for procedure to building CI test environment for mac.
* Newline characters in the host and path part of git:// URL are
now forbidden.
* When more than one commit with the same patch ID appears on one
side, "git log --cherry-pick A...B" did not exclude them all when a
commit with the same patch ID appears on the other side. Now it
does.
* Documentation for "git fsck" lost stale bits that has become
incorrect.
* Doc for packfile URI feature has been clarified.
* The implementation of "git branch --sort" wrt the detached HEAD
display has always been hacky, which has been cleaned up.
* Our setting of GitHub CI test jobs were a bit too eager to give up
once there is even one failure found. Tweak the knob to allow
other jobs keep running even when we see a failure, so that we can
find more failures in a single run.
Also contains minor documentation updates and code clean-ups.

View File

@ -1,358 +0,0 @@
Git 2.31 Release Notes
======================
Updates since v2.30
-------------------
Backward incompatible and other important changes
* The "pack-redundant" command, which has been left stale with almost
unusable performance issues, now warns loudly when it gets used, as
we no longer want to recommend its use (instead just "repack -d"
instead).
* The development community has adopted Contributor Covenant v2.0 to
update from v1.4 that we have been using.
* The support for deprecated PCRE1 library has been dropped.
UI, Workflows & Features
* The "--format=%(trailers)" mechanism gets enhanced to make it
easier to design output for machine consumption.
* When a user does not tell "git pull" to use rebase or merge, the
command gives a loud message telling a user to choose between
rebase or merge but creates a merge anyway, forcing users who would
want to rebase to redo the operation. Fix an early part of this
problem by tightening the condition to give the message---there is
no reason to stop or force the user to choose between rebase or
merge if the history fast-forwards.
* The configuration variable 'core.abbrev' can be set to 'no' to
force no abbreviation regardless of the hash algorithm.
* "git rev-parse" can be explicitly told to give output as absolute
or relative path with the `--path-format=(absolute|relative)` option.
* Bash completion (in contrib/) update to make it easier for
end-users to add completion for their custom "git" subcommands.
* "git maintenance" learned to drive scheduled maintenance on
platforms whose native scheduling methods are not 'cron'.
* After expiring a reflog and making a single commit, the reflog for
the branch would record a single entry that knows both @{0} and
@{1}, but we failed to answer "what commit were we on?", i.e. @{1}
* "git bundle" learns "--stdin" option to read its refs from the
standard input. Also, it now does not lose refs whey they point
at the same object.
* "git log" learned a new "--diff-merges=<how>" option.
* "git ls-files" can and does show multiple entries when the index is
unmerged, which is a source for confusion unless -s/-u option is in
use. A new option --deduplicate has been introduced.
* `git worktree list` now annotates worktrees as prunable, shows
locked and prunable attributes in --porcelain mode, and gained
a --verbose option.
* "git clone" tries to locally check out the branch pointed at by
HEAD of the remote repository after it is done, but the protocol
did not convey the information necessary to do so when copying an
empty repository. The protocol v2 learned how to do so.
* There are other ways than ".." for a single token to denote a
"commit range", namely "<rev>^!" and "<rev>^-<n>", but "git
range-diff" did not understand them.
* The "git range-diff" command learned "--(left|right)-only" option
to show only one side of the compared range.
* "git mergetool" feeds three versions (base, local and remote) of
a conflicted path unmodified. The command learned to optionally
prepare these files with unconflicted parts already resolved.
* The .mailmap is documented to be read only from the root level of a
working tree, but a stray file in a bare repository also was read
by accident, which has been corrected.
* "git maintenance" tool learned a new "pack-refs" maintenance task.
* The error message given when a configuration variable that is
expected to have a boolean value has been improved.
* Signed commits and tags now allow verification of objects, whose
two object names (one in SHA-1, the other in SHA-256) are both
signed.
* "git rev-list" command learned "--disk-usage" option.
* "git {diff,log} --{skip,rotate}-to=<path>" allows the user to
discard diff output for early paths or move them to the end of the
output.
* "git difftool" learned "--skip-to=<path>" option to restart an
interrupted session from an arbitrary path.
* "git grep" has been tweaked to be limited to the sparse checkout
paths.
* "git rebase --[no-]fork-point" gained a configuration variable
rebase.forkPoint so that users do not have to keep specifying a
non-default setting.
Performance, Internal Implementation, Development Support etc.
* A 3-year old test that was not testing anything useful has been
corrected.
* Retire more names with "sha1" in it.
* The topological walk codepath is covered by new trace2 stats.
* Update the Code-of-conduct to version 2.0 from the upstream (we've
been using version 1.4).
* "git mktag" validates its input using its own rules before writing
a tag object---it has been updated to share the logic with "git
fsck".
* Two new ways to feed configuration variable-value pairs via
environment variables have been introduced, and the way
GIT_CONFIG_PARAMETERS encodes variable/value pairs has been tweaked
to make it more robust.
* Tests have been updated so that they do not to get affected by the
name of the default branch "git init" creates.
* "git fetch" learns to treat ref updates atomically in all-or-none
fashion, just like "git push" does, with the new "--atomic" option.
* The peel_ref() API has been replaced with peel_iterated_oid().
* The .use_shell flag in struct child_process that is passed to
run_command() API has been clarified with a bit more documentation.
* Document, clean-up and optimize the code around the cache-tree
extension in the index.
* The ls-refs protocol operation has been optimized to narrow the
sub-hierarchy of refs/ it walks to produce response.
* When removing many branches and tags, the code used to do so one
ref at a time. There is another API it can use to delete multiple
refs, and it makes quite a lot of performance difference when the
refs are packed.
* The "pack-objects" command needs to iterate over all the tags when
automatic tag following is enabled, but it actually iterated over
all refs and then discarded everything outside "refs/tags/"
hierarchy, which was quite wasteful.
* A perf script was made more portable.
* Our setting of GitHub CI test jobs were a bit too eager to give up
once there is even one failure found. Tweak the knob to allow
other jobs keep running even when we see a failure, so that we can
find more failures in a single run.
* We've carried compatibility codepaths for compilers without
variadic macros for quite some time, but the world may be ready for
them to be removed. Force compilation failure on exotic platforms
where variadic macros are not available to find out who screams in
such a way that we can easily revert if it turns out that the world
is not yet ready.
* Code clean-up to ensure our use of hashtables using object names as
keys use the "struct object_id" objects, not the raw hash values.
* Lose the debugging aid that may have been useful in the past, but
no longer is, in the "grep" codepaths.
* Some pretty-format specifiers do not need the data in commit object
(e.g. "%H"), but we were over-eager to load and parse it, which has
been made even lazier.
* Get rid of "GETTEXT_POISON" support altogether, which may or may
not be controversial.
* Introduce an on-disk file to record revindex for packdata, which
traditionally was always created on the fly and only in-core.
* The commit-graph learned to use corrected commit dates instead of
the generation number to help topological revision traversal.
* Piecemeal of rewrite of "git bisect" in C continues.
* When a pager spawned by us exited, the trace log did not record its
exit status correctly, which has been corrected.
* Removal of GIT_TEST_GETTEXT_POISON continues.
* The code to implement "git merge-base --independent" was poorly
done and was kept from the very beginning of the feature.
* Preliminary changes to fsmonitor integration.
* Performance optimization work on the rename detection continues.
* The common code to deal with "chunked file format" that is shared
by the multi-pack-index and commit-graph files have been factored
out, to help codepaths for both filetypes to become more robust.
* The approach to "fsck" the incoming objects in "index-pack" is
attractive for performance reasons (we have them already in core,
inflated and ready to be inspected), but fundamentally cannot be
applied fully when we receive more than one pack stream, as a tree
object in one pack may refer to a blob object in another pack as
".gitmodules", when we want to inspect blobs that are used as
".gitmodules" file, for example. Teach "index-pack" to emit
objects that must be inspected later and check them in the calling
"fetch-pack" process.
* The logic to handle "trailer" related placeholders in the
"--format=" mechanisms in the "log" family and "for-each-ref"
family is getting unified.
* Raise the buffer size used when writing the index file out from
(obviously too small) 8kB to (clearly sufficiently large) 128kB.
Fixes since v2.30
-----------------
* Diagnose command line error of "git rebase" early.
* Clean up option descriptions in "git cmd --help".
* "git stash" did not work well in a sparsely checked out working
tree.
* Some tests expect that "ls -l" output has either '-' or 'x' for
group executable bit, but setgid bit can be inherited from parent
directory and make these fields 'S' or 's' instead, causing test
failures.
* "git for-each-repo --config=<var> <cmd>" should not run <cmd> for
any repository when the configuration variable <var> is not defined
even once.
* Fix 2.29 regression where "git mergetool --tool-help" fails to list
all the available tools.
* Fix for procedure to building CI test environment for mac.
* The implementation of "git branch --sort" wrt the detached HEAD
display has always been hacky, which has been cleaned up.
* Newline characters in the host and path part of git:// URL are
now forbidden.
* "git diff" showed a submodule working tree with untracked cruft as
"Submodule commit <objectname>-dirty", but a natural expectation is
that the "-dirty" indicator would align with "git describe --dirty",
which does not consider having untracked files in the working tree
as source of dirtiness. The inconsistency has been fixed.
* When more than one commit with the same patch ID appears on one
side, "git log --cherry-pick A...B" did not exclude them all when a
commit with the same patch ID appears on the other side. Now it
does.
* Documentation for "git fsck" lost stale bits that has become
incorrect.
* Doc fix for packfile URI feature.
* When "git rebase -i" processes "fixup" insn, there is no reason to
clean up the commit log message, but we did the usual stripspace
processing. This has been corrected.
(merge f7d42ceec5 js/rebase-i-commit-cleanup-fix later to maint).
* Fix in passing custom args from "git clone" to "upload-pack" on the
other side.
(merge ad6b5fefbd jv/upload-pack-filter-spec-quotefix later to maint).
* The command line completion (in contrib/) completed "git branch -d"
with branch names, but "git branch -D" offered tagnames in addition,
which has been corrected. "git branch -M" had the same problem.
(merge 27dc071b9a jk/complete-branch-force-delete later to maint).
* When commands are started from a subdirectory, they may have to
compare the path to the subdirectory (called prefix and found out
from $(pwd)) with the tracked paths. On macOS, $(pwd) and
readdir() yield decomposed path, while the tracked paths are
usually normalized to the precomposed form, causing mismatch. This
has been fixed by taking the same approach used to normalize the
command line arguments.
(merge 5c327502db tb/precompose-prefix-too later to maint).
* Even though invocations of "die()" were logged to the trace2
system, "BUG()"s were not, which has been corrected.
(merge 0a9dde4a04 jt/trace2-BUG later to maint).
* "git grep --untracked" is meant to be "let's ALSO find in these
files on the filesystem" when looking for matches in the working
tree files, and does not make any sense if the primary search is
done against the index, or the tree objects. The "--cached" and
"--untracked" options have been marked as mutually incompatible.
(merge 0c5d83b248 mt/grep-cached-untracked later to maint).
* Fix "git fsck --name-objects" which apparently has not been used by
anybody who is motivated enough to report breakage.
(merge e89f89361c js/fsck-name-objects-fix later to maint).
* Avoid individual tests in t5411 from getting affected by each other
by forcing them to use separate output files during the test.
(merge 822ee894f6 jx/t5411-unique-filenames later to maint).
* Test to make sure "git rev-parse one-thing one-thing" gives
the same thing twice (when one-thing is --since=X).
(merge a5cdca4520 ew/rev-parse-since-test later to maint).
* When certain features (e.g. grafts) used in the repository are
incompatible with the use of the commit-graph, we used to silently
turned commit-graph off; we now tell the user what we are doing.
(merge c85eec7fc3 js/commit-graph-warning later to maint).
* Objects that lost references can be pruned away, even when they
have notes attached to it (and these notes will become dangling,
which in turn can be pruned with "git notes prune"). This has been
clarified in the documentation.
(merge fa9ab027ba mz/doc-notes-are-not-anchors later to maint).
* The error codepath around the "--temp/--prefix" feature of "git
checkout-index" has been improved.
(merge 3f7ba60350 mt/checkout-index-corner-cases later to maint).
* The "git maintenance register" command had trouble registering bare
repositories, which had been corrected.
* A handful of multi-word configuration variable names in
documentation that are spelled in all lowercase have been corrected
to use the more canonical camelCase.
(merge 7dd0eaa39c dl/doc-config-camelcase later to maint).
* "git push $there --delete ''" should have been diagnosed as an
error, but instead turned into a matching push, which has been
corrected.
(merge 20e416409f jc/push-delete-nothing later to maint).
* Test script modernization.
(merge 488acf15df sv/t7001-modernize later to maint).
* An under-allocation for the untracked cache data has been corrected.
(merge 6347d649bc jh/untracked-cache-fix later to maint).
* Other code cleanup, docfix, build fix, etc.
(merge e3f5da7e60 sg/t7800-difftool-robustify later to maint).
(merge 9d336655ba js/doc-proto-v2-response-end later to maint).
(merge 1b5b8cf072 jc/maint-column-doc-typofix later to maint).
(merge 3a837b58e3 cw/pack-config-doc later to maint).
(merge 01168a9d89 ug/doc-commit-approxidate later to maint).
(merge b865734760 js/params-vs-args later to maint).

View File

@ -209,7 +209,7 @@ send them as replies to either an additional "cover letter" message
(see below), the first patch, or the respective preceding patch. (see below), the first patch, or the respective preceding patch.
If your log message (including your name on the If your log message (including your name on the
`Signed-off-by` trailer) is not writable in ASCII, make sure that Signed-off-by line) is not writable in ASCII, make sure that
you send off a message in the correct encoding. you send off a message in the correct encoding.
WARNING: Be wary of your MUAs word-wrap WARNING: Be wary of your MUAs word-wrap
@ -229,7 +229,7 @@ previously sent.
The `git format-patch` command follows the best current practice to The `git format-patch` command follows the best current practice to
format the body of an e-mail message. At the beginning of the format the body of an e-mail message. At the beginning of the
patch should come your commit message, ending with the patch should come your commit message, ending with the
`Signed-off-by` trailers, and a line that consists of three dashes, Signed-off-by: lines, and a line that consists of three dashes,
followed by the diffstat information and the patch itself. If followed by the diffstat information and the patch itself. If
you are forwarding a patch from somebody else, optionally, at you are forwarding a patch from somebody else, optionally, at
the beginning of the e-mail message just before the commit the beginning of the e-mail message just before the commit
@ -290,24 +290,25 @@ identify them), to solicit comments and reviews.
:git-ml: footnote:[The mailing list: git@vger.kernel.org] :git-ml: footnote:[The mailing list: git@vger.kernel.org]
After the list reached a consensus that it is a good idea to apply the After the list reached a consensus that it is a good idea to apply the
patch, re-send it with "To:" set to the maintainer{current-maintainer} patch, re-send it with "To:" set to the maintainer{current-maintainer} and "cc:" the
and "cc:" the list{git-ml} for inclusion. This is especially relevant list{git-ml} for inclusion.
when the maintainer did not heavily participate in the discussion and
instead left the review to trusted others.
Do not forget to add trailers such as `Acked-by:`, `Reviewed-by:` and Do not forget to add trailers such as `Acked-by:`, `Reviewed-by:` and
`Tested-by:` lines as necessary to credit people who helped your `Tested-by:` lines as necessary to credit people who helped your
patch, and "cc:" them when sending such a final version for inclusion. patch.
[[sign-off]] [[sign-off]]
=== Certify your work by adding your `Signed-off-by` trailer === Certify your work by adding your "Signed-off-by: " line
To improve tracking of who did what, we ask you to certify that you To improve tracking of who did what, we've borrowed the
wrote the patch or have the right to pass it on under the same license "sign-off" procedure from the Linux kernel project on patches
as ours, by "signing off" your patch. Without sign-off, we cannot that are being emailed around. Although core Git is a lot
accept your patches. smaller project it is a good discipline to follow it.
If (and only if) you certify the below D-C-O: The sign-off is a simple line at the end of the explanation for
the patch, which certifies that you wrote it or otherwise have
the right to pass it on as an open-source patch. The rules are
pretty simple: if you can certify the below D-C-O:
[[dco]] [[dco]]
.Developer's Certificate of Origin 1.1 .Developer's Certificate of Origin 1.1
@ -337,29 +338,23 @@ d. I understand and agree that this project and the contribution
this project or the open source license(s) involved. this project or the open source license(s) involved.
____ ____
you add a "Signed-off-by" trailer to your commit, that looks like then you just add a line saying
this:
.... ....
Signed-off-by: Random J Developer <random@developer.example.org> Signed-off-by: Random J Developer <random@developer.example.org>
.... ....
This line can be added by Git if you run the git-commit command with This line can be automatically added by Git if you run the git-commit
the -s option. command with the -s option.
Notice that you can place your own `Signed-off-by` trailer when Notice that you can place your own Signed-off-by: line when
forwarding somebody else's patch with the above rules for forwarding somebody else's patch with the above rules for
D-C-O. Indeed you are encouraged to do so. Do not forget to D-C-O. Indeed you are encouraged to do so. Do not forget to
place an in-body "From: " line at the beginning to properly attribute place an in-body "From: " line at the beginning to properly attribute
the change to its true author (see (2) above). the change to its true author (see (2) above).
This procedure originally came from the Linux kernel project, so our
rule is quite similar to theirs, but what exactly it means to sign-off
your patch differs from project to project, so it may be different
from that of the project you are accustomed to.
[[real-name]] [[real-name]]
Also notice that a real name is used in the `Signed-off-by` trailer. Please Also notice that a real name is used in the Signed-off-by: line. Please
don't hide your real name. don't hide your real name.
[[commit-trailers]] [[commit-trailers]]

View File

@ -1,6 +1,6 @@
-b:: -b::
Show blank SHA-1 for boundary commits. This can also Show blank SHA-1 for boundary commits. This can also
be controlled via the `blame.blankBoundary` config option. be controlled via the `blame.blankboundary` config option.
--root:: --root::
Do not treat root commits as boundaries. This can also be Do not treat root commits as boundaries. This can also be
@ -11,12 +11,11 @@
-L <start>,<end>:: -L <start>,<end>::
-L :<funcname>:: -L :<funcname>::
Annotate only the line range given by '<start>,<end>', Annotate only the given line range. May be specified multiple times.
or by the function name regex '<funcname>'. Overlapping ranges are allowed.
May be specified multiple times. Overlapping ranges are allowed.
+ +
'<start>' and '<end>' are optional. `-L <start>` or `-L <start>,` spans from <start> and <end> are optional. ``-L <start>'' or ``-L <start>,'' spans from
'<start>' to end of file. `-L ,<end>` spans from start of file to '<end>'. <start> to end of file. ``-L ,<end>'' spans from start of file to <end>.
+ +
include::line-range-format.txt[] include::line-range-format.txt[]
@ -37,12 +36,6 @@ include::line-range-format.txt[]
START. `git blame --reverse START` is taken as `git blame START. `git blame --reverse START` is taken as `git blame
--reverse START..HEAD` for convenience. --reverse START..HEAD` for convenience.
--first-parent::
Follow only the first parent commit upon seeing a merge
commit. This option can be used to determine when a line
was introduced to a particular integration branch, rather
than when it was introduced to the history overall.
-p:: -p::
--porcelain:: --porcelain::
Show in a format designed for machine consumption. Show in a format designed for machine consumption.

View File

@ -6,14 +6,9 @@ sub format_one {
my ($out, $nameattr) = @_; my ($out, $nameattr) = @_;
my ($name, $attr) = @$nameattr; my ($name, $attr) = @$nameattr;
my ($state, $description); my ($state, $description);
my $mansection;
$state = 0; $state = 0;
open I, '<', "$name.txt" or die "No such file $name.txt"; open I, '<', "$name.txt" or die "No such file $name.txt";
while (<I>) { while (<I>) {
if (/^git[a-z0-9-]*\(([0-9])\)$/) {
$mansection = $1;
next;
}
if (/^NAME$/) { if (/^NAME$/) {
$state = 1; $state = 1;
next; next;
@ -32,7 +27,7 @@ sub format_one {
die "No description found in $name.txt"; die "No description found in $name.txt";
} }
if (my ($verify_name, $text) = ($description =~ /^($name) - (.*)/)) { if (my ($verify_name, $text) = ($description =~ /^($name) - (.*)/)) {
print $out "linkgit:$name\[$mansection\]::\n\t"; print $out "linkgit:$name\[1\]::\n\t";
if ($attr =~ / deprecated /) { if ($attr =~ / deprecated /) {
print $out "(deprecated) "; print $out "(deprecated) ";
} }
@ -43,15 +38,12 @@ sub format_one {
} }
} }
my ($input, @categories) = @ARGV; while (<>) {
open IN, "<$input";
while (<IN>) {
last if /^### command list/; last if /^### command list/;
} }
my %cmds = (); my %cmds = ();
for (sort <IN>) { for (sort <>) {
next if /^#/; next if /^#/;
chomp; chomp;
@ -59,10 +51,17 @@ for (sort <IN>) {
$attr = '' unless defined $attr; $attr = '' unless defined $attr;
push @{$cmds{$cat}}, [$name, " $attr "]; push @{$cmds{$cat}}, [$name, " $attr "];
} }
close IN;
for my $out (@categories) { for my $cat (qw(ancillaryinterrogators
my ($cat) = $out =~ /^cmds-(.*)\.txt$/; ancillarymanipulators
mainporcelain
plumbinginterrogators
plumbingmanipulators
synchingrepositories
foreignscminterface
purehelpers
synchelpers)) {
my $out = "cmds-$cat.txt";
open O, '>', "$out+" or die "Cannot open output file $out+"; open O, '>', "$out+" or die "Cannot open output file $out+";
for (@{$cmds{$cat}}) { for (@{$cmds{$cat}}) {
format_one(\*O, $_); format_one(\*O, $_);

View File

@ -64,7 +64,7 @@ The variable names are case-insensitive, allow only alphanumeric characters
and `-`, and must start with an alphabetic character. and `-`, and must start with an alphabetic character.
A line that defines a value can be continued to the next line by A line that defines a value can be continued to the next line by
ending it with a `\`; the backslash and the end-of-line are ending it with a `\`; the backquote and the end-of-line are
stripped. Leading whitespaces after 'name =', the remainder of the stripped. Leading whitespaces after 'name =', the remainder of the
line after the first comment character '#' or ';', and trailing line after the first comment character '#' or ';', and trailing
whitespaces of the line are discarded unless they are enclosed in whitespaces of the line are discarded unless they are enclosed in
@ -265,7 +265,7 @@ color::
The basic colors accepted are `normal`, `black`, `red`, `green`, `yellow`, The basic colors accepted are `normal`, `black`, `red`, `green`, `yellow`,
`blue`, `magenta`, `cyan` and `white`. The first color given is the `blue`, `magenta`, `cyan` and `white`. The first color given is the
foreground; the second is the background. All the basic colors except foreground; the second is the background. All the basic colors except
`normal` have a bright variant that can be specified by prefixing the `normal` have a bright variant that can be speficied by prefixing the
color with `bright`, like `brightred`. color with `bright`, like `brightred`.
+ +
Colors may also be given as numbers between 0 and 255; these use ANSI Colors may also be given as numbers between 0 and 255; these use ANSI
@ -334,16 +334,12 @@ include::config/checkout.txt[]
include::config/clean.txt[] include::config/clean.txt[]
include::config/clone.txt[]
include::config/color.txt[] include::config/color.txt[]
include::config/column.txt[] include::config/column.txt[]
include::config/commit.txt[] include::config/commit.txt[]
include::config/commitgraph.txt[]
include::config/credential.txt[] include::config/credential.txt[]
include::config/completion.txt[] include::config/completion.txt[]
@ -352,8 +348,6 @@ include::config/diff.txt[]
include::config/difftool.txt[] include::config/difftool.txt[]
include::config/extensions.txt[]
include::config/fastimport.txt[] include::config/fastimport.txt[]
include::config/feature.txt[] include::config/feature.txt[]
@ -398,14 +392,10 @@ include::config/interactive.txt[]
include::config/log.txt[] include::config/log.txt[]
include::config/lsrefs.txt[]
include::config/mailinfo.txt[] include::config/mailinfo.txt[]
include::config/mailmap.txt[] include::config/mailmap.txt[]
include::config/maintenance.txt[]
include::config/man.txt[] include::config/man.txt[]
include::config/merge.txt[] include::config/merge.txt[]

View File

@ -10,8 +10,9 @@ advice.*::
that the check is disabled. that the check is disabled.
pushUpdateRejected:: pushUpdateRejected::
Set this variable to 'false' if you want to disable Set this variable to 'false' if you want to disable
'pushNonFFCurrent', 'pushNonFFMatching', 'pushAlreadyExists', 'pushNonFFCurrent',
'pushFetchFirst', 'pushNeedsForce', and 'pushRefNeedsUpdate' 'pushNonFFMatching', 'pushAlreadyExists',
'pushFetchFirst', and 'pushNeedsForce'
simultaneously. simultaneously.
pushNonFFCurrent:: pushNonFFCurrent::
Advice shown when linkgit:git-push[1] fails due to a Advice shown when linkgit:git-push[1] fails due to a
@ -40,10 +41,6 @@ advice.*::
we can still suggest that the user push to either we can still suggest that the user push to either
refs/heads/* or refs/tags/* based on the type of the refs/heads/* or refs/tags/* based on the type of the
source object. source object.
pushRefNeedsUpdate::
Shown when linkgit:git-push[1] rejects a forced update of
a branch when its remote-tracking ref has updates that we
do not have locally.
statusAheadBehind:: statusAheadBehind::
Shown when linkgit:git-status[1] computes the ahead/behind Shown when linkgit:git-status[1] computes the ahead/behind
counts for a local ref compared to its remote tracking ref, counts for a local ref compared to its remote tracking ref,

View File

@ -1,23 +1,18 @@
checkout.defaultRemote:: checkout.defaultRemote::
When you run `git checkout <something>` When you run 'git checkout <something>'
or `git switch <something>` and only have one or 'git switch <something>' and only have one
remote, it may implicitly fall back on checking out and remote, it may implicitly fall back on checking out and
tracking e.g. `origin/<something>`. This stops working as soon tracking e.g. 'origin/<something>'. This stops working as soon
as you have more than one remote with a `<something>` as you have more than one remote with a '<something>'
reference. This setting allows for setting the name of a reference. This setting allows for setting the name of a
preferred remote that should always win when it comes to preferred remote that should always win when it comes to
disambiguation. The typical use-case is to set this to disambiguation. The typical use-case is to set this to
`origin`. `origin`.
+ +
Currently this is used by linkgit:git-switch[1] and Currently this is used by linkgit:git-switch[1] and
linkgit:git-checkout[1] when `git checkout <something>` linkgit:git-checkout[1] when 'git checkout <something>'
or `git switch <something>` or 'git switch <something>'
will checkout the `<something>` branch on another remote, will checkout the '<something>' branch on another remote,
and by linkgit:git-worktree[1] when `git worktree add` refers to a and by linkgit:git-worktree[1] when 'git worktree add' refers to a
remote branch. This setting might be used for other checkout-like remote branch. This setting might be used for other checkout-like
commands or functionality in the future. commands or functionality in the future.
checkout.guess::
Provides the default value for the `--guess` or `--no-guess`
option in `git checkout` and `git switch`. See
linkgit:git-switch[1] and linkgit:git-checkout[1].

View File

@ -1,4 +0,0 @@
clone.defaultRemoteName::
The name of the remote to create when cloning a repository. Defaults to
`origin`, and can be overridden by passing the `--origin` command-line
option to linkgit:git-clone[1].

View File

@ -1,8 +0,0 @@
commitGraph.maxNewFilters::
Specifies the default value for the `--max-new-filters` option of `git
commit-graph write` (c.f., linkgit:git-commit-graph[1]).
commitGraph.readChangedPaths::
If true, then git will use the changed-path Bloom filters in the
commit-graph file (if it exists, and they are present). Defaults to
true. See linkgit:git-commit-graph[1] for more information.

View File

@ -399,7 +399,7 @@ the largest projects. You probably do not need to adjust this value.
Common unit suffixes of 'k', 'm', or 'g' are supported. Common unit suffixes of 'k', 'm', or 'g' are supported.
core.deltaBaseCacheLimit:: core.deltaBaseCacheLimit::
Maximum number of bytes per thread to reserve for caching base objects Maximum number of bytes to reserve for caching base objects
that may be referenced by multiple deltified objects. By storing the that may be referenced by multiple deltified objects. By storing the
entire decompressed base objects in a cache Git is able entire decompressed base objects in a cache Git is able
to avoid unpacking and decompressing frequently used base to avoid unpacking and decompressing frequently used base
@ -606,8 +606,8 @@ core.useReplaceRefs::
core.multiPackIndex:: core.multiPackIndex::
Use the multi-pack-index file to track multiple packfiles using a Use the multi-pack-index file to track multiple packfiles using a
single index. See linkgit:git-multi-pack-index[1] for more single index. See link:technical/multi-pack-index.html[the
information. Defaults to true. multi-pack-index design document].
core.sparseCheckout:: core.sparseCheckout::
Enable "sparse checkout" feature. See linkgit:git-sparse-checkout[1] Enable "sparse checkout" feature. See linkgit:git-sparse-checkout[1]
@ -625,6 +625,4 @@ core.abbrev::
computed based on the approximate number of packed objects computed based on the approximate number of packed objects
in your repository, which hopefully is enough for in your repository, which hopefully is enough for
abbreviated object names to stay unique for some time. abbreviated object names to stay unique for some time.
If set to "no", no abbreviation is made and the object names
are shown in their full length.
The minimum length is 4. The minimum length is 4.

View File

@ -28,9 +28,3 @@ credential.<url>.*::
credentialCache.ignoreSIGHUP:: credentialCache.ignoreSIGHUP::
Tell git-credential-cache--daemon to ignore SIGHUP, instead of quitting. Tell git-credential-cache--daemon to ignore SIGHUP, instead of quitting.
credentialStore.lockTimeoutMS::
The length of time, in milliseconds, for git-credential-store to retry
when trying to lock the credentials file. Value 0 means not to retry at
all; -1 means to try indefinitely. Default is 1000 (i.e., retry for
1s).

View File

@ -85,8 +85,6 @@ diff.ignoreSubmodules::
and 'git status' when `status.submoduleSummary` is set unless it is and 'git status' when `status.submoduleSummary` is set unless it is
overridden by using the --ignore-submodules command-line option. overridden by using the --ignore-submodules command-line option.
The 'git submodule' commands are not affected by this setting. The 'git submodule' commands are not affected by this setting.
By default this is set to untracked so that any untracked
submodules are ignored.
diff.mnemonicPrefix:: diff.mnemonicPrefix::
If set, 'git diff' uses a prefix pair that is different from the If set, 'git diff' uses a prefix pair that is different from the

View File

@ -1,8 +0,0 @@
extensions.objectFormat::
Specify the hash algorithm to use. The acceptable values are `sha1` and
`sha256`. If not specified, `sha1` is assumed. It is an error to specify
this key unless `core.repositoryFormatVersion` is 1.
+
Note that this setting should only be set by linkgit:git-init[1] or
linkgit:git-clone[1]. Trying to change it after initialization will not
work and will produce hard-to-diagnose issues.

View File

@ -14,6 +14,10 @@ feature.experimental::
+ +
* `fetch.negotiationAlgorithm=skipping` may improve fetch negotiation times by * `fetch.negotiationAlgorithm=skipping` may improve fetch negotiation times by
skipping more commits at a time, reducing the number of round trips. skipping more commits at a time, reducing the number of round trips.
+
* `protocol.version=2` speeds up fetches from repositories with many refs by
allowing the client to specify which refs to list before the server lists
them.
feature.manyFiles:: feature.manyFiles::
Enable config options that optimize for repos with many files in the Enable config options that optimize for repos with many files in the

View File

@ -60,10 +60,7 @@ fetch.negotiationAlgorithm::
sent when negotiating the contents of the packfile to be sent by the sent when negotiating the contents of the packfile to be sent by the
server. Set to "skipping" to use an algorithm that skips commits in an server. Set to "skipping" to use an algorithm that skips commits in an
effort to converge faster, but may result in a larger-than-necessary effort to converge faster, but may result in a larger-than-necessary
packfile; or set to "noop" to not send any information at all, which packfile; The default is "default" which instructs Git to use the default algorithm
will almost certainly result in a larger-than-necessary packfile, but
will skip the negotiation step.
The default is "default" which instructs Git to use the default algorithm
that never skips commits (unless the server has acknowledged it or one that never skips commits (unless the server has acknowledged it or one
of its descendants). If `feature.experimental` is enabled, then this of its descendants). If `feature.experimental` is enabled, then this
setting defaults to "skipping". setting defaults to "skipping".

View File

@ -8,15 +8,3 @@ merge.log::
most the specified number of one-line descriptions from the most the specified number of one-line descriptions from the
actual commits that are being merged. Defaults to false, and actual commits that are being merged. Defaults to false, and
true is a synonym for 20. true is a synonym for 20.
merge.suppressDest::
By adding a glob that matches the names of integration
branches to this multi-valued configuration variable, the
default merge message computed for merges into these
integration branches will omit "into <branch name>" from
its title.
+
An element with an empty value can be used to clear the list
of globs accumulated from previous configuration entries.
When there is no `merge.suppressDest` variable defined, the
default value of `master` is used for backward compatibility.

View File

@ -79,7 +79,7 @@ format.thread::
format.signOff:: format.signOff::
A boolean value which lets you enable the `-s/--signoff` option of A boolean value which lets you enable the `-s/--signoff` option of
format-patch by default. *Note:* Adding the `Signed-off-by` trailer to a format-patch by default. *Note:* Adding the Signed-off-by: line to a
patch should be a conscious act and means that you certify you have patch should be a conscious act and means that you certify you have
the rights to submit this work under the same open source license. the rights to submit this work under the same open source license.
Please see the 'SubmittingPatches' document for further discussion. Please see the 'SubmittingPatches' document for further discussion.
@ -94,16 +94,9 @@ format.outputDirectory::
Set a custom directory to store the resulting files instead of the Set a custom directory to store the resulting files instead of the
current working directory. All directory components will be created. current working directory. All directory components will be created.
format.filenameMaxLength::
The maximum length of the output filenames generated by the
`format-patch` command; defaults to 64. Can be overridden
by the `--filename-max-length=<n>` command line option.
format.useAutoBase:: format.useAutoBase::
A boolean value which lets you enable the `--base=auto` option of A boolean value which lets you enable the `--base=auto` option of
format-patch by default. Can also be set to "whenAble" to allow format-patch by default.
enabling `--base=auto` if a suitable base is available, but to skip
adding base info otherwise without the format dying.
format.notes:: format.notes::
Provides the default value for the `--notes` option to Provides the default value for the `--notes` option to

View File

@ -44,9 +44,9 @@ gc.autoDetach::
gc.bigPackThreshold:: gc.bigPackThreshold::
If non-zero, all packs larger than this limit are kept when If non-zero, all packs larger than this limit are kept when
`git gc` is run. This is very similar to `--keep-largest-pack` `git gc` is run. This is very similar to `--keep-base-pack`
except that all packs that meet the threshold are kept, not except that all packs that meet the threshold are kept, not
just the largest pack. Defaults to zero. Common unit suffixes of just the base pack. Defaults to zero. Common unit suffixes of
'k', 'm', or 'g' are supported. 'k', 'm', or 'g' are supported.
+ +
Note that if the number of kept packs is more than gc.autoPackLimit, Note that if the number of kept packs is more than gc.autoPackLimit,
@ -57,7 +57,7 @@ gc.autoPackLimit and gc.bigPackThreshold should be respected again.
If the amount of memory estimated for `git repack` to run smoothly is If the amount of memory estimated for `git repack` to run smoothly is
not available and `gc.bigPackThreshold` is not set, the largest pack not available and `gc.bigPackThreshold` is not set, the largest pack
will also be excluded (this is the equivalent of running `git gc` with will also be excluded (this is the equivalent of running `git gc` with
`--keep-largest-pack`). `--keep-base-pack`).
gc.writeCommitGraph:: gc.writeCommitGraph::
If true, then gc will rewrite the commit-graph file when If true, then gc will rewrite the commit-graph file when

View File

@ -8,14 +8,13 @@ help.format::
the default. 'web' and 'html' are the same. the default. 'web' and 'html' are the same.
help.autoCorrect:: help.autoCorrect::
If git detects typos and can identify exactly one valid command similar Automatically correct and execute mistyped commands after
to the error, git will automatically run the intended command after waiting for the given number of deciseconds (0.1 sec). If more
waiting a duration of time defined by this configuration value in than one command can be deduced from the entered text, nothing
deciseconds (0.1 sec). If this value is 0, the suggested corrections will be executed. If the value of this option is negative,
will be shown, but not executed. If it is a negative integer, or the corrected command will be executed immediately. If the
"immediate", the suggested command value is 0 - the command will be just shown but not executed.
is run immediately. If "never", suggestions are not shown at all. The This is the default.
default value is zero.
help.htmlPath:: help.htmlPath::
Specify the path where the HTML documentation resides. File system paths Specify the path where the HTML documentation resides. File system paths

View File

@ -42,12 +42,12 @@ http.proxySSLKey::
http.proxySSLCertPasswordProtected:: http.proxySSLCertPasswordProtected::
Enable Git's password prompt for the proxy SSL certificate. Otherwise OpenSSL Enable Git's password prompt for the proxy SSL certificate. Otherwise OpenSSL
will prompt the user, possibly many times, if the certificate or private key will prompt the user, possibly many times, if the certificate or private key
is encrypted. Can be overridden by the `GIT_PROXY_SSL_CERT_PASSWORD_PROTECTED` is encrypted. Can be overriden by the `GIT_PROXY_SSL_CERT_PASSWORD_PROTECTED`
environment variable. environment variable.
http.proxySSLCAInfo:: http.proxySSLCAInfo::
Pathname to the file containing the certificate bundle that should be used to Pathname to the file containing the certificate bundle that should be used to
verify the proxy with when using an HTTPS proxy. Can be overridden by the verify the proxy with when using an HTTPS proxy. Can be overriden by the
`GIT_PROXY_SSL_CAINFO` environment variable. `GIT_PROXY_SSL_CAINFO` environment variable.
http.emptyAuth:: http.emptyAuth::

View File

@ -4,4 +4,4 @@ init.templateDir::
init.defaultBranch:: init.defaultBranch::
Allows overriding the default branch name e.g. when initializing Allows overriding the default branch name e.g. when initializing
a new repository. a new repository or when cloning an empty repository.

View File

@ -1,9 +0,0 @@
lsrefs.unborn::
May be "advertise" (the default), "allow", or "ignore". If "advertise",
the server will respond to the client sending "unborn" (as described in
protocol-v2.txt) and will advertise support for this feature during the
protocol v2 capability advertisement. "allow" is the same as
"advertise" except that the server will not advertise support for this
feature; this is useful for load-balanced servers that cannot be
updated atomically (for example), since the administrator could
configure "allow", then after a delay, configure "advertise".

View File

@ -1,60 +0,0 @@
maintenance.auto::
This boolean config option controls whether some commands run
`git maintenance run --auto` after doing their normal work. Defaults
to true.
maintenance.strategy::
This string config option provides a way to specify one of a few
recommended schedules for background maintenance. This only affects
which tasks are run during `git maintenance run --schedule=X`
commands, provided no `--task=<task>` arguments are provided.
Further, if a `maintenance.<task>.schedule` config value is set,
then that value is used instead of the one provided by
`maintenance.strategy`. The possible strategy strings are:
+
* `none`: This default setting implies no task are run at any schedule.
* `incremental`: This setting optimizes for performing small maintenance
activities that do not delete any data. This does not schedule the `gc`
task, but runs the `prefetch` and `commit-graph` tasks hourly, the
`loose-objects` and `incremental-repack` tasks daily, and the `pack-refs`
task weekly.
maintenance.<task>.enabled::
This boolean config option controls whether the maintenance task
with name `<task>` is run when no `--task` option is specified to
`git maintenance run`. These config values are ignored if a
`--task` option exists. By default, only `maintenance.gc.enabled`
is true.
maintenance.<task>.schedule::
This config option controls whether or not the given `<task>` runs
during a `git maintenance run --schedule=<frequency>` command. The
value must be one of "hourly", "daily", or "weekly".
maintenance.commit-graph.auto::
This integer config option controls how often the `commit-graph` task
should be run as part of `git maintenance run --auto`. If zero, then
the `commit-graph` task will not run with the `--auto` option. A
negative value will force the task to run every time. Otherwise, a
positive value implies the command should run when the number of
reachable commits that are not in the commit-graph file is at least
the value of `maintenance.commit-graph.auto`. The default value is
100.
maintenance.loose-objects.auto::
This integer config option controls how often the `loose-objects` task
should be run as part of `git maintenance run --auto`. If zero, then
the `loose-objects` task will not run with the `--auto` option. A
negative value will force the task to run every time. Otherwise, a
positive value implies the command should run when the number of
loose objects is at least the value of `maintenance.loose-objects.auto`.
The default value is 100.
maintenance.incremental-repack.auto::
This integer config option controls how often the `incremental-repack`
task should be run as part of `git maintenance run --auto`. If zero,
then the `incremental-repack` task will not run with the `--auto`
option. A negative value will force the task to run every time.
Otherwise, a positive value implies the command should run when the
number of pack-files not in the multi-pack-index is at least the value
of `maintenance.incremental-repack.auto`. The default value is 10.

View File

@ -13,11 +13,6 @@ mergetool.<tool>.cmd::
merged; 'MERGED' contains the name of the file to which the merge merged; 'MERGED' contains the name of the file to which the merge
tool should write the results of a successful merge. tool should write the results of a successful merge.
mergetool.<tool>.hideResolved::
Allows the user to override the global `mergetool.hideResolved` value
for a specific tool. See `mergetool.hideResolved` for the full
description.
mergetool.<tool>.trustExitCode:: mergetool.<tool>.trustExitCode::
For a custom merge command, specify whether the exit code of For a custom merge command, specify whether the exit code of
the merge command can be used to determine whether the merge was the merge command can be used to determine whether the merge was
@ -35,26 +30,6 @@ mergetool.meld.hasOutput::
to `true` tells Git to unconditionally use the `--output` option, to `true` tells Git to unconditionally use the `--output` option,
and `false` avoids using `--output`. and `false` avoids using `--output`.
mergetool.meld.useAutoMerge::
When the `--auto-merge` is given, meld will merge all non-conflicting
parts automatically, highlight the conflicting parts and wait for
user decision. Setting `mergetool.meld.useAutoMerge` to `true` tells
Git to unconditionally use the `--auto-merge` option with `meld`.
Setting this value to `auto` makes git detect whether `--auto-merge`
is supported and will only use `--auto-merge` when available. A
value of `false` avoids using `--auto-merge` altogether, and is the
default value.
mergetool.hideResolved::
During a merge Git will automatically resolve as many conflicts as
possible and write the 'MERGED' file containing conflict markers around
any conflicts that it cannot resolve; 'LOCAL' and 'REMOTE' normally
represent the versions of the file from before Git's conflict
resolution. This flag causes 'LOCAL' and 'REMOTE' to be overwriten so
that only the unresolved conflicts are presented to the merge tool. Can
be configured per-tool via the `mergetool.<tool>.hideResolved`
configuration variable. Defaults to `true`.
mergetool.keepBackup:: mergetool.keepBackup::
After performing a merge, the original file with conflict markers After performing a merge, the original file with conflict markers
can be saved as a file with a `.orig` extension. If this variable can be saved as a file with a `.orig` extension. If this variable

View File

@ -133,10 +133,3 @@ pack.writeBitmapHashCache::
between an older, bitmapped pack and objects that have been between an older, bitmapped pack and objects that have been
pushed since the last gc). The downside is that it consumes 4 pushed since the last gc). The downside is that it consumes 4
bytes per object of disk space. Defaults to true. bytes per object of disk space. Defaults to true.
pack.writeReverseIndex::
When true, git will write a corresponding .rev file (see:
link:../technical/pack-format.html[Documentation/technical/pack-format.txt])
for each new packfile that it writes in all places except for
linkgit:git-fast-import[1] and in the bulk checkin mechanism.
Defaults to false.

View File

@ -48,7 +48,8 @@ protocol.version::
If set, clients will attempt to communicate with a server If set, clients will attempt to communicate with a server
using the specified protocol version. If the server does using the specified protocol version. If the server does
not support it, communication falls back to version 0. not support it, communication falls back to version 0.
If unset, the default is `2`. If unset, the default is `0`, unless `feature.experimental`
is enabled, in which case the default is `2`.
Supported versions: Supported versions:
+ +
-- --

View File

@ -114,9 +114,3 @@ push.recurseSubmodules::
specifying '--recurse-submodules=check|on-demand|no'. specifying '--recurse-submodules=check|on-demand|no'.
If not set, 'no' is used by default, unless 'submodule.recurse' is If not set, 'no' is used by default, unless 'submodule.recurse' is
set (in which case a 'true' value means 'on-demand'). set (in which case a 'true' value means 'on-demand').
push.useForceIfIncludes::
If set to "true", it is equivalent to specifying
`--force-if-includes` as an option to linkgit:git-push[1]
in the command line. Adding `--no-force-if-includes` at the
time of push overrides this configuration setting.

View File

@ -68,6 +68,3 @@ rebase.rescheduleFailedExec::
Automatically reschedule `exec` commands that failed. This only makes Automatically reschedule `exec` commands that failed. This only makes
sense in interactive mode (or when an `--exec` option was provided). sense in interactive mode (or when an `--exec` option was provided).
This is the same as specifying the `--reschedule-failed-exec` option. This is the same as specifying the `--reschedule-failed-exec` option.
rebase.forkPoint::
If set to false set `--no-fork-point` option by default.

View File

@ -114,28 +114,6 @@ receive.hideRefs::
An attempt to update or delete a hidden ref by `git push` is An attempt to update or delete a hidden ref by `git push` is
rejected. rejected.
receive.procReceiveRefs::
This is a multi-valued variable that defines reference prefixes
to match the commands in `receive-pack`. Commands matching the
prefixes will be executed by an external hook "proc-receive",
instead of the internal `execute_commands` function. If this
variable is not defined, the "proc-receive" hook will never be
used, and all commands will be executed by the internal
`execute_commands` function.
+
For example, if this variable is set to "refs/for", pushing to reference
such as "refs/for/master" will not create or update a reference named
"refs/for/master", but may create or update a pull request directly by
running the hook "proc-receive".
+
Optional modifiers can be provided in the beginning of the value to filter
commands for specific actions: create (a), modify (m), delete (d).
A `!` can be included in the modifiers to negate the reference prefix entry.
E.g.:
+
git config --system --add receive.procReceiveRefs ad:refs/heads
git config --system --add receive.procReceiveRefs !:refs/heads
receive.updateServerInfo:: receive.updateServerInfo::
If set to true, git-receive-pack will run git-update-server-info If set to true, git-receive-pack will run git-update-server-info
after receiving data from git-push and updating refs. after receiving data from git-push and updating refs.

View File

@ -61,8 +61,3 @@ sendemail.smtpBatchSize::
sendemail.smtpReloginDelay:: sendemail.smtpReloginDelay::
Seconds wait before reconnecting to smtp server. Seconds wait before reconnecting to smtp server.
See also the `--relogin-delay` option of linkgit:git-send-email[1]. See also the `--relogin-delay` option of linkgit:git-send-email[1].
sendemail.forbidSendmailVariables::
To avoid common misconfiguration mistakes, linkgit:git-send-email[1]
will abort with a warning if any configuration options for "sendmail"
exist. Set this variable to bypass the check.

View File

@ -54,7 +54,7 @@ trace2.envVars::
`GIT_HTTP_USER_AGENT,GIT_CONFIG` would cause the trace2 output to `GIT_HTTP_USER_AGENT,GIT_CONFIG` would cause the trace2 output to
contain events listing the overrides for HTTP user agent and the contain events listing the overrides for HTTP user agent and the
location of the Git configuration file (assuming any are set). May be location of the Git configuration file (assuming any are set). May be
overridden by the `GIT_TRACE2_ENV_VARS` environment variable. Unset by overriden by the `GIT_TRACE2_ENV_VARS` environment variable. Unset by
default. default.
trace2.destinationDebug:: trace2.destinationDebug::

View File

@ -69,7 +69,3 @@ transfer.unpackLimit::
When `fetch.unpackLimit` or `receive.unpackLimit` are When `fetch.unpackLimit` or `receive.unpackLimit` are
not set, the value of this variable is used instead. not set, the value of this variable is used instead.
The default value is 100. The default value is 100.
transfer.advertiseSID::
Boolean. When true, client and server processes will advertise their
unique session IDs to their remote counterpart. Defaults to false.

View File

@ -57,24 +57,6 @@ uploadpack.allowFilter::
If this option is set, `upload-pack` will support partial If this option is set, `upload-pack` will support partial
clone and partial fetch object filtering. clone and partial fetch object filtering.
uploadpackfilter.allow::
Provides a default value for unspecified object filters (see: the
below configuration variable).
Defaults to `true`.
uploadpackfilter.<filter>.allow::
Explicitly allow or ban the object filter corresponding to
`<filter>`, where `<filter>` may be one of: `blob:none`,
`blob:limit`, `tree`, `sparse:oid`, or `combine`. If using
combined filters, both `combine` and all of the nested filter
kinds must be allowed. Defaults to `uploadpackfilter.allow`.
uploadpackfilter.tree.maxDepth::
Only allow `--filter=tree:<n>` when `<n>` is no more than the value of
`uploadpackfilter.tree.maxDepth`. If set, this also implies
`uploadpackfilter.tree.allow=true`, unless this configuration
variable had already been set. Has no effect if unset.
uploadpack.allowRefInWant:: uploadpack.allowRefInWant::
If this option is set, `upload-pack` will support the `ref-in-want` If this option is set, `upload-pack` will support the `ref-in-want`
feature of the protocol version 2 `fetch` command. This feature feature of the protocol version 2 `fetch` command. This feature

View File

@ -1,7 +1,10 @@
DATE FORMATS DATE FORMATS
------------ ------------
The `GIT_AUTHOR_DATE` and `GIT_COMMITTER_DATE` environment variables The `GIT_AUTHOR_DATE`, `GIT_COMMITTER_DATE` environment variables
ifdef::git-commit[]
and the `--date` option
endif::git-commit[]
support the following date formats: support the following date formats:
Git internal format:: Git internal format::
@ -23,9 +26,3 @@ ISO 8601::
+ +
NOTE: In addition, the date part is accepted in the following formats: NOTE: In addition, the date part is accepted in the following formats:
`YYYY.MM.DD`, `MM/DD/YYYY` and `DD.MM.YYYY`. `YYYY.MM.DD`, `MM/DD/YYYY` and `DD.MM.YYYY`.
ifdef::git-commit[]
In addition to recognizing all date formats above, the `--date` option
will also try to make sense of other, more human-centric date formats,
such as relative dates like "yesterday" or "last Friday at noon".
endif::git-commit[]

View File

@ -10,8 +10,7 @@ linkgit:git-diff-tree[1], or
linkgit:git-diff-files[1] linkgit:git-diff-files[1]
with the `-p` option produces patch text. with the `-p` option produces patch text.
You can customize the creation of patch text via the You can customize the creation of patch text via the
`GIT_EXTERNAL_DIFF` and the `GIT_DIFF_OPTS` environment variables `GIT_EXTERNAL_DIFF` and the `GIT_DIFF_OPTS` environment variables.
(see linkgit:git[1]).
What the -p option produces is slightly different from the traditional What the -p option produces is slightly different from the traditional
diff format: diff format:
@ -81,9 +80,9 @@ Combined diff format
Any diff-generating command can take the `-c` or `--cc` option to Any diff-generating command can take the `-c` or `--cc` option to
produce a 'combined diff' when showing a merge. This is the default produce a 'combined diff' when showing a merge. This is the default
format when showing merges with linkgit:git-diff[1] or format when showing merges with linkgit:git-diff[1] or
linkgit:git-show[1]. Note also that you can give suitable linkgit:git-show[1]. Note also that you can give the `-m` option to any
`--diff-merges` option to any of these commands to force generation of of these commands to force generation of diffs with individual parents
diffs in specific format. of a merge.
A "combined diff" format looks like this: A "combined diff" format looks like this:

View File

@ -33,63 +33,12 @@ endif::git-diff[]
show the patch by default, or to cancel the effect of `--patch`. show the patch by default, or to cancel the effect of `--patch`.
endif::git-format-patch[] endif::git-format-patch[]
ifdef::git-log[]
--diff-merges=(off|none|first-parent|1|separate|m|combined|c|dense-combined|cc)::
--no-diff-merges::
Specify diff format to be used for merge commits. Default is
{diff-merges-default} unless `--first-parent` is in use, in which case
`first-parent` is the default.
+
--diff-merges=(off|none):::
--no-diff-merges:::
Disable output of diffs for merge commits. Useful to override
implied value.
+
--diff-merges=first-parent:::
--diff-merges=1:::
This option makes merge commits show the full diff with
respect to the first parent only.
+
--diff-merges=separate:::
--diff-merges=m:::
-m:::
This makes merge commits show the full diff with respect to
each of the parents. Separate log entry and diff is generated
for each parent. `-m` doesn't produce any output without `-p`.
+
--diff-merges=combined:::
--diff-merges=c:::
-c:::
With this option, diff output for a merge commit shows the
differences from each of the parents to the merge result
simultaneously instead of showing pairwise diff between a
parent and the result one at a time. Furthermore, it lists
only files which were modified from all parents. `-c` implies
`-p`.
+
--diff-merges=dense-combined:::
--diff-merges=cc:::
--cc:::
With this option the output produced by
`--diff-merges=combined` is further compressed by omitting
uninteresting hunks whose contents in the parents have only
two variants and the merge result picks one of them without
modification. `--cc` implies `-p`.
--combined-all-paths::
This flag causes combined diffs (used for merge commits) to
list the name of the file from all parents. It thus only has
effect when `--diff-merges=[dense-]combined` is in use, and
is likely only useful if filename changes are detected (i.e.
when either rename or copy detection have been requested).
endif::git-log[]
-U<n>:: -U<n>::
--unified=<n>:: --unified=<n>::
Generate diffs with <n> lines of context instead of Generate diffs with <n> lines of context instead of
the usual three. the usual three. Implies `--patch`.
ifndef::git-format-patch[] ifndef::git-format-patch[]
Implies `--patch`. Implies `-p`.
endif::git-format-patch[] endif::git-format-patch[]
--output=<file>:: --output=<file>::
@ -124,11 +73,6 @@ ifndef::git-format-patch[]
Synonym for `-p --raw`. Synonym for `-p --raw`.
endif::git-format-patch[] endif::git-format-patch[]
ifdef::git-log[]
-t::
Show the tree objects in the diff output.
endif::git-log[]
--indent-heuristic:: --indent-heuristic::
Enable the heuristic that shifts diff hunk boundaries to make patches Enable the heuristic that shifts diff hunk boundaries to make patches
easier to read. This is the default. easier to read. This is the default.
@ -492,20 +436,15 @@ endif::git-format-patch[]
--binary:: --binary::
In addition to `--full-index`, output a binary diff that In addition to `--full-index`, output a binary diff that
can be applied with `git-apply`. can be applied with `git-apply`. Implies `--patch`.
ifndef::git-format-patch[]
Implies `--patch`.
endif::git-format-patch[]
--abbrev[=<n>]:: --abbrev[=<n>]::
Instead of showing the full 40-byte hexadecimal object Instead of showing the full 40-byte hexadecimal object
name in diff-raw format output and diff-tree header name in diff-raw format output and diff-tree header
lines, show the shortest prefix that is at least '<n>' lines, show only a partial prefix. This is
hexdigits long that uniquely refers the object. independent of the `--full-index` option above, which controls
In diff-patch output format, `--full-index` takes higher the diff-patch output format. Non default number of
precedence, i.e. if `--full-index` is specified, full blob digits can be specified with `--abbrev=<n>`.
names will be shown regardless of `--abbrev`.
Non default number of digits can be specified with `--abbrev=<n>`.
-B[<n>][/<m>]:: -B[<n>][/<m>]::
--break-rewrites[=[<n>][/<m>]]:: --break-rewrites[=[<n>][/<m>]]::
@ -700,14 +639,6 @@ matches a pattern if removing any number of the final pathname
components matches the pattern. For example, the pattern "`foo*bar`" components matches the pattern. For example, the pattern "`foo*bar`"
matches "`fooasdfbar`" and "`foo/bar/baz/asdf`" but not "`foobarx`". matches "`fooasdfbar`" and "`foo/bar/baz/asdf`" but not "`foobarx`".
--skip-to=<file>::
--rotate-to=<file>::
Discard the files before the named <file> from the output
(i.e. 'skip to'), or move them to the end of the output
(i.e. 'rotate to'). These were invented primarily for use
of the `git difftool` command, and may not be very useful
otherwise.
ifndef::git-format-patch[] ifndef::git-format-patch[]
-R:: -R::
Swap two inputs; that is, show differences from index or Swap two inputs; that is, show differences from index or
@ -750,11 +681,6 @@ endif::git-format-patch[]
--ignore-blank-lines:: --ignore-blank-lines::
Ignore changes whose lines are all blank. Ignore changes whose lines are all blank.
-I<regex>::
--ignore-matching-lines=<regex>::
Ignore changes whose all lines match <regex>. This option may
be specified more than once.
--inter-hunk-context=<lines>:: --inter-hunk-context=<lines>::
Show the context between diff hunks, up to the specified number Show the context between diff hunks, up to the specified number
of lines, thereby fusing hunks that are close to each other. of lines, thereby fusing hunks that are close to each other.
@ -763,10 +689,7 @@ endif::git-format-patch[]
-W:: -W::
--function-context:: --function-context::
Show whole function as context lines for each change. Show whole surrounding functions of changes.
The function names are determined in the same way as
`git diff` works out patch hunk headers (see 'Defining a
custom hunk-header' in linkgit:gitattributes[5]).
ifndef::git-format-patch[] ifndef::git-format-patch[]
ifndef::git-log[] ifndef::git-log[]

View File

@ -7,10 +7,6 @@
existing contents of `.git/FETCH_HEAD`. Without this existing contents of `.git/FETCH_HEAD`. Without this
option old data in `.git/FETCH_HEAD` will be overwritten. option old data in `.git/FETCH_HEAD` will be overwritten.
--atomic::
Use an atomic transaction to update local refs. Either all refs are
updated, or on error, no refs are updated.
--depth=<depth>:: --depth=<depth>::
Limit fetching to the specified number of commits from the tip of Limit fetching to the specified number of commits from the tip of
each remote branch history. If fetching to a 'shallow' repository each remote branch history. If fetching to a 'shallow' repository
@ -68,15 +64,6 @@ documented in linkgit:git-config[1].
--dry-run:: --dry-run::
Show what would be done, without making any changes. Show what would be done, without making any changes.
ifndef::git-pull[]
--[no-]write-fetch-head::
Write the list of remote refs fetched in the `FETCH_HEAD`
file directly under `$GIT_DIR`. This is the default.
Passing `--no-write-fetch-head` from the command line tells
Git not to write the file. Under `--dry-run` option, the
file is never written.
endif::git-pull[]
-f:: -f::
--force:: --force::
When 'git fetch' is used with `<src>:<dst>` refspec it may When 'git fetch' is used with `<src>:<dst>` refspec it may
@ -99,11 +86,9 @@ ifndef::git-pull[]
Allow several <repository> and <group> arguments to be Allow several <repository> and <group> arguments to be
specified. No <refspec>s may be specified. specified. No <refspec>s may be specified.
--[no-]auto-maintenance::
--[no-]auto-gc:: --[no-]auto-gc::
Run `git maintenance run --auto` at the end to perform automatic Run `git gc --auto` at the end to perform garbage collection
repository maintenance if needed. (`--[no-]auto-gc` is a synonym.) if needed. This is enabled by default.
This is enabled by default.
--[no-]write-commit-graph:: --[no-]write-commit-graph::
Write a commit-graph after fetching. This overrides the config Write a commit-graph after fetching. This overrides the config
@ -201,7 +186,7 @@ ifndef::git-pull[]
endif::git-pull[] endif::git-pull[]
--set-upstream:: --set-upstream::
If the remote is fetched successfully, add upstream If the remote is fetched successfully, pull and add upstream
(tracking) reference, used by argument-less (tracking) reference, used by argument-less
linkgit:git-pull[1] and other commands. For more information, linkgit:git-pull[1] and other commands. For more information,
see `branch.<name>.merge` and `branch.<name>.remote` in see `branch.<name>.merge` and `branch.<name>.remote` in

View File

@ -33,7 +33,7 @@ OPTIONS
-s:: -s::
--signoff:: --signoff::
Add a `Signed-off-by` trailer to the commit message, using Add a `Signed-off-by:` line to the commit message, using
the committer identity of yourself. the committer identity of yourself.
See the signoff option in linkgit:git-commit[1] for more information. See the signoff option in linkgit:git-commit[1] for more information.
@ -79,7 +79,7 @@ OPTIONS
Pass `-u` flag to 'git mailinfo' (see linkgit:git-mailinfo[1]). Pass `-u` flag to 'git mailinfo' (see linkgit:git-mailinfo[1]).
The proposed commit log message taken from the e-mail The proposed commit log message taken from the e-mail
is re-coded into UTF-8 encoding (configuration variable is re-coded into UTF-8 encoding (configuration variable
`i18n.commitEncoding` can be used to specify project's `i18n.commitencoding` can be used to specify project's
preferred encoding if it is not UTF-8). preferred encoding if it is not UTF-8).
+ +
This was optional in prior versions of git, but now it is the This was optional in prior versions of git, but now it is the

View File

@ -61,18 +61,18 @@ OPTIONS
file and detects errors. Turns off "apply". file and detects errors. Turns off "apply".
--index:: --index::
Apply the patch to both the index and the working tree (or When `--check` is in effect, or when applying the patch
merely check that it would apply cleanly to both if `--check` is (which is the default when none of the options that
in effect). Note that `--index` expects index entries and disables it is in effect), make sure the patch is
working tree copies for relevant paths to be identical (their applicable to what the current index file records. If
contents and metadata such as file mode must match), and will the file to be patched in the working tree is not
raise an error if they are not, even if the patch would apply up to date, it is flagged as an error. This flag also
cleanly to both the index and the working tree in isolation. causes the index file to be updated.
--cached:: --cached::
Apply the patch to just the index, without touching the working Apply a patch without touching the working tree. Instead take the
tree. If `--check` is in effect, merely check that it would cached data, apply the patch, and store the result in the index
apply cleanly to the index entry. without using the working tree. This implies `--index`.
--intent-to-add:: --intent-to-add::
When applying the patch only to the working tree, mark new When applying the patch only to the working tree, mark new

View File

@ -55,12 +55,6 @@ OPTIONS
--output=<file>:: --output=<file>::
Write the archive to <file> instead of stdout. Write the archive to <file> instead of stdout.
--add-file=<file>::
Add a non-tracked file to the archive. Can be repeated to add
multiple files. The path of the file in the archive is built
by concatenating the value for `--prefix` (if any) and the
basename of <file>.
--worktree-attributes:: --worktree-attributes::
Look for attributes in .gitattributes files in the working tree Look for attributes in .gitattributes files in the working tree
as well (see <<ATTRIBUTES>>). as well (see <<ATTRIBUTES>>).

View File

@ -473,7 +473,7 @@ Z-Z
------------- -------------
2) starting from the "good" ends of the graph, associate to each 2) starting from the "good" ends of the graph, associate to each
commit the number of ancestors it has plus one commit the number of ancestors it has plus one
For example with the following graph where H is the "bad" commit and A For example with the following graph where H is the "bad" commit and A
and D are some parents of some "good" commits: and D are some parents of some "good" commits:
@ -514,7 +514,7 @@ D---E
------------- -------------
4) the best bisection point is the commit with the highest associated 4) the best bisection point is the commit with the highest associated
number number
So in the above example the best bisection point is commit C. So in the above example the best bisection point is commit C.
@ -580,8 +580,8 @@ good or a bad commit does not give more or less information).
Let's also suppose that we have a cleaned up graph like one after step Let's also suppose that we have a cleaned up graph like one after step
1) in the bisection algorithm above. This means that we can measure 1) in the bisection algorithm above. This means that we can measure
the information we get in terms of number of commit we can remove the information we get in terms of number of commit we can remove from
from the graph.. the graph..
And let's take a commit X in the graph. And let's take a commit X in the graph.
@ -689,18 +689,18 @@ roughly the following steps:
6) sort the commit by decreasing associated value 6) sort the commit by decreasing associated value
7) if the first commit has not been skipped, we can return it and stop 7) if the first commit has not been skipped, we can return it and stop
here here
8) otherwise filter out all the skipped commits in the sorted list 8) otherwise filter out all the skipped commits in the sorted list
9) use a pseudo random number generator (PRNG) to generate a random 9) use a pseudo random number generator (PRNG) to generate a random
number between 0 and 1 number between 0 and 1
10) multiply this random number with its square root to bias it toward 10) multiply this random number with its square root to bias it toward
0 0
11) multiply the result by the number of commits in the filtered list 11) multiply the result by the number of commits in the filtered list
to get an index into this list to get an index into this list
12) return the commit at the computed index 12) return the commit at the computed index

View File

@ -16,8 +16,8 @@ DESCRIPTION
The command takes various subcommands, and different options depending The command takes various subcommands, and different options depending
on the subcommand: on the subcommand:
git bisect start [--term-{new,bad}=<term> --term-{old,good}=<term>] git bisect start [--term-{old,good}=<term> --term-{new,bad}=<term>]
[--no-checkout] [--first-parent] [<bad> [<good>...]] [--] [<paths>...] [--no-checkout] [<bad> [<good>...]] [--] [<paths>...]
git bisect (bad|new|<term-new>) [<rev>] git bisect (bad|new|<term-new>) [<rev>]
git bisect (good|old|<term-old>) [<rev>...] git bisect (good|old|<term-old>) [<rev>...]
git bisect terms [--term-good | --term-bad] git bisect terms [--term-good | --term-bad]
@ -365,17 +365,6 @@ does not require a checked out tree.
+ +
If the repository is bare, `--no-checkout` is assumed. If the repository is bare, `--no-checkout` is assumed.
--first-parent::
+
Follow only the first parent commit upon seeing a merge commit.
+
In detecting regressions introduced through the merging of a branch, the merge
commit will be identified as introduction of the bug and its ancestors will be
ignored.
+
This option is particularly useful in avoiding false positives when a merged
branch contained broken or non-buildable commits, but the merge itself was OK.
EXAMPLES EXAMPLES
-------- --------

View File

@ -87,9 +87,7 @@ include::blame-options.txt[]
--abbrev=<n>:: --abbrev=<n>::
Instead of using the default 7+1 hexadecimal digits as the Instead of using the default 7+1 hexadecimal digits as the
abbreviated object name, use <m>+1 digits, where <m> is at abbreviated object name, use <n>+1 digits. Note that 1 column
least <n> but ensures the commit object names are unique.
Note that 1 column
is used for a caret to mark the boundary commit. is used for a caret to mark the boundary commit.
@ -226,7 +224,7 @@ commit commentary), a blame viewer will not care.
MAPPING AUTHORS MAPPING AUTHORS
--------------- ---------------
See linkgit:gitmailmap[5]. include::mailmap.txt[]
SEE ALSO SEE ALSO

View File

@ -9,9 +9,9 @@ SYNOPSIS
-------- --------
[verse] [verse]
'git branch' [--color[=<when>] | --no-color] [--show-current] 'git branch' [--color[=<when>] | --no-color] [--show-current]
[-v [--abbrev=<n> | --no-abbrev]] [-v [--abbrev=<length> | --no-abbrev]]
[--column[=<options>] | --no-column] [--sort=<key>] [--column[=<options>] | --no-column] [--sort=<key>]
[--merged [<commit>]] [--no-merged [<commit>]] [(--merged | --no-merged) [<commit>]]
[--contains [<commit>]] [--no-contains [<commit>]] [--contains [<commit>]] [--no-contains [<commit>]]
[--points-at <object>] [--format=<format>] [--points-at <object>] [--format=<format>]
[(-r | --remotes) | (-a | --all)] [(-r | --remotes) | (-a | --all)]
@ -78,8 +78,8 @@ renaming. If <newbranch> exists, -M must be used to force the rename
to happen. to happen.
The `-c` and `-C` options have the exact same semantics as `-m` and The `-c` and `-C` options have the exact same semantics as `-m` and
`-M`, except instead of the branch being renamed, it will be copied to a `-M`, except instead of the branch being renamed it along with its
new name, along with its config and reflog. config and reflog will be copied to a new name.
With a `-d` or `-D` option, `<branchname>` will be deleted. You may With a `-d` or `-D` option, `<branchname>` will be deleted. You may
specify more than one branch for deletion. If the branch currently specify more than one branch for deletion. If the branch currently
@ -153,7 +153,7 @@ OPTIONS
--column[=<options>]:: --column[=<options>]::
--no-column:: --no-column::
Display branch listing in columns. See configuration variable Display branch listing in columns. See configuration variable
`column.branch` for option syntax. `--column` and `--no-column` column.branch for option syntax.`--column` and `--no-column`
without options are equivalent to 'always' and 'never' respectively. without options are equivalent to 'always' and 'never' respectively.
+ +
This option is only applicable in non-verbose mode. This option is only applicable in non-verbose mode.
@ -194,10 +194,8 @@ This option is only applicable in non-verbose mode.
Be more quiet when creating or deleting a branch, suppressing Be more quiet when creating or deleting a branch, suppressing
non-error messages. non-error messages.
--abbrev=<n>:: --abbrev=<length>::
In the verbose listing that show the commit object name, Alter the sha1's minimum display length in the output listing.
show the shortest prefix that is at least '<n>' hexdigits
long that uniquely refers the object.
The default value is 7 and can be overridden by the `core.abbrev` The default value is 7 and can be overridden by the `core.abbrev`
config option. config option.
@ -254,11 +252,13 @@ start-point is either a local or remote-tracking branch.
--merged [<commit>]:: --merged [<commit>]::
Only list branches whose tips are reachable from the Only list branches whose tips are reachable from the
specified commit (HEAD if not specified). Implies `--list`. specified commit (HEAD if not specified). Implies `--list`,
incompatible with `--no-merged`.
--no-merged [<commit>]:: --no-merged [<commit>]::
Only list branches whose tips are not reachable from the Only list branches whose tips are not reachable from the
specified commit (HEAD if not specified). Implies `--list`. specified commit (HEAD if not specified). Implies `--list`,
incompatible with `--merged`.
<branchname>:: <branchname>::
The name of the branch to create or delete. The name of the branch to create or delete.
@ -370,8 +370,6 @@ serve four related but different purposes:
- `--no-merged` is used to find branches which are candidates for merging - `--no-merged` is used to find branches which are candidates for merging
into HEAD, since those branches are not fully contained by HEAD. into HEAD, since those branches are not fully contained by HEAD.
include::ref-reachability-filters.txt[]
SEE ALSO SEE ALSO
-------- --------
linkgit:git-check-ref-format[1], linkgit:git-check-ref-format[1],

View File

@ -9,8 +9,7 @@ git-bundle - Move objects and refs by archive
SYNOPSIS SYNOPSIS
-------- --------
[verse] [verse]
'git bundle' create [-q | --quiet | --progress | --all-progress] [--all-progress-implied] 'git bundle' create [-q | --quiet | --progress | --all-progress] [--all-progress-implied] <file> <git-rev-list-args>
[--version=<version>] <file> <git-rev-list-args>
'git bundle' verify [-q | --quiet] <file> 'git bundle' verify [-q | --quiet] <file>
'git bundle' list-heads <file> [<refname>...] 'git bundle' list-heads <file> [<refname>...]
'git bundle' unbundle <file> [<refname>...] 'git bundle' unbundle <file> [<refname>...]
@ -103,12 +102,6 @@ unbundle <file>::
is activated. Unlike --all-progress this flag doesn't actually is activated. Unlike --all-progress this flag doesn't actually
force any progress display by itself. force any progress display by itself.
--version=<version>::
Specify the bundle version. Version 2 is the older format and can only be
used with SHA-1 repositories; the newer version 3 contains capabilities that
permit extensions. The default is the oldest supported format, based on the
hash algorithm in use.
-q:: -q::
--quiet:: --quiet::
This flag makes the command not to report its progress This flag makes the command not to report its progress

View File

@ -36,17 +36,10 @@ name is provided or known to the 'mailmap', ``Name $$<user@host>$$'' is
printed; otherwise only ``$$<user@host>$$'' is printed. printed; otherwise only ``$$<user@host>$$'' is printed.
CONFIGURATION
-------------
See `mailmap.file` and `mailmap.blob` in linkgit:git-config[1] for how
to specify a custom `.mailmap` target file or object.
MAPPING AUTHORS MAPPING AUTHORS
--------------- ---------------
See linkgit:gitmailmap[5]. include::mailmap.txt[]
GIT GIT

View File

@ -192,16 +192,12 @@ branches from there if `<branch>` is ambiguous but exists on the
'origin' remote. See also `checkout.defaultRemote` in 'origin' remote. See also `checkout.defaultRemote` in
linkgit:git-config[1]. linkgit:git-config[1].
+ +
`--guess` is the default behavior. Use `--no-guess` to disable it. Use `--no-guess` to disable this.
+
The default behavior can be set via the `checkout.guess` configuration
variable.
-l:: -l::
Create the new branch's reflog; see linkgit:git-branch[1] for Create the new branch's reflog; see linkgit:git-branch[1] for
details. details.
-d::
--detach:: --detach::
Rather than checking out a branch to work on it, check out a Rather than checking out a branch to work on it, check out a
commit for inspection and discardable experiments. commit for inspection and discardable experiments.
@ -354,10 +350,6 @@ leave out at most one of `A` and `B`, in which case it defaults to `HEAD`.
<tree-ish>:: <tree-ish>::
Tree to checkout from (when paths are given). If not specified, Tree to checkout from (when paths are given). If not specified,
the index will be used. the index will be used.
+
As a special case, you may use `"A...B"` as a shortcut for the
merge base of `A` and `B` if there is exactly one merge base. You can
leave out at most one of `A` and `B`, in which case it defaults to `HEAD`.
\--:: \--::
Do not interpret any more arguments as options. Do not interpret any more arguments as options.

View File

@ -104,7 +104,7 @@ effect to your index in a row.
-s:: -s::
--signoff:: --signoff::
Add a `Signed-off-by` trailer at the end of the commit message. Add Signed-off-by line at the end of the commit message.
See the signoff option in linkgit:git-commit[1] for more information. See the signoff option in linkgit:git-commit[1] for more information.
-S[<keyid>]:: -S[<keyid>]::

View File

@ -57,10 +57,6 @@ repository is specified as a URL, then this flag is ignored (and we
never use the local optimizations). Specifying `--no-local` will never use the local optimizations). Specifying `--no-local` will
override the default when `/path/to/repo` is given, using the regular override the default when `/path/to/repo` is given, using the regular
Git transport instead. Git transport instead.
+
*NOTE*: this operation can race with concurrent modification to the
source repository, similar to running `cp -r src dst` while modifying
`src`.
--no-hardlinks:: --no-hardlinks::
Force the cloning process from a repository on a local Force the cloning process from a repository on a local
@ -82,9 +78,9 @@ repository using this option and then delete branches (or use any
other Git command that makes any existing commit unreferenced) in the other Git command that makes any existing commit unreferenced) in the
source repository, some objects may become unreferenced (or dangling). source repository, some objects may become unreferenced (or dangling).
These objects may be removed by normal Git operations (such as `git commit`) These objects may be removed by normal Git operations (such as `git commit`)
which automatically call `git maintenance run --auto`. (See which automatically call `git gc --auto`. (See linkgit:git-gc[1].)
linkgit:git-maintenance[1].) If these objects are removed and were referenced If these objects are removed and were referenced by the cloned repository,
by the cloned repository, then the cloned repository will become corrupt. then the cloned repository will become corrupt.
+ +
Note that running `git repack` without the `--local` option in a repository Note that running `git repack` without the `--local` option in a repository
cloned with `--shared` will copy objects from the source repository into a pack cloned with `--shared` will copy objects from the source repository into a pack
@ -187,9 +183,8 @@ objects from the source repository into a pack in the cloned repository.
-o <name>:: -o <name>::
--origin <name>:: --origin <name>::
Instead of using the remote name `origin` to keep track of the upstream Instead of using the remote name `origin` to keep track
repository, use `<name>`. Overrides `clone.defaultRemoteName` from the of the upstream repository, use `<name>`.
config.
-b <name>:: -b <name>::
--branch <name>:: --branch <name>::

View File

@ -39,9 +39,7 @@ COMMANDS
-------- --------
'write':: 'write'::
Write a commit-graph file based on the commits found in packfiles. If Write a commit-graph file based on the commits found in packfiles.
the config option `core.commitGraph` is disabled, then this command will
output a warning, then return success without writing a commit-graph file.
+ +
With the `--stdin-packs` option, generate the new commit graph by With the `--stdin-packs` option, generate the new commit graph by
walking objects only in the specified pack-indexes. (Cannot be combined walking objects only in the specified pack-indexes. (Cannot be combined
@ -64,17 +62,7 @@ existing commit-graph file.
With the `--changed-paths` option, compute and write information about the With the `--changed-paths` option, compute and write information about the
paths changed between a commit and its first parent. This operation can paths changed between a commit and its first parent. This operation can
take a while on large repositories. It provides significant performance gains take a while on large repositories. It provides significant performance gains
for getting history of a directory or a file with `git log -- <path>`. If for getting history of a directory or a file with `git log -- <path>`.
this option is given, future commit-graph writes will automatically assume
that this option was intended. Use `--no-changed-paths` to stop storing this
data.
+
With the `--max-new-filters=<n>` option, generate at most `n` new Bloom
filters (if `--changed-paths` is specified). If `n` is `-1`, no limit is
enforced. Only commits present in the new layer count against this
limit. To retroactively compute Bloom filters over earlier layers, it is
advised to use `--split=replace`. Overrides the `commitGraph.maxNewFilters`
configuration.
+ +
With the `--split[=<strategy>]` option, write the commit-graph as a With the `--split[=<strategy>]` option, write the commit-graph as a
chain of multiple commit-graph files stored in chain of multiple commit-graph files stored in

View File

@ -59,7 +59,6 @@ commit by giving the same set of parameters (options and paths).
If you make a commit and then find a mistake immediately after If you make a commit and then find a mistake immediately after
that, you can recover from it with 'git reset'. that, you can recover from it with 'git reset'.
:git-commit: 1
OPTIONS OPTIONS
------- -------
@ -164,7 +163,14 @@ The `-m` option is mutually exclusive with `-c`, `-C`, and `-F`.
message, the commit is aborted. This has no effect when a message message, the commit is aborted. This has no effect when a message
is given by other means, e.g. with the `-m` or `-F` options. is given by other means, e.g. with the `-m` or `-F` options.
include::signoff-option.txt[] -s::
--signoff::
Add Signed-off-by line by the committer at the end of the commit
log message. The meaning of a signoff depends on the project,
but it typically certifies that committer has
the rights to submit this work under the same license and
agrees to a Developer Certificate of Origin
(see http://developercertificate.org/ for more information).
-n:: -n::
--no-verify:: --no-verify::

View File

@ -9,15 +9,15 @@ git-config - Get and set repository or global options
SYNOPSIS SYNOPSIS
-------- --------
[verse] [verse]
'git config' [<file-option>] [--type=<type>] [--fixed-value] [--show-origin] [--show-scope] [-z|--null] name [value [value-pattern]] 'git config' [<file-option>] [--type=<type>] [--show-origin] [--show-scope] [-z|--null] name [value [value_regex]]
'git config' [<file-option>] [--type=<type>] --add name value 'git config' [<file-option>] [--type=<type>] --add name value
'git config' [<file-option>] [--type=<type>] [--fixed-value] --replace-all name value [value-pattern] 'git config' [<file-option>] [--type=<type>] --replace-all name value [value_regex]
'git config' [<file-option>] [--type=<type>] [--show-origin] [--show-scope] [-z|--null] [--fixed-value] --get name [value-pattern] 'git config' [<file-option>] [--type=<type>] [--show-origin] [--show-scope] [-z|--null] --get name [value_regex]
'git config' [<file-option>] [--type=<type>] [--show-origin] [--show-scope] [-z|--null] [--fixed-value] --get-all name [value-pattern] 'git config' [<file-option>] [--type=<type>] [--show-origin] [--show-scope] [-z|--null] --get-all name [value_regex]
'git config' [<file-option>] [--type=<type>] [--show-origin] [--show-scope] [-z|--null] [--fixed-value] [--name-only] --get-regexp name_regex [value-pattern] 'git config' [<file-option>] [--type=<type>] [--show-origin] [--show-scope] [-z|--null] [--name-only] --get-regexp name_regex [value_regex]
'git config' [<file-option>] [--type=<type>] [-z|--null] --get-urlmatch name URL 'git config' [<file-option>] [--type=<type>] [-z|--null] --get-urlmatch name URL
'git config' [<file-option>] [--fixed-value] --unset name [value-pattern] 'git config' [<file-option>] --unset name [value_regex]
'git config' [<file-option>] [--fixed-value] --unset-all name [value-pattern] 'git config' [<file-option>] --unset-all name [value_regex]
'git config' [<file-option>] --rename-section old_name new_name 'git config' [<file-option>] --rename-section old_name new_name
'git config' [<file-option>] --remove-section name 'git config' [<file-option>] --remove-section name
'git config' [<file-option>] [--show-origin] [--show-scope] [-z|--null] [--name-only] -l | --list 'git config' [<file-option>] [--show-origin] [--show-scope] [-z|--null] [--name-only] -l | --list
@ -33,13 +33,10 @@ escaped.
Multiple lines can be added to an option by using the `--add` option. Multiple lines can be added to an option by using the `--add` option.
If you want to update or unset an option which can occur on multiple If you want to update or unset an option which can occur on multiple
lines, a `value-pattern` (which is an extended regular expression, lines, a POSIX regexp `value_regex` needs to be given. Only the
unless the `--fixed-value` option is given) needs to be given. Only the existing values that match the regexp are updated or unset. If
existing values that match the pattern are updated or unset. If you want to handle the lines that do *not* match the regex, just
you want to handle the lines that do *not* match the pattern, just prepend a single exclamation mark in front (see also <<EXAMPLES>>).
prepend a single exclamation mark in front (see also <<EXAMPLES>>),
but note that this only works when the `--fixed-value` option is not
in use.
The `--type=<type>` option instructs 'git config' to ensure that incoming and The `--type=<type>` option instructs 'git config' to ensure that incoming and
outgoing values are canonicalize-able under the given <type>. If no outgoing values are canonicalize-able under the given <type>. If no
@ -76,11 +73,11 @@ OPTIONS
--replace-all:: --replace-all::
Default behavior is to replace at most one line. This replaces Default behavior is to replace at most one line. This replaces
all lines matching the key (and optionally the `value-pattern`). all lines matching the key (and optionally the value_regex).
--add:: --add::
Adds a new line to the option without altering any existing Adds a new line to the option without altering any existing
values. This is the same as providing '^$' as the `value-pattern` values. This is the same as providing '^$' as the value_regex
in `--replace-all`. in `--replace-all`.
--get:: --get::
@ -168,12 +165,6 @@ See also <<FILES>>.
--list:: --list::
List all variables set in config file, along with their values. List all variables set in config file, along with their values.
--fixed-value::
When used with the `value-pattern` argument, treat `value-pattern` as
an exact string instead of a regular expression. This will restrict
the name/value pairs that are matched to only those where the value
is exactly equal to the `value-pattern`.
--type <type>:: --type <type>::
'git config' will ensure that any input or output is valid under the given 'git config' will ensure that any input or output is valid under the given
type constraint(s), and will canonicalize outgoing values in `<type>`'s type constraint(s), and will canonicalize outgoing values in `<type>`'s
@ -346,22 +337,6 @@ GIT_CONFIG_NOSYSTEM::
See also <<FILES>>. See also <<FILES>>.
GIT_CONFIG_COUNT::
GIT_CONFIG_KEY_<n>::
GIT_CONFIG_VALUE_<n>::
If GIT_CONFIG_COUNT is set to a positive number, all environment pairs
GIT_CONFIG_KEY_<n> and GIT_CONFIG_VALUE_<n> up to that number will be
added to the process's runtime configuration. The config pairs are
zero-indexed. Any missing key or value is treated as an error. An empty
GIT_CONFIG_COUNT is treated the same as GIT_CONFIG_COUNT=0, namely no
pairs are processed. These environment variables will override values
in configuration files, but will be overridden by any explicit options
passed via `git -c`.
+
This is useful for cases where you want to spawn multiple git commands
with a common configuration but cannot depend on a configuration file,
for example when writing scripts.
[[EXAMPLES]] [[EXAMPLES]]
EXAMPLES EXAMPLES

View File

@ -9,7 +9,7 @@ git-diff-index - Compare a tree to the working tree or index
SYNOPSIS SYNOPSIS
-------- --------
[verse] [verse]
'git diff-index' [-m] [--cached] [--merge-base] [<common diff options>] <tree-ish> [<path>...] 'git diff-index' [-m] [--cached] [<common diff options>] <tree-ish> [<path>...]
DESCRIPTION DESCRIPTION
----------- -----------
@ -27,12 +27,7 @@ include::diff-options.txt[]
The id of a tree object to diff against. The id of a tree object to diff against.
--cached:: --cached::
Do not consider the on-disk file at all. do not consider the on-disk file at all
--merge-base::
Instead of comparing <tree-ish> directly, use the merge base
between <tree-ish> and HEAD instead. <tree-ish> must be a
commit.
-m:: -m::
By default, files recorded in the index but not checked By default, files recorded in the index but not checked

View File

@ -10,7 +10,7 @@ SYNOPSIS
-------- --------
[verse] [verse]
'git diff-tree' [--stdin] [-m] [-s] [-v] [--no-commit-id] [--pretty] 'git diff-tree' [--stdin] [-m] [-s] [-v] [--no-commit-id] [--pretty]
[-t] [-r] [-c | --cc] [--combined-all-paths] [--root] [--merge-base] [-t] [-r] [-c | --cc] [--combined-all-paths] [--root]
[<common diff options>] <tree-ish> [<tree-ish>] [<path>...] [<common diff options>] <tree-ish> [<tree-ish>] [<path>...]
DESCRIPTION DESCRIPTION
@ -43,11 +43,6 @@ include::diff-options.txt[]
When `--root` is specified the initial commit will be shown as a big When `--root` is specified the initial commit will be shown as a big
creation event. This is equivalent to a diff against the NULL tree. creation event. This is equivalent to a diff against the NULL tree.
--merge-base::
Instead of comparing the <tree-ish>s directly, use the merge
base between the two <tree-ish>s as the "before" side. There
must be two <tree-ish>s given and they must both be commits.
--stdin:: --stdin::
When `--stdin` is specified, the command does not take When `--stdin` is specified, the command does not take
<tree-ish> arguments from the command line. Instead, it <tree-ish> arguments from the command line. Instead, it

View File

@ -10,8 +10,8 @@ SYNOPSIS
-------- --------
[verse] [verse]
'git diff' [<options>] [<commit>] [--] [<path>...] 'git diff' [<options>] [<commit>] [--] [<path>...]
'git diff' [<options>] --cached [--merge-base] [<commit>] [--] [<path>...] 'git diff' [<options>] --cached [<commit>] [--] [<path>...]
'git diff' [<options>] [--merge-base] <commit> [<commit>...] <commit> [--] [<path>...] 'git diff' [<options>] <commit> [<commit>...] <commit> [--] [<path>...]
'git diff' [<options>] <commit>...<commit> [--] [<path>...] 'git diff' [<options>] <commit>...<commit> [--] [<path>...]
'git diff' [<options>] <blob> <blob> 'git diff' [<options>] <blob> <blob>
'git diff' [<options>] --no-index [--] <path> <path> 'git diff' [<options>] --no-index [--] <path> <path>
@ -40,7 +40,7 @@ files on disk.
or when running the command outside a working tree or when running the command outside a working tree
controlled by Git. This form implies `--exit-code`. controlled by Git. This form implies `--exit-code`.
'git diff' [<options>] --cached [--merge-base] [<commit>] [--] [<path>...]:: 'git diff' [<options>] --cached [<commit>] [--] [<path>...]::
This form is to view the changes you staged for the next This form is to view the changes you staged for the next
commit relative to the named <commit>. Typically you commit relative to the named <commit>. Typically you
@ -49,10 +49,6 @@ files on disk.
If HEAD does not exist (e.g. unborn branches) and If HEAD does not exist (e.g. unborn branches) and
<commit> is not given, it shows all staged changes. <commit> is not given, it shows all staged changes.
--staged is a synonym of --cached. --staged is a synonym of --cached.
+
If --merge-base is given, instead of using <commit>, use the merge base
of <commit> and HEAD. `git diff --merge-base A` is equivalent to
`git diff $(git merge-base A HEAD)`.
'git diff' [<options>] <commit> [--] [<path>...]:: 'git diff' [<options>] <commit> [--] [<path>...]::
@ -62,27 +58,23 @@ of <commit> and HEAD. `git diff --merge-base A` is equivalent to
branch name to compare with the tip of a different branch name to compare with the tip of a different
branch. branch.
'git diff' [<options>] [--merge-base] <commit> <commit> [--] [<path>...]:: 'git diff' [<options>] <commit> <commit> [--] [<path>...]::
This is to view the changes between two arbitrary This is to view the changes between two arbitrary
<commit>. <commit>.
+
If --merge-base is given, use the merge base of the two commits for the
"before" side. `git diff --merge-base A B` is equivalent to
`git diff $(git merge-base A B) B`.
'git diff' [<options>] <commit> <commit>... <commit> [--] [<path>...]:: 'git diff' [<options>] <commit> <commit>... <commit> [--] [<path>...]::
This form is to view the results of a merge commit. The first This form is to view the results of a merge commit. The first
listed <commit> must be the merge itself; the remaining two or listed <commit> must be the merge itself; the remaining two or
more commits should be its parents. A convenient way to produce more commits should be its parents. A convenient way to produce
the desired set of revisions is to use the `^@` suffix. the desired set of revisions is to use the {caret}@ suffix.
For instance, if `master` names a merge commit, `git diff master For instance, if `master` names a merge commit, `git diff master
master^@` gives the same combined diff as `git show master`. master^@` gives the same combined diff as `git show master`.
'git diff' [<options>] <commit>..<commit> [--] [<path>...]:: 'git diff' [<options>] <commit>..<commit> [--] [<path>...]::
This is synonymous to the earlier form (without the `..`) for This is synonymous to the earlier form (without the "..") for
viewing the changes between two arbitrary <commit>. If <commit> on viewing the changes between two arbitrary <commit>. If <commit> on
one side is omitted, it will have the same effect as one side is omitted, it will have the same effect as
using HEAD instead. using HEAD instead.
@ -91,20 +83,20 @@ If --merge-base is given, use the merge base of the two commits for the
This form is to view the changes on the branch containing This form is to view the changes on the branch containing
and up to the second <commit>, starting at a common ancestor and up to the second <commit>, starting at a common ancestor
of both <commit>. `git diff A...B` is equivalent to of both <commit>. "git diff A\...B" is equivalent to
`git diff $(git merge-base A B) B`. You can omit any one "git diff $(git merge-base A B) B". You can omit any one
of <commit>, which has the same effect as using HEAD instead. of <commit>, which has the same effect as using HEAD instead.
Just in case you are doing something exotic, it should be Just in case you are doing something exotic, it should be
noted that all of the <commit> in the above description, except noted that all of the <commit> in the above description, except
in the `--merge-base` case and in the last two forms that use `..` in the last two forms that use ".." notations, can be any
notations, can be any <tree>. <tree>.
For a more complete list of ways to spell <commit>, see For a more complete list of ways to spell <commit>, see
"SPECIFYING REVISIONS" section in linkgit:gitrevisions[7]. "SPECIFYING REVISIONS" section in linkgit:gitrevisions[7].
However, "diff" is about comparing two _endpoints_, not ranges, However, "diff" is about comparing two _endpoints_, not ranges,
and the range notations (`<commit>..<commit>` and and the range notations ("<commit>..<commit>" and
`<commit>...<commit>`) do not mean a range as defined in the "<commit>\...<commit>") do not mean a range as defined in the
"SPECIFYING RANGES" section in linkgit:gitrevisions[7]. "SPECIFYING RANGES" section in linkgit:gitrevisions[7].
'git diff' [<options>] <blob> <blob>:: 'git diff' [<options>] <blob> <blob>::
@ -152,9 +144,9 @@ $ git diff HEAD <3>
+ +
<1> Changes in the working tree not yet staged for the next commit. <1> Changes in the working tree not yet staged for the next commit.
<2> Changes between the index and your last commit; what you <2> Changes between the index and your last commit; what you
would be committing if you run `git commit` without `-a` option. would be committing if you run "git commit" without "-a" option.
<3> Changes in the working tree since your last commit; what you <3> Changes in the working tree since your last commit; what you
would be committing if you run `git commit -a` would be committing if you run "git commit -a"
Comparing with arbitrary commits:: Comparing with arbitrary commits::
+ +

View File

@ -34,14 +34,6 @@ OPTIONS
This is the default behaviour; the option is provided to This is the default behaviour; the option is provided to
override any configuration settings. override any configuration settings.
--rotate-to=<file>::
Start showing the diff for the given path,
the paths before it will move to end and output.
--skip-to=<file>::
Start showing the diff for the given path, skipping all
the paths before it.
-t <tool>:: -t <tool>::
--tool=<tool>:: --tool=<tool>::
Use the diff tool specified by <tool>. Valid values include Use the diff tool specified by <tool>. Valid values include

View File

@ -814,7 +814,7 @@ may have uses for this information
'original-oid' SP <object-identifier> LF 'original-oid' SP <object-identifier> LF
.... ....
where `<object-identifier>` is any string not containing LF. where `<object-identifer>` is any string not containing LF.
`tag` `tag`
~~~~~ ~~~~~

View File

@ -48,10 +48,6 @@ include::fetch-options.txt[]
include::pull-fetch-param.txt[] include::pull-fetch-param.txt[]
--stdin::
Read refspecs, one per line, from stdin in addition to those provided
as arguments. The "tag <name>" format is not supported.
include::urls-remotes.txt[] include::urls-remotes.txt[]

View File

@ -532,7 +532,7 @@ The https://github.com/newren/git-filter-repo/[git filter-repo] tool is
an alternative to git-filter-branch which does not suffer from these an alternative to git-filter-branch which does not suffer from these
performance problems or the safety problems (mentioned below). For those performance problems or the safety problems (mentioned below). For those
with existing tooling which relies upon git-filter-branch, 'git with existing tooling which relies upon git-filter-branch, 'git
filter-repo' also provides repo-filter' also provides
https://github.com/newren/git-filter-repo/blob/master/contrib/filter-repo-demos/filter-lamely[filter-lamely], https://github.com/newren/git-filter-repo/blob/master/contrib/filter-repo-demos/filter-lamely[filter-lamely],
a drop-in git-filter-branch replacement (with a few caveats). While a drop-in git-filter-branch replacement (with a few caveats). While
filter-lamely suffers from all the same safety issues as filter-lamely suffers from all the same safety issues as

View File

@ -11,7 +11,7 @@ SYNOPSIS
'git for-each-ref' [--count=<count>] [--shell|--perl|--python|--tcl] 'git for-each-ref' [--count=<count>] [--shell|--perl|--python|--tcl]
[(--sort=<key>)...] [--format=<format>] [<pattern>...] [(--sort=<key>)...] [--format=<format>] [<pattern>...]
[--points-at=<object>] [--points-at=<object>]
[--merged[=<object>]] [--no-merged[=<object>]] (--merged[=<object>] | --no-merged[=<object>])
[--contains[=<object>]] [--no-contains[=<object>]] [--contains[=<object>]] [--no-contains[=<object>]]
DESCRIPTION DESCRIPTION
@ -76,11 +76,13 @@ OPTIONS
--merged[=<object>]:: --merged[=<object>]::
Only list refs whose tips are reachable from the Only list refs whose tips are reachable from the
specified commit (HEAD if not specified). specified commit (HEAD if not specified),
incompatible with `--no-merged`.
--no-merged[=<object>]:: --no-merged[=<object>]::
Only list refs whose tips are not reachable from the Only list refs whose tips are not reachable from the
specified commit (HEAD if not specified). specified commit (HEAD if not specified),
incompatible with `--merged`.
--contains[=<object>]:: --contains[=<object>]::
Only list refs which contain the specified commit (HEAD if not Only list refs which contain the specified commit (HEAD if not
@ -220,8 +222,6 @@ worktreepath::
In addition to the above, for commit and tag objects, the header In addition to the above, for commit and tag objects, the header
field names (`tree`, `parent`, `object`, `type`, and `tag`) can field names (`tree`, `parent`, `object`, `type`, and `tag`) can
be used to specify the value in the header field. be used to specify the value in the header field.
Fields `tree` and `parent` can also be used with modifier `:short` and
`:short=<length>` just like `objectname`.
For commit and tag objects, the special `creatordate` and `creator` For commit and tag objects, the special `creatordate` and `creator`
fields will correspond to the appropriate date or name-email-date tuple fields will correspond to the appropriate date or name-email-date tuple
@ -230,39 +230,20 @@ These are intended for working on a mix of annotated and lightweight tags.
Fields that have name-email-date tuple as its value (`author`, Fields that have name-email-date tuple as its value (`author`,
`committer`, and `tagger`) can be suffixed with `name`, `email`, `committer`, and `tagger`) can be suffixed with `name`, `email`,
and `date` to extract the named component. For email fields (`authoremail`, and `date` to extract the named component.
`committeremail` and `taggeremail`), `:trim` can be appended to get the email
without angle brackets, and `:localpart` to get the part before the `@` symbol
out of the trimmed email.
The message in a commit or a tag object is `contents`, from which
`contents:<part>` can be used to extract various parts out of:
contents:size::
The size in bytes of the commit or tag message.
contents:subject::
The first paragraph of the message, which typically is a
single line, is taken as the "subject" of the commit or the
tag message.
Instead of `contents:subject`, field `subject` can also be used to
obtain same results. `:sanitize` can be appended to `subject` for
subject line suitable for filename.
contents:body::
The remainder of the commit or the tag message that follows
the "subject".
contents:signature::
The optional GPG signature of the tag.
contents:lines=N::
The first `N` lines of the message.
The complete message in a commit and tag object is `contents`.
Its first line is `contents:subject`, where subject is the concatenation
of all lines of the commit message up to the first blank line. The next
line is `contents:body`, where body is all of the lines after the first
blank line. The optional GPG signature is `contents:signature`. The
first `N` lines of the message is obtained using `contents:lines=N`.
Additionally, the trailers as interpreted by linkgit:git-interpret-trailers[1] Additionally, the trailers as interpreted by linkgit:git-interpret-trailers[1]
are obtained as `trailers[:options]` (or by using the historical alias are obtained as `trailers` (or by using the historical alias
`contents:trailers[:options]`). For valid [:option] values see `trailers` `contents:trailers`). Non-trailer lines from the trailer block can be omitted
section of linkgit:git-log[1]. with `trailers:only`. Whitespace-continuations can be removed from trailers so
that each trailer appears on a line by itself with its full content with
`trailers:unfold`. Both can be used together as `trailers:unfold,only`.
For sorting purposes, fields with numeric values sort in numeric order For sorting purposes, fields with numeric values sort in numeric order
(`objectsize`, `authordate`, `committerdate`, `creatordate`, `taggerdate`). (`objectsize`, `authordate`, `committerdate`, `creatordate`, `taggerdate`).
@ -404,11 +385,6 @@ Note also that multiple copies of an object may be present in the object
database; in this case, it is undefined which copy's size or delta base database; in this case, it is undefined which copy's size or delta base
will be reported. will be reported.
NOTES
-----
include::ref-reachability-filters.txt[]
SEE ALSO SEE ALSO
-------- --------
linkgit:git-show-ref[1] linkgit:git-show-ref[1]

View File

@ -1,59 +0,0 @@
git-for-each-repo(1)
====================
NAME
----
git-for-each-repo - Run a Git command on a list of repositories
SYNOPSIS
--------
[verse]
'git for-each-repo' --config=<config> [--] <arguments>
DESCRIPTION
-----------
Run a Git command on a list of repositories. The arguments after the
known options or `--` indicator are used as the arguments for the Git
subprocess.
THIS COMMAND IS EXPERIMENTAL. THE BEHAVIOR MAY CHANGE.
For example, we could run maintenance on each of a list of repositories
stored in a `maintenance.repo` config variable using
-------------
git for-each-repo --config=maintenance.repo maintenance run
-------------
This will run `git -C <repo> maintenance run` for each value `<repo>`
in the multi-valued config variable `maintenance.repo`.
OPTIONS
-------
--config=<config>::
Use the given config variable as a multi-valued list storing
absolute path names. Iterate on that list of paths to run
the given arguments.
+
These config values are loaded from system, global, and local Git config,
as available. If `git for-each-repo` is run in a directory that is not a
Git repository, then only the system and global config is used.
SUBPROCESS BEHAVIOR
-------------------
If any `git -C <repo> <arguments>` subprocess returns a non-zero exit code,
then the `git for-each-repo` process returns that exit code without running
more subprocesses.
Each `git -C <repo> <arguments>` subprocess inherits the standard file
descriptors `stdin`, `stdout`, and `stderr`.
GIT
---
Part of the linkgit:git[1] suite

View File

@ -28,7 +28,6 @@ SYNOPSIS
[--no-notes | --notes[=<ref>]] [--no-notes | --notes[=<ref>]]
[--interdiff=<previous>] [--interdiff=<previous>]
[--range-diff=<previous> [--creation-factor=<percent>]] [--range-diff=<previous> [--creation-factor=<percent>]]
[--filename-max-length=<n>]
[--progress] [--progress]
[<common diff options>] [<common diff options>]
[ <since> | <revision range> ] [ <since> | <revision range> ]
@ -120,7 +119,7 @@ include::diff-options.txt[]
-s:: -s::
--signoff:: --signoff::
Add a `Signed-off-by` trailer to the commit message, using Add `Signed-off-by:` line to the commit message, using
the committer identity of yourself. the committer identity of yourself.
See the signoff option in linkgit:git-commit[1] for more information. See the signoff option in linkgit:git-commit[1] for more information.
@ -201,13 +200,6 @@ populated with placeholder text.
allows for useful naming of a patch series, and can be allows for useful naming of a patch series, and can be
combined with the `--numbered` option. combined with the `--numbered` option.
--filename-max-length=<n>::
Instead of the standard 64 bytes, chomp the generated output
filenames at around '<n>' bytes (too short a value will be
silently raised to a reasonable length). Defaults to the
value of the `format.filenameMaxLength` configuration
variable, or 64 if unconfigured.
--rfc:: --rfc::
Alias for `--subject-prefix="RFC PATCH"`. RFC means "Request For Alias for `--subject-prefix="RFC PATCH"`. RFC means "Request For
Comments"; use this when sending an experimental patch for Comments"; use this when sending an experimental patch for

View File

@ -129,6 +129,14 @@ using 'git commit-graph verify'. See linkgit:git-commit-graph[1].
Extracted Diagnostics Extracted Diagnostics
--------------------- ---------------------
expect dangling commits - potential heads - due to lack of head information::
You haven't specified any nodes as heads so it won't be
possible to differentiate between un-parented commits and
root nodes.
missing sha1 directory '<dir>'::
The directory holding the sha1 objects is missing.
unreachable <type> <object>:: unreachable <type> <object>::
The <type> object <object>, isn't actually referred to directly The <type> object <object>, isn't actually referred to directly
or indirectly in any of the trees or commits seen. This can or indirectly in any of the trees or commits seen. This can

View File

@ -117,14 +117,12 @@ NOTES
'git gc' tries very hard not to delete objects that are referenced 'git gc' tries very hard not to delete objects that are referenced
anywhere in your repository. In particular, it will keep not only anywhere in your repository. In particular, it will keep not only
objects referenced by your current set of branches and tags, but also objects referenced by your current set of branches and tags, but also
objects referenced by the index, remote-tracking branches, reflogs objects referenced by the index, remote-tracking branches, notes saved
(which may reference commits in branches that were later amended or by 'git notes' under refs/notes/, reflogs (which may reference commits
rewound), and anything else in the refs/* namespace. Note that a note in branches that were later amended or rewound), and anything else in
(of the kind created by 'git notes') attached to an object does not the refs/* namespace. If you are expecting some objects to be deleted
contribute in keeping the object alive. If you are expecting some and they aren't, check all of those locations and decide whether it
objects to be deleted and they aren't, check all of those locations makes sense in your case to remove those references.
and decide whether it makes sense in your case to remove those
references.
On the other hand, when 'git gc' runs concurrently with another process, On the other hand, when 'git gc' runs concurrently with another process,
there is a risk of it deleting an object that the other process is using there is a risk of it deleting an object that the other process is using

View File

@ -209,7 +209,7 @@ providing this option will cause it to die.
Use \0 as the delimiter for pathnames in the output, and print Use \0 as the delimiter for pathnames in the output, and print
them verbatim. Without this option, pathnames with "unusual" them verbatim. Without this option, pathnames with "unusual"
characters are quoted as explained for the configuration characters are quoted as explained for the configuration
variable core.quotePath (see linkgit:git-config[1]). variable core.quotePath (see git-config(1)).
-o:: -o::
--only-matching:: --only-matching::
@ -241,7 +241,7 @@ providing this option will cause it to die.
--show-function:: --show-function::
Show the preceding line that contains the function name of Show the preceding line that contains the function name of
the match, unless the matching line is a function name itself. the match, unless the matching line is a function name itself.
The name is determined in the same way as `git diff` works out The name is determined in the same way as 'git diff' works out
patch hunk headers (see 'Defining a custom hunk-header' in patch hunk headers (see 'Defining a custom hunk-header' in
linkgit:gitattributes[5]). linkgit:gitattributes[5]).
@ -266,9 +266,7 @@ providing this option will cause it to die.
Show the surrounding text from the previous line containing a Show the surrounding text from the previous line containing a
function name up to the one before the next function name, function name up to the one before the next function name,
effectively showing the whole function in which the match was effectively showing the whole function in which the match was
found. The function names are determined in the same way as found.
`git diff` works out patch hunk headers (see 'Defining a
custom hunk-header' in linkgit:gitattributes[5]).
--threads <num>:: --threads <num>::
Number of grep worker threads to use. Number of grep worker threads to use.

View File

@ -8,7 +8,7 @@ git-help - Display help information about Git
SYNOPSIS SYNOPSIS
-------- --------
[verse] [verse]
'git help' [-a|--all [--[no-]verbose]] [-g|--guides] 'git help' [-a|--all [--[no-]verbose]] [-g|--guide]
[-i|--info|-m|--man|-w|--web] [COMMAND|GUIDE] [-i|--info|-m|--man|-w|--web] [COMMAND|GUIDE]
DESCRIPTION DESCRIPTION
@ -21,8 +21,8 @@ on the standard output.
If the option `--all` or `-a` is given, all available commands are If the option `--all` or `-a` is given, all available commands are
printed on the standard output. printed on the standard output.
If the option `--guides` or `-g` is given, a list of the If the option `--guide` or `-g` is given, a list of the useful
Git concept guides is also printed on the standard output. Git guides is also printed on the standard output.
If a command, or a guide, is given, a manual page for that command or If a command, or a guide, is given, a manual page for that command or
guide is brought up. The 'man' program is used by default for this guide is brought up. The 'man' program is used by default for this
@ -58,7 +58,7 @@ OPTIONS
-g:: -g::
--guides:: --guides::
Prints a list of the Git concept guides on the standard output. This Prints a list of useful guides on the standard output. This
option overrides any given command or guide name. option overrides any given command or guide name.
-i:: -i::

View File

@ -41,17 +41,11 @@ commit-id::
<commit-id>['\t'<filename-as-in--w>] <commit-id>['\t'<filename-as-in--w>]
--packfile=<hash>:: --packfile=<hash>::
For internal use only. Instead of a commit id on the command Instead of a commit id on the command line (which is not expected in
line (which is not expected in
this case), 'git http-fetch' fetches the packfile directly at the given this case), 'git http-fetch' fetches the packfile directly at the given
URL and uses index-pack to generate corresponding .idx and .keep files. URL and uses index-pack to generate corresponding .idx and .keep files.
The hash is used to determine the name of the temporary file and is The hash is used to determine the name of the temporary file and is
arbitrary. The output of index-pack is printed to stdout. Requires arbitrary. The output of index-pack is printed to stdout.
--index-pack-args.
--index-pack-args=<args>::
For internal use only. The command to run on the contents of the
downloaded pack. Arguments are URL-encoded separated by spaces.
--recover:: --recover::
Verify that everything reachable from target is fetched. Used after Verify that everything reachable from target is fetched. Used after

View File

@ -51,13 +51,17 @@ OPTIONS
CONFIGURATION CONFIGURATION
------------- -------------
To use the tool, `imap.folder` and either `imap.tunnel` or `imap.host` must be set To use the tool, imap.folder and either imap.tunnel or imap.host must be set
to appropriate values. to appropriate values.
Variables
~~~~~~~~~
include::config/imap.txt[] include::config/imap.txt[]
EXAMPLES Examples
-------- ~~~~~~~~
Using tunnel mode: Using tunnel mode:
.......................... ..........................
@ -85,18 +89,14 @@ Using direct mode with SSL:
user = bob user = bob
pass = p4ssw0rd pass = p4ssw0rd
port = 123 port = 123
; sslVerify = false sslverify = false
......................... .........................
[NOTE] EXAMPLES
You may want to use `sslVerify=false` --------
while troubleshooting, if you suspect that the reason you are To submit patches using GMail's IMAP interface, first, edit your ~/.gitconfig
having trouble connecting is because the certificate you use at to specify your account settings:
the private server `example.com` you are trying to set up (or
have set up) may not be verified correctly.
Using Gmail's IMAP interface:
--------- ---------
[imap] [imap]
@ -104,21 +104,17 @@ Using Gmail's IMAP interface:
host = imaps://imap.gmail.com host = imaps://imap.gmail.com
user = user@gmail.com user = user@gmail.com
port = 993 port = 993
sslverify = false
--------- ---------
[NOTE] You might need to instead use: folder = "[Google Mail]/Drafts" if you get an error
You might need to instead use: `folder = "[Google Mail]/Drafts"` if you get an error
that the "Folder doesn't exist". that the "Folder doesn't exist".
[NOTE]
If your Gmail account is set to another language than English, the name of the "Drafts"
folder will be localized.
Once the commits are ready to be sent, run the following command: Once the commits are ready to be sent, run the following command:
$ git format-patch --cover-letter -M --stdout origin/master | git imap-send $ git format-patch --cover-letter -M --stdout origin/master | git imap-send
Just make sure to disable line wrapping in the email client (Gmail's web Just make sure to disable line wrapping in the email client (GMail's web
interface will wrap lines no matter what, so you need to use a real interface will wrap lines no matter what, so you need to use a real
IMAP client). IMAP client).

View File

@ -9,18 +9,17 @@ git-index-pack - Build pack index file for an existing packed archive
SYNOPSIS SYNOPSIS
-------- --------
[verse] [verse]
'git index-pack' [-v] [-o <index-file>] [--[no-]rev-index] <pack-file> 'git index-pack' [-v] [-o <index-file>] <pack-file>
'git index-pack' --stdin [--fix-thin] [--keep] [-v] [-o <index-file>] 'git index-pack' --stdin [--fix-thin] [--keep] [-v] [-o <index-file>]
[--[no-]rev-index] [<pack-file>] [<pack-file>]
DESCRIPTION DESCRIPTION
----------- -----------
Reads a packed archive (.pack) from the specified file, and Reads a packed archive (.pack) from the specified file, and
builds a pack index file (.idx) for it. Optionally writes a builds a pack index file (.idx) for it. The packed archive
reverse-index (.rev) for the specified pack. The packed together with the pack index can then be placed in the
archive together with the pack index can then be placed in objects/pack/ directory of a Git repository.
the objects/pack/ directory of a Git repository.
OPTIONS OPTIONS
@ -36,13 +35,6 @@ OPTIONS
fails if the name of packed archive does not end fails if the name of packed archive does not end
with .pack). with .pack).
--[no-]rev-index::
When this flag is provided, generate a reverse index
(a `.rev` file) corresponding to the given pack. If
`--verify` is given, ensure that the existing
reverse index is correct. Takes precedence over
`pack.writeReverseIndex`.
--stdin:: --stdin::
When this flag is provided, the pack is read from stdin When this flag is provided, the pack is read from stdin
instead and a copy is then written to <pack-file>. If instead and a copy is then written to <pack-file>. If
@ -86,12 +78,7 @@ OPTIONS
Die if the pack contains broken links. For internal use only. Die if the pack contains broken links. For internal use only.
--fsck-objects:: --fsck-objects::
For internal use only. Die if the pack contains broken objects. For internal use only.
+
Die if the pack contains broken objects. If the pack contains a tree
pointing to a .gitmodules blob that does not exist, prints the hash of
that blob (for the caller to check) after the hash that goes into the
name of the pack/idx file (see "Notes").
--threads=<n>:: --threads=<n>::
Specifies the number of threads to spawn when resolving Specifies the number of threads to spawn when resolving
@ -113,14 +100,12 @@ name of the pack/idx file (see "Notes").
value is set or outside a repository. value is set or outside a repository.
+ +
This option cannot be used with --stdin. This option cannot be used with --stdin.
+
include::object-format-disclaimer.txt[]
NOTES NOTES
----- -----
Once the index has been created, the hash that goes into the name of Once the index has been created, the list of object names is sorted
the pack/idx file is printed to stdout. If --stdin was and the SHA-1 hash of that list is printed to stdout. If --stdin was
also used then this is prefixed by either "pack\t", or "keep\t" if a also used then this is prefixed by either "pack\t", or "keep\t" if a
new .keep file was successfully created. This is useful to remove a new .keep file was successfully created. This is useful to remove a
.keep file used as a lock to prevent the race with 'git repack' .keep file used as a lock to prevent the race with 'git repack'

View File

@ -20,9 +20,8 @@ DESCRIPTION
This command creates an empty Git repository - basically a `.git` This command creates an empty Git repository - basically a `.git`
directory with subdirectories for `objects`, `refs/heads`, directory with subdirectories for `objects`, `refs/heads`,
`refs/tags`, and template files. An initial branch without any `refs/tags`, and template files. An initial `HEAD` file that
commits will be created (see the `--initial-branch` option below references the HEAD of the master branch is also created.
for its name).
If the `$GIT_DIR` environment variable is set then it specifies a path If the `$GIT_DIR` environment variable is set then it specifies a path
to use instead of `./.git` for the base of the repository. to use instead of `./.git` for the base of the repository.
@ -54,8 +53,6 @@ current working directory.
Specify the given object format (hash algorithm) for the repository. The valid Specify the given object format (hash algorithm) for the repository. The valid
values are 'sha1' and (if enabled) 'sha256'. 'sha1' is the default. values are 'sha1' and (if enabled) 'sha256'. 'sha1' is the default.
+
include::object-format-disclaimer.txt[]
--template=<template_directory>:: --template=<template_directory>::
@ -71,13 +68,11 @@ repository.
+ +
If this is reinitialization, the repository will be moved to the specified path. If this is reinitialization, the repository will be moved to the specified path.
-b <branch-name>:: -b <branch-name::
--initial-branch=<branch-name>:: --initial-branch=<branch-name>::
Use the specified name for the initial branch in the newly created Use the specified name for the initial branch in the newly created repository.
repository. If not specified, fall back to the default name (currently If not specified, fall back to the default name: `master`.
`master`, but this is subject to change in the future; the name can be
customized via the `init.defaultBranch` configuration variable).
--shared[=(false|true|umask|group|all|world|everybody|0xxx)]:: --shared[=(false|true|umask|group|all|world|everybody|0xxx)]::

View File

@ -15,12 +15,9 @@ DESCRIPTION
----------- -----------
Shows the commit logs. Shows the commit logs.
:git-log: 1 The command takes options applicable to the `git rev-list`
include::rev-list-description.txt[]
The command takes options applicable to the linkgit:git-rev-list[1]
command to control what is shown and how, and options applicable to command to control what is shown and how, and options applicable to
the linkgit:git-diff[1] command to control how the changes the `git diff-*` commands to control how the changes
each commit introduces are shown. each commit introduces are shown.
@ -77,7 +74,20 @@ produced by `--stat`, etc.
Intended to speed up tools that read log messages from `git log` Intended to speed up tools that read log messages from `git log`
output by allowing them to allocate space in advance. output by allowing them to allocate space in advance.
include::line-range-options.txt[] -L <start>,<end>:<file>::
-L :<funcname>:<file>::
Trace the evolution of the line range given by "<start>,<end>"
(or the function name regex <funcname>) within the <file>. You may
not give any pathspec limiters. This is currently limited to
a walk starting from a single revision, i.e., you may only
give zero or one positive revision arguments, and
<start> and <end> (or <funcname>) must exist in the starting revision.
You can specify this option more than once. Implies `--patch`.
Patch output can be suppressed using `--no-patch`, but other diff formats
(namely `--raw`, `--numstat`, `--shortstat`, `--dirstat`, `--summary`,
`--name-only`, `--name-status`, `--check`) are not currently implemented.
+
include::line-range-format.txt[]
<revision range>:: <revision range>::
Show only commits in the specified revision range. When no Show only commits in the specified revision range. When no
@ -101,21 +111,10 @@ include::rev-list-options.txt[]
include::pretty-formats.txt[] include::pretty-formats.txt[]
DIFF FORMATTING COMMON DIFF OPTIONS
--------------- -------------------
By default, `git log` does not generate any diff output. The options
below can be used to show the changes made by each commit.
Note that unless one of `--diff-merges` variants (including short
`-m`, `-c`, and `--cc` options) is explicitly given, merge commits
will not show a diff, even if a diff format like `--patch` is
selected, nor will they match search options like `-S`. The exception
is when `--first-parent` is in use, in which case `first-parent` is
the default format.
:git-log: 1 :git-log: 1
:diff-merges-default: `off`
include::diff-options.txt[] include::diff-options.txt[]
include::diff-generate-patch.txt[] include::diff-generate-patch.txt[]

View File

@ -13,19 +13,19 @@ SYNOPSIS
(--[cached|deleted|others|ignored|stage|unmerged|killed|modified])* (--[cached|deleted|others|ignored|stage|unmerged|killed|modified])*
(-[c|d|o|i|s|u|k|m])* (-[c|d|o|i|s|u|k|m])*
[--eol] [--eol]
[--deduplicate]
[-x <pattern>|--exclude=<pattern>] [-x <pattern>|--exclude=<pattern>]
[-X <file>|--exclude-from=<file>] [-X <file>|--exclude-from=<file>]
[--exclude-per-directory=<file>] [--exclude-per-directory=<file>]
[--exclude-standard] [--exclude-standard]
[--error-unmatch] [--with-tree=<tree-ish>] [--error-unmatch] [--with-tree=<tree-ish>]
[--full-name] [--recurse-submodules] [--full-name] [--recurse-submodules]
[--abbrev[=<n>]] [--] [<file>...] [--abbrev] [--] [<file>...]
DESCRIPTION DESCRIPTION
----------- -----------
This merges the file listing in the index with the actual working This merges the file listing in the directory cache index with the
directory list, and shows different combinations of the two. actual working directory list, and shows different combinations of the
two.
One or more of the options below may be used to determine the files One or more of the options below may be used to determine the files
shown: shown:
@ -81,13 +81,6 @@ OPTIONS
\0 line termination on output and do not quote filenames. \0 line termination on output and do not quote filenames.
See OUTPUT below for more information. See OUTPUT below for more information.
--deduplicate::
When only filenames are shown, suppress duplicates that may
come from having multiple stages during a merge, or giving
`--deleted` and `--modified` option at the same time.
When any of the `-t`, `--unmerged`, or `--stage` option is
in use, this option has no effect.
-x <pattern>:: -x <pattern>::
--exclude=<pattern>:: --exclude=<pattern>::
Skip untracked files matching pattern. Skip untracked files matching pattern.
@ -160,8 +153,7 @@ a space) at the start of each line:
--abbrev[=<n>]:: --abbrev[=<n>]::
Instead of showing the full 40-byte hexadecimal object Instead of showing the full 40-byte hexadecimal object
lines, show the shortest prefix that is at least '<n>' lines, show only a partial prefix.
hexdigits long that uniquely refers the object.
Non default number of digits can be specified with --abbrev=<n>. Non default number of digits can be specified with --abbrev=<n>.
--debug:: --debug::

View File

@ -62,8 +62,7 @@ OPTIONS
--abbrev[=<n>]:: --abbrev[=<n>]::
Instead of showing the full 40-byte hexadecimal object Instead of showing the full 40-byte hexadecimal object
lines, show the shortest prefix that is at least '<n>' lines, show only a partial prefix.
hexdigits long that uniquely refers the object.
Non default number of digits can be specified with --abbrev=<n>. Non default number of digits can be specified with --abbrev=<n>.
--full-name:: --full-name::

View File

@ -53,7 +53,7 @@ character.
The commit log message, author name and author email are The commit log message, author name and author email are
taken from the e-mail, and after minimally decoding MIME taken from the e-mail, and after minimally decoding MIME
transfer encoding, re-coded in the charset specified by transfer encoding, re-coded in the charset specified by
`i18n.commitEncoding` (defaulting to UTF-8) by transliterating i18n.commitencoding (defaulting to UTF-8) by transliterating
them. This used to be optional but now it is the default. them. This used to be optional but now it is the default.
+ +
Note that the patch is always used as-is without charset Note that the patch is always used as-is without charset
@ -61,7 +61,7 @@ conversion, even with this flag.
--encoding=<encoding>:: --encoding=<encoding>::
Similar to -u. But when re-coding, the charset specified here is Similar to -u. But when re-coding, the charset specified here is
used instead of the one specified by `i18n.commitEncoding` or UTF-8. used instead of the one specified by i18n.commitencoding or UTF-8.
-n:: -n::
Disable all charset re-coding of the metadata. Disable all charset re-coding of the metadata.
@ -72,9 +72,10 @@ conversion, even with this flag.
is useful in order to associate commits with mailing list discussions. is useful in order to associate commits with mailing list discussions.
--scissors:: --scissors::
Remove everything in body before a scissors line (e.g. "-- >8 --"). Remove everything in body before a scissors line. A line that
The line represents scissors and perforation marks, and is used to mainly consists of scissors (either ">8" or "8<") and perforation
request the reader to cut the message at that line. If that line (dash "-") marks is called a scissors line, and is used to request
the reader to cut the message at that line. If such a line
appears in the body of the message before the patch, everything appears in the body of the message before the patch, everything
before it (including the scissors line itself) is ignored when before it (including the scissors line itself) is ignored when
this option is used. this option is used.

Some files were not shown because too many files have changed in this diff Show More