1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-05-25 17:06:28 +02:00
Git Source Code Mirror. Please follow Documentation/SubmittingPatches procedure for any of your improvements.
Go to file
Ævar Arnfjörð Bjarmason 956d2e4639 tests: add a test mode for SANITIZE=leak, run it in CI
While git can be compiled with SANITIZE=leak, we have not run
regression tests under that mode. Memory leaks have only been fixed as
one-offs without structured regression testing.

This change adds CI testing for it. We'll now build and small set of
whitelisted t00*.sh tests under Linux with a new job called
"linux-leaks".

The CI target uses a new GIT_TEST_PASSING_SANITIZE_LEAK=true test
mode. When running in that mode, we'll assert that we were compiled
with SANITIZE=leak. We'll then skip all tests, except those that we've
opted-in by setting "TEST_PASSES_SANITIZE_LEAK=true".

A test setting "TEST_PASSES_SANITIZE_LEAK=true" setting can in turn
make use of the "SANITIZE_LEAK" prerequisite, should they wish to
selectively skip tests even under
"GIT_TEST_PASSING_SANITIZE_LEAK=true". In the preceding commit we
started doing this in "t0004-unwritable.sh" under SANITIZE=leak, now
it'll combine nicely with "GIT_TEST_PASSING_SANITIZE_LEAK=true".

This is how tests that don't set "TEST_PASSES_SANITIZE_LEAK=true" will
be skipped under GIT_TEST_PASSING_SANITIZE_LEAK=true:

    $ GIT_TEST_PASSING_SANITIZE_LEAK=true ./t0001-init.sh
    1..0 # SKIP skip all tests in t0001 under SANITIZE=leak, TEST_PASSES_SANITIZE_LEAK not set

The intent is to add more TEST_PASSES_SANITIZE_LEAK=true annotations
as follow-up change, but let's start small to begin with.

In ci/run-build-and-tests.sh we make use of the default "*" case to
run "make test" without any GIT_TEST_* modes. SANITIZE=leak is known
to fail in combination with GIT_TEST_SPLIT_INDEX=true in
t0016-oidmap.sh, and we're likely to have other such failures in
various GIT_TEST_* modes. Let's focus on getting the base tests
passing, we can expand coverage to GIT_TEST_* modes later.

It would also be possible to implement a more lightweight version of
this by only relying on setting "LSAN_OPTIONS". See
<YS9OT/pn5rRK9cGB@coredump.intra.peff.net>[1] and
<YS9ZIDpANfsh7N+S@coredump.intra.peff.net>[2] for a discussion of
that. I've opted for this approach of adding a GIT_TEST_* mode instead
because it's consistent with how we handle other special test modes.

Being able to add a "!SANITIZE_LEAK" prerequisite and calling
"test_done" early if it isn't satisfied also means that we can more
incrementally add regression tests without being forced to fix
widespread and hard-to-fix leaks at the same time.

We have tests that do simple checking of some tool we're interested
in, but later on in the script might be stressing trace2, or common
sources of leaks like "git log" in combination with the tool (e.g. the
commit-graph tests). To be clear having a prerequisite could also be
accomplished by using "LSAN_OPTIONS" directly.

On the topic of "LSAN_OPTIONS": It would be nice to have a mode to
aggregate all failures in our various scripts, see [2] for a start at
doing that which sets "log_path" in "LSAN_OPTIONS". I've punted on
that for now, it can be added later.

As of writing this we've got major regressions between master..seen,
i.e. the t000*.sh tests and more fixed since 31f9acf9ce (Merge branch
'ah/plugleaks', 2021-08-04) have regressed recently.

See the discussion at <87czsv2idy.fsf@evledraar.gmail.com>[3] about
the lack of this sort of test mode, and 0e5bba53af (add UNLEAK
annotation for reducing leak false positives, 2017-09-08) for the
initial addition of SANITIZE=leak.

See also 09595ab381 (Merge branch 'jk/leak-checkers', 2017-09-19),
7782066f67 (Merge branch 'jk/apache-lsan', 2019-05-19) and the recent
936e58851a (Merge branch 'ah/plugleaks', 2021-05-07) for some of the
past history of "one-off" SANITIZE=leak (and more) fixes.

As noted in [5] we can't support this on OSX yet until Clang 14 is
released, at that point we'll probably want to resurrect that
"osx-leaks" job.

1. https://github.com/google/sanitizers/wiki/AddressSanitizerLeakSanitizer
2. https://lore.kernel.org/git/YS9OT%2Fpn5rRK9cGB@coredump.intra.peff.net/
3. https://lore.kernel.org/git/87czsv2idy.fsf@evledraar.gmail.com/
4. https://lore.kernel.org/git/YS9ZIDpANfsh7N+S@coredump.intra.peff.net/
5. https://lore.kernel.org/git/20210916035603.76369-1-carenas@gmail.com/

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-09-23 11:29:45 -07:00
.github tests: add a test mode for SANITIZE=leak, run it in CI 2021-09-23 11:29:45 -07:00
Documentation The third batch 2021-09-03 13:49:30 -07:00
block-sha1 block-sha1: drop trailing semicolon from macro definition 2021-03-17 10:20:01 -07:00
builtin Merge branch 'jk/commit-edit-fixup-fix' 2021-09-03 13:49:27 -07:00
ci tests: add a test mode for SANITIZE=leak, run it in CI 2021-09-23 11:29:45 -07:00
compat Merge branch 'es/trace2-log-parent-process-name' 2021-08-24 15:32:40 -07:00
contrib Merge branch 'ti/tcsh-completion-regression-fix' 2021-09-03 13:49:30 -07:00
ewah use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
git-gui Merge https://github.com/prati0100/git-gui 2021-03-04 12:38:50 -08:00
gitk-git
gitweb gitweb: add "e-mail privacy" feature to redact e-mail addresses 2021-04-08 15:54:26 -07:00
mergetools mergetools/kdiff3: make kdiff3 work on Windows too 2021-06-08 10:26:16 +09:00
negotiator use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
perl Merge branch 'ab/send-email-optim' 2021-07-22 13:05:54 -07:00
po l10n: sv.po: Update Swedish translation (5230t0f0u) 2021-08-16 06:54:20 +08:00
ppc
refs Merge branch 'hn/refs-debug-empty-prefix' 2021-07-28 13:18:04 -07:00
sha1collisiondetection@855827c583
sha1dc
sha256
t tests: add a test mode for SANITIZE=leak, run it in CI 2021-09-23 11:29:45 -07:00
templates
trace2 Merge branch 'es/trace2-log-parent-process-name' 2021-08-24 15:32:40 -07:00
xdiff Merge branch 'ab/pickaxe-pcre2' 2021-07-13 16:52:50 -07:00
.cirrus.yml ci: update freebsd 12 cirrus job 2021-08-12 14:00:52 -07:00
.clang-format
.editorconfig
.gitattributes
.gitignore Merge branch 'ls/subtree' 2021-05-10 16:59:47 +09:00
.gitmodules
.mailmap Add entry for Ramkumar Ramachandra 2021-03-08 09:56:34 -08:00
.travis.yml
.tsan-suppressions
CODE_OF_CONDUCT.md
COPYING
GIT-VERSION-GEN The first batch post 2.33 2021-08-24 15:33:23 -07:00
INSTALL INSTALL: note on using Asciidoctor to build doc 2021-03-19 10:49:20 -07:00
LGPL-2.1
Makefile Makefile: add SANITIZE=leak flag to GIT-BUILD-OPTIONS 2021-09-23 11:29:45 -07:00
README.md
RelNotes The first batch post 2.33 2021-08-24 15:33:23 -07:00
SECURITY.md SECURITY: describe how to report vulnerabilities 2021-03-27 15:13:02 -07:00
abspath.c
aclocal.m4
add-interactive.c Merge branch 'rs/xcalloc-takes-nelem-first' 2021-03-19 15:25:39 -07:00
add-interactive.h
add-patch.c *.c static functions: add missing __attribute__((format)) 2021-07-13 15:20:20 -07:00
advice.c pull: abort if --ff-only is given and fast-forwarding is impossible 2021-07-20 21:43:12 -07:00
advice.h Merge branch 'en/pull-conflicting-options' 2021-08-30 16:06:01 -07:00
alias.c
alias.h
alloc.c
alloc.h
apply.c Merge branch 'jk/apply-binary-hunk-parsing-fix' 2021-08-30 16:06:04 -07:00
apply.h
archive-tar.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
archive-zip.c
archive.c string-list.h users: change to use *_{nodup,dup}() 2021-07-01 12:32:22 -07:00
archive.h archive: expand only a single %(describe) per archive 2021-03-11 13:22:44 -08:00
attr.c *: fix typos which duplicate a word 2021-06-14 10:16:06 +09:00
attr.h *: remove 'const' qualifier for struct index_state 2021-04-14 13:46:00 -07:00
banned.h
base85.c
bisect.c bisect: simplify return code from bisect_checkout() 2021-07-28 10:57:37 -07:00
bisect.h
blame.c hash: provide per-algorithm null OIDs 2021-04-27 16:31:39 +09:00
blame.h
blob.c
blob.h
bloom.c Merge branch 'ah/plugleaks' 2021-05-07 12:47:41 +09:00
bloom.h
branch.c Merge branch 'bc/hash-transition-interop-part-1' 2021-05-10 16:59:46 +09:00
branch.h
builtin.h parallel-checkout: make it truly parallel 2021-04-19 11:57:05 -07:00
bulk-checkin.c bulk-checkin: make buffer reuse more obvious and safer 2021-06-11 13:01:22 +09:00
bulk-checkin.h
bundle.c bundle: remove "ref_list" in favor of string-list.c API 2021-07-06 12:10:17 -07:00
bundle.h bundle: remove "ref_list" in favor of string-list.c API 2021-07-06 12:10:17 -07:00
cache-tree.c Merge branch 'ds/commit-and-checkout-with-sparse-index' 2021-08-04 13:28:53 -07:00
cache-tree.h
cache.h Merge branch 'js/expand-runtime-prefix' 2021-08-24 15:32:38 -07:00
cbtree.c oidtree: a crit-bit tree for odb_loose_cache 2021-07-07 21:28:04 -07:00
cbtree.h oidtree: avoid unaligned access to crit-bit tree 2021-08-15 13:13:50 -07:00
chdir-notify.c
chdir-notify.h
check-builtins.sh
check_bindir
checkout.c
checkout.h
chunk-format.c csum-file.h: increase hashfile buffer size 2021-05-19 16:41:21 +09:00
chunk-format.h
color.c
color.h
column.c
column.h
combine-diff.c Merge branch 'ab/pickaxe-pcre2' 2021-07-13 16:52:50 -07:00
command-list.txt
commit-graph.c revision: avoid hitting packfiles when commits are in commit-graph 2021-08-09 09:51:12 -07:00
commit-graph.h revision: avoid hitting packfiles when commits are in commit-graph 2021-08-09 09:51:12 -07:00
commit-reach.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
commit-reach.h
commit-slab-decl.h
commit-slab-impl.h
commit-slab.h
commit.c Merge branch 'ds/gender-neutral-doc' 2021-07-16 17:42:53 -07:00
commit.h Merge branch 'cm/rebase-i-fixup-amend-reword' 2021-03-26 14:59:03 -07:00
common-main.c
config.c Merge branch 'js/expand-runtime-prefix' 2021-08-24 15:32:38 -07:00
config.h Merge branch 'ds/gender-neutral-doc' 2021-07-16 17:42:53 -07:00
config.mak.dev
config.mak.in
config.mak.uname Merge branch 'es/trace2-log-parent-process-name' 2021-08-24 15:32:40 -07:00
configure.ac
connect.c connect, protocol: log negotiated protocol version 2021-08-10 11:46:33 -07:00
connect.h
connected.c connected: do not sort input revisions 2021-08-09 09:51:12 -07:00
connected.h
convert.c convert: release strbuf to avoid leak 2021-07-26 12:19:20 -07:00
convert.h Merge branch 'ds/sparse-index-protections' 2021-04-30 13:50:26 +09:00
copy.c
credential.c *.c *_init(): define in terms of corresponding *_INIT macro 2021-07-01 12:32:22 -07:00
credential.h *.h: move some *_INIT to designated initializers 2021-07-01 12:31:45 -07:00
csum-file.c Merge branch 'tb/midx-use-checksum' 2021-07-16 17:42:46 -07:00
csum-file.h Merge branch 'tb/midx-use-checksum' 2021-07-16 17:42:46 -07:00
ctype.c
daemon.c Merge branch 'rs/daemon-sanitize-dir-sep' 2021-04-08 13:23:26 -07:00
date.c comments: avoid using the gender of our users 2021-06-16 11:25:11 +09:00
decorate.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
decorate.h
delta-islands.c
delta-islands.h
delta.h
detect-compiler
diff-delta.c
diff-lib.c diff-lib: handle index diffs with sparse dirs 2021-07-14 13:42:49 -07:00
diff-merges.c Revert 'diff-merges: let "-m" imply "-p"' 2021-08-09 13:52:01 -07:00
diff-merges.h diff-merges: move specific diff-index "-m" handling to diff-index 2021-05-21 09:24:14 +09:00
diff-no-index.c dir: introduce readdir_skip_dot_and_dotdot() helper 2021-05-27 14:02:37 +09:00
diff.c Merge branch 'ab/pickaxe-pcre2' 2021-08-06 12:52:15 -07:00
diff.h diff.h: move pickaxe fields together again 2021-05-11 12:47:31 +09:00
diffcore-break.c
diffcore-delta.c
diffcore-order.c
diffcore-pickaxe.c xdiff-interface: replace discard_hunk_line() with a flag 2021-05-11 12:47:31 +09:00
diffcore-rename.c Merge branch 'en/ort-perf-batch-15' 2021-08-24 15:32:39 -07:00
diffcore-rotate.c
diffcore.h merge-ort: store filepairs and filespecs in our mem_pool 2021-07-30 09:01:19 -07:00
dir-iterator.c
dir-iterator.h
dir.c use fspathhash() everywhere 2021-07-30 12:14:27 -07:00
dir.h Merge branch 'ew/many-alternate-optim' 2021-07-28 13:17:57 -07:00
editor.c
entry.c string-list.h users: change to use *_{nodup,dup}() 2021-07-01 12:32:22 -07:00
entry.h entry: add checkout_entry_ca() taking preloaded conv_attrs 2021-03-23 10:34:05 -07:00
environment.c environment: move strbuf into block to plug leak 2021-07-26 12:19:20 -07:00
environment.h
exec-cmd.c
exec-cmd.h
fetch-negotiator.c
fetch-negotiator.h
fetch-pack.c Merge branch 'ps/fetch-pack-load-refs-optim' 2021-08-24 15:32:41 -07:00
fetch-pack.h fetch: teach independent negotiation (no packfile) 2021-05-05 10:41:29 +09:00
fmt-merge-msg.c fmt-merge-msg: free newly allocated temporary strings when done 2021-07-26 12:19:19 -07:00
fmt-merge-msg.h
fsck.c fsck: warn about symlinked dotfiles we'll open with O_NOFOLLOW 2021-05-04 11:52:02 +09:00
fsck.h fsck: warn about symlinked dotfiles we'll open with O_NOFOLLOW 2021-05-04 11:52:02 +09:00
fsmonitor.c Merge branch 'jh/fsmonitor-prework' 2021-03-19 15:25:37 -07:00
fsmonitor.h fsmonitor: add assertion that fsmonitor is valid to check_removed 2021-03-18 13:31:13 -07:00
fuzz-commit-graph.c
fuzz-pack-headers.c
fuzz-pack-idx.c
generate-cmdlist.sh
generate-configlist.sh
gettext.c *.c static functions: add missing __attribute__((format)) 2021-07-13 15:20:20 -07:00
gettext.h
git-add--interactive.perl
git-archimport.perl
git-bisect.sh
git-compat-util.h Merge branch 'ew/mmap-failures' 2021-07-16 17:42:47 -07:00
git-cvsexportcommit.perl
git-cvsimport.perl
git-cvsserver.perl *: fix typos which duplicate a word 2021-06-14 10:16:06 +09:00
git-difftool--helper.sh
git-filter-branch.sh filter-branch: drop $_x40 glob 2021-03-10 14:16:58 -08:00
git-instaweb.sh
git-merge-octopus.sh
git-merge-one-file.sh
git-merge-resolve.sh
git-mergetool--lib.sh
git-mergetool.sh mergetool: do not enable hideResolved by default 2021-03-13 15:30:29 -08:00
git-p4.py git-p4: fix failed submit by skip non-text data files 2021-06-28 09:49:30 -07:00
git-quiltimport.sh
git-rebase--preserve-merges.sh
git-request-pull.sh
git-send-email.perl Merge branch 'ab/send-email-optim' 2021-07-22 13:05:54 -07:00
git-sh-i18n.sh
git-sh-setup.sh
git-submodule.sh Merge branch 'ar/submodule-add' 2021-08-04 13:28:52 -07:00
git-svn.perl
git-web--browse.sh
git.c Merge branch 'ps/config-env-option-with-separate-value' 2021-05-07 12:47:37 +09:00
git.rc
gpg-interface.c
gpg-interface.h
graph.c graph: improve grammar of "invalid color" error message 2021-06-15 12:54:26 +09:00
graph.h
grep.c Merge branch 'rs/grep-parser-fix' 2021-07-13 16:52:53 -07:00
grep.h
hash-lookup.c
hash-lookup.h
hash.h oidtree: avoid unaligned access to crit-bit tree 2021-08-15 13:13:50 -07:00
hashmap.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
hashmap.h
help.c
help.h
hex.c hex: print objects using the hash algorithm member 2021-04-27 16:31:39 +09:00
http-backend.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
http-fetch.c
http-push.c http: rename CURLOPT_FILE to CURLOPT_WRITEDATA 2021-07-30 16:01:54 -07:00
http-walker.c http: rename CURLOPT_FILE to CURLOPT_WRITEDATA 2021-07-30 16:01:54 -07:00
http.c http: rename CURLOPT_FILE to CURLOPT_WRITEDATA 2021-07-30 16:01:54 -07:00
http.h http: drop support for curl < 7.19.3 and < 7.17.0 (again) 2021-07-30 16:00:10 -07:00
ident.c
imap-send.c Merge branch 'ab/http-drop-old-curl' 2021-08-24 15:32:36 -07:00
iterator.h
json-writer.c *.c *_init(): define in terms of corresponding *_INIT macro 2021-07-01 12:32:22 -07:00
json-writer.h *.h: move some *_INIT to designated initializers 2021-07-01 12:31:45 -07:00
khash.h khash: clarify that allocations never fail 2021-07-06 13:07:50 -07:00
kwset.c
kwset.h
levenshtein.c
levenshtein.h
line-log.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
line-log.h
line-range.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
line-range.h
linear-assignment.c
linear-assignment.h
list-objects-filter-options.c help: fix small typo in error message 2021-05-21 07:52:10 +09:00
list-objects-filter-options.h list-objects: implement object type filter 2021-04-19 14:09:11 -07:00
list-objects-filter.c list-objects: implement object type filter 2021-04-19 14:09:11 -07:00
list-objects-filter.h list-objects: support filtering by tag and commit 2021-04-12 09:35:50 -07:00
list-objects.c list-objects.c: rename "traverse_trees_and_blobs" to "traverse_non_commits" 2021-08-12 13:08:30 -07:00
list-objects.h
list.h
ll-merge.c ll_union_merge(): rename path_unused parameter 2021-06-11 12:37:33 +09:00
ll-merge.h
lockfile.c
lockfile.h
log-tree.c load_ref_decorations(): fix decoration with tags 2021-07-14 10:11:02 -07:00
log-tree.h
ls-refs.c
ls-refs.h
mailinfo.c Merge branch 'ar/mailinfo-memcmp-to-skip-prefix' 2021-07-08 13:15:03 -07:00
mailinfo.h am: learn to process quoted lines that ends with CRLF 2021-05-10 15:06:22 +09:00
mailmap.c *.c static functions: add missing __attribute__((format)) 2021-07-13 15:20:20 -07:00
mailmap.h
match-trees.c Always use oidread to read into struct object_id 2021-04-27 16:31:38 +09:00
mem-pool.c mem-pool: drop trailing semicolon from macro definition 2021-03-17 10:20:16 -07:00
mem-pool.h
merge-blobs.c
merge-blobs.h
merge-ort-wrappers.c merge(s): apply consistent punctuation to "up to date" messages 2021-05-03 14:14:56 +09:00
merge-ort-wrappers.h
merge-ort.c Merge branch 'en/ort-perf-batch-15' 2021-08-24 15:32:39 -07:00
merge-ort.h merge-ort: avoid accidental API mis-use 2021-05-20 15:40:39 +09:00
merge-recursive.c use fspathhash() everywhere 2021-07-30 12:14:27 -07:00
merge-recursive.h
merge.c dir.[ch]: replace dir_init() with DIR_INIT 2021-07-01 12:32:22 -07:00
mergesort.c
mergesort.h
midx.c Merge branch 'ab/attribute-format' 2021-07-28 13:17:59 -07:00
midx.h pack-revindex: write multi-pack reverse indexes 2021-04-01 13:07:37 -07:00
name-hash.c Merge branch 'ds/sparse-index-protections' 2021-04-30 13:50:26 +09:00
notes-cache.c
notes-cache.h
notes-merge.c dir: introduce readdir_skip_dot_and_dotdot() helper 2021-05-27 14:02:37 +09:00
notes-merge.h
notes-utils.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
notes-utils.h
notes.c hash: provide per-algorithm null OIDs 2021-04-27 16:31:39 +09:00
notes.h
object-file.c Merge branch 'cb/many-alternate-optim-fixup' 2021-08-11 12:36:17 -07:00
object-name.c oidtree: a crit-bit tree for odb_loose_cache 2021-07-07 21:28:04 -07:00
object-store.h object-store: avoid extra ';' from KHASH_INIT 2021-08-09 09:01:30 -07:00
object.c Merge branch 'jk/log-decorate-optim' 2021-07-28 13:17:58 -07:00
object.h object.h: add lookup_object_by_type() function 2021-06-28 20:30:18 -07:00
oid-array.c
oid-array.h
oidmap.c
oidmap.h
oidset.c
oidset.h
oidtree.c oidtree: avoid unaligned access to crit-bit tree 2021-08-15 13:13:50 -07:00
oidtree.h oidtree: a crit-bit tree for odb_loose_cache 2021-07-07 21:28:04 -07:00
pack-bitmap-write.c
pack-bitmap.c Merge branch 'jk/check-pack-valid-before-opening-bitmap' 2021-08-02 14:06:43 -07:00
pack-bitmap.h Merge branch 'ps/rev-list-object-type-filter' 2021-05-07 12:47:41 +09:00
pack-check.c csum-file: introduce checksum_valid() 2021-06-28 20:36:17 -07:00
pack-objects.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
pack-objects.h pack-objects: move static inline from a header to the sole consumer 2021-05-27 12:14:41 +09:00
pack-revindex.c Merge branch 'tb/reverse-midx' 2021-04-08 13:23:25 -07:00
pack-revindex.h pack-revindex: read multi-pack reverse indexes 2021-04-01 13:07:37 -07:00
pack-write.c Merge branch 'tb/reverse-midx' 2021-04-08 13:23:25 -07:00
pack.h Merge branch 'tb/reverse-midx' 2021-04-08 13:23:25 -07:00
packfile.c xmmap: inform Linux users of tuning knobs on ENOMEM 2021-06-29 23:14:25 -07:00
packfile.h
pager.c pager: avoid setting COLUMNS when we're guessing its value 2021-06-28 10:42:10 -07:00
parallel-checkout.c parallel-checkout: send the new object_id algo field to the workers 2021-05-18 05:38:54 +09:00
parallel-checkout.h parallel-checkout: support progress displaying 2021-04-19 11:57:05 -07:00
parse-options-cb.c hash: provide per-algorithm null OIDs 2021-04-27 16:31:39 +09:00
parse-options.c parse-options: don't complete option aliases by default 2021-07-16 11:31:44 -07:00
parse-options.h parse-options: don't leak alias help messages 2021-03-21 14:39:10 -07:00
patch-delta.c
patch-ids.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
patch-ids.h
path.c interpolate_path(): allow specifying paths relative to the runtime prefix 2021-07-26 12:17:16 -07:00
path.h merge-ort: write $GIT_DIR/AUTO_MERGE whenever we hit a conflict 2021-03-20 12:35:40 -07:00
pathspec.c pathspec: stop calling ensure_full_index 2021-07-29 12:36:34 -07:00
pathspec.h Merge branch 'ds/gender-neutral-doc' 2021-07-16 17:42:53 -07:00
pkt-line.c Merge branch 'dl/packet-read-response-end-fix' 2021-07-28 13:17:56 -07:00
pkt-line.h pkt-line: add options argument to read_packetized_to_strbuf() 2021-03-15 14:32:50 -07:00
preload-index.c
pretty.c log: avoid loading decorations for userformats that don't need it 2021-06-28 20:30:17 -07:00
pretty.h log: avoid loading decorations for userformats that don't need it 2021-06-28 20:30:17 -07:00
prio-queue.c
prio-queue.h
progress.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
progress.h
promisor-remote.c Merge branch 'jt/partial-clone-submodule-1' 2021-07-16 17:42:53 -07:00
promisor-remote.h promisor-remote: support per-repository config 2021-06-28 09:57:42 -07:00
prompt.c
prompt.h
protocol-caps.c object-info: support for retrieving object info 2021-04-20 17:41:13 -07:00
protocol-caps.h protocol-caps.h: add newline at end of file 2021-06-08 10:08:41 +09:00
protocol.c connect, protocol: log negotiated protocol version 2021-08-10 11:46:33 -07:00
protocol.h
prune-packed.c
prune-packed.h
quote.c ref-filter: --format=%(raw) support --perl 2021-07-26 12:01:25 -07:00
quote.h Merge branch 'zh/ref-filter-raw-data' 2021-08-24 15:32:37 -07:00
range-diff.c Merge branch 'jk/range-diff-fixes' 2021-08-30 16:06:05 -07:00
range-diff.h
reachable.c object.h: add lookup_object_by_type() function 2021-06-28 20:30:18 -07:00
reachable.h
read-cache.c Merge branch 'ah/plugleaks' 2021-08-04 13:28:52 -07:00
rebase-interactive.c
rebase-interactive.h
rebase.c
rebase.h
ref-filter.c Merge branch 'zh/ref-filter-raw-data' 2021-08-24 15:32:37 -07:00
ref-filter.h ref-filter: add %(rest) atom 2021-07-26 12:01:26 -07:00
reflog-walk.c use CALLOC_ARRAY 2021-03-13 16:00:09 -08:00
reflog-walk.h
refs.c Merge branch 'hn/refs-iterator-peel-returns-boolean' 2021-07-16 17:42:49 -07:00
refs.h
refspec.c
refspec.h
remote-curl.c Merge branch 'ab/http-drop-old-curl' 2021-08-24 15:32:36 -07:00
remote.c *: fix typos which duplicate a word 2021-06-14 10:16:06 +09:00
remote.h
replace-object.c
replace-object.h
repo-settings.c sparse-index: add index.sparse config option 2021-03-30 12:57:47 -07:00
repository.c promisor-remote: support per-repository config 2021-06-28 09:57:42 -07:00
repository.h promisor-remote: support per-repository config 2021-06-28 09:57:42 -07:00
rerere.c dir: introduce readdir_skip_dot_and_dotdot() helper 2021-05-27 14:02:37 +09:00
rerere.h
reset.c reset: clear_unpack_trees_porcelain to plug leak 2021-07-26 12:19:21 -07:00
reset.h
resolve-undo.c Merge branch 'ds/sparse-index-protections' 2021-04-30 13:50:26 +09:00
resolve-undo.h
revision.c revision: avoid hitting packfiles when commits are in commit-graph 2021-08-09 09:51:12 -07:00
revision.h revision: separate walk and unsorted flags 2021-08-05 09:37:28 -07:00
run-command.c Merge branch 'jt/partial-clone-submodule-1' 2021-07-16 17:42:53 -07:00
run-command.h Merge branch 'jt/partial-clone-submodule-1' 2021-07-16 17:42:53 -07:00
send-pack.c Merge branch 'jt/push-negotiation-fixes' 2021-08-24 15:32:40 -07:00
send-pack.h
sequencer.c Merge branch 'pw/rebase-r-fixes' 2021-09-03 13:49:29 -07:00
sequencer.h sequencer: fix edit handling for cherry-pick and revert messages 2021-03-31 14:10:50 -07:00
serve.c Merge branch 'dl/packet-read-response-end-fix' 2021-07-28 13:17:56 -07:00
serve.h
server-info.c *.c static functions: add missing __attribute__((format)) 2021-07-13 15:20:20 -07:00
setup.c Merge branch 'jt/partial-clone-submodule-1' 2021-07-16 17:42:53 -07:00
sh-i18n--envsubst.c builtins + test helpers: use return instead of exit() in cmd_* 2021-06-09 09:15:58 +09:00
sha1dc_git.c
sha1dc_git.h
shallow.c
shallow.h
shell.c builtins + test helpers: use return instead of exit() in cmd_* 2021-06-09 09:15:58 +09:00
shortlog.h
sideband.c sideband: don't lose clear-to-eol at packet boundary 2021-06-17 14:11:36 +09:00
sideband.h
sigchain.c
sigchain.h
simple-ipc.h simple-ipc: correct ifdefs when NO_PTHREADS is defined 2021-05-21 07:55:00 +09:00
sparse-index.c sparse-index: recompute cache-tree 2021-07-14 15:05:53 -07:00
sparse-index.h sparse-index: expand_to_path() 2021-04-14 13:47:54 -07:00
split-index.c split-index: use oideq instead of memcmp to compare object_id's 2021-06-15 12:07:56 +09:00
split-index.h
stable-qsort.c
strbuf.c *.c *_init(): define in terms of corresponding *_INIT macro 2021-07-01 12:32:22 -07:00
strbuf.h Merge branch 'ab/attribute-format' 2021-07-28 13:17:59 -07:00
streaming.c streaming.c: move {open,close,read} from vtable to "struct git_istream" 2021-05-06 12:56:10 +09:00
streaming.h
string-list.c string-list.[ch]: add a string_list_init_{nodup,dup}() 2021-07-01 12:32:22 -07:00
string-list.h string-list.[ch]: add a string_list_init_{nodup,dup}() 2021-07-01 12:32:22 -07:00
strmap.c *.c *_init(): define in terms of corresponding *_INIT macro 2021-07-01 12:32:22 -07:00
strmap.h
strvec.c *.c *_init(): define in terms of corresponding *_INIT macro 2021-07-01 12:32:22 -07:00
strvec.h
sub-process.c
sub-process.h
submodule-config.c hash: provide per-algorithm null OIDs 2021-04-27 16:31:39 +09:00
submodule-config.h
submodule.c run-command: refactor subprocess env preparation 2021-06-28 09:58:01 -07:00
submodule.h *: remove 'const' qualifier for struct index_state 2021-04-14 13:46:00 -07:00
symlinks.c checkout: don't follow symlinks when removing entries 2021-03-18 12:58:10 -07:00
tag.c
tag.h
tar.h
tempfile.c
tempfile.h
thread-utils.c
thread-utils.h
tmp-objdir.c
tmp-objdir.h
trace.c
trace.h
trace2.c tr2: log parent process name 2021-07-22 13:35:20 -07:00
trace2.h tr2: log parent process name 2021-07-22 13:35:20 -07:00
trailer.c trailer: add new .cmd config option 2021-05-04 12:09:43 +09:00
trailer.h
transport-helper.c fetch: teach independent negotiation (no packfile) 2021-05-05 10:41:29 +09:00
transport-internal.h
transport.c Merge branch 'ab/struct-init' 2021-07-16 17:42:53 -07:00
transport.h fetch: teach independent negotiation (no packfile) 2021-05-05 10:41:29 +09:00
tree-diff.c hash: provide per-algorithm null OIDs 2021-04-27 16:31:39 +09:00
tree-walk.c Always use oidread to read into struct object_id 2021-04-27 16:31:38 +09:00
tree-walk.h
tree.c tree.h API: simplify read_tree_recursive() signature 2021-03-20 16:09:26 -07:00
tree.h tree.h API: simplify read_tree_recursive() signature 2021-03-20 16:09:26 -07:00
unicode-width.h
unimplemented.sh
unix-socket.c unix-socket: disallow chdir() when creating unix domain sockets 2021-03-15 14:32:51 -07:00
unix-socket.h unix-socket: disallow chdir() when creating unix domain sockets 2021-03-15 14:32:51 -07:00
unix-stream-server.c unix-stream-server: create unix domain socket under lock 2021-03-15 14:32:51 -07:00
unix-stream-server.h unix-stream-server: create unix domain socket under lock 2021-03-15 14:32:51 -07:00
unpack-trees.c Merge branch 'ds/commit-and-checkout-with-sparse-index' 2021-08-04 13:28:53 -07:00
unpack-trees.h stash show: teach --include-untracked and --only-untracked 2021-03-05 14:31:26 -08:00
upload-pack.c Merge branch 'jt/push-negotiation' 2021-05-16 21:05:22 +09:00
upload-pack.h
url.c
url.h
urlmatch.c
urlmatch.h
usage.c usage.c: don't copy/paste the same comment three times 2021-04-13 14:56:28 -07:00
userdiff.c Merge branch 'th/userdiff-more-java' 2021-08-30 16:06:05 -07:00
userdiff.h userdiff: add and use for_each_userdiff_driver() 2021-04-08 12:19:10 -07:00
utf8.c t0060: test ntfs/hfs-obscured dotfiles 2021-05-04 11:52:02 +09:00
utf8.h t0060: test ntfs/hfs-obscured dotfiles 2021-05-04 11:52:02 +09:00
varint.c
varint.h
version.c
version.h
versioncmp.c
walker.c lookup_unknown_object(): take a repository argument 2021-04-13 13:18:46 -07:00
walker.h
wildmatch.c
wildmatch.h
worktree.c *.c static functions: add missing __attribute__((format)) 2021-07-13 15:20:20 -07:00
worktree.h
wrap-for-bin.sh
wrapper.c
write-or-die.c fsync(): be prepared to see EINTR 2021-06-05 22:13:40 +09:00
ws.c
wt-status.c Merge branch 'ds/status-with-sparse-index' 2021-07-28 13:18:02 -07:00
wt-status.h status: skip sparse-checkout percentage with sparse-index 2021-07-14 13:42:49 -07:00
xdiff-interface.c Merge branch 'ab/pickaxe-pcre2' 2021-07-13 16:52:50 -07:00
xdiff-interface.h xdiff-interface: replace discard_hunk_line() with a flag 2021-05-11 12:47:31 +09:00
zlib.c

Build status

Git - fast, scalable, distributed revision control system

Git is a fast, scalable, distributed revision control system with an unusually rich command set that provides both high-level operations and full access to internals.

Git is an Open Source project covered by the GNU General Public License version 2 (some parts of it are under different licenses, compatible with the GPLv2). It was originally written by Linus Torvalds with help of a group of hackers around the net.

Please read the file INSTALL for installation instructions.

Many Git online resources are accessible from https://git-scm.com/ including full documentation and Git related tools.

See Documentation/gittutorial.txt to get started, then see Documentation/giteveryday.txt for a useful minimum set of commands, and Documentation/git-<commandname>.txt for documentation of each command. If git has been correctly installed, then the tutorial can also be read with man gittutorial or git help tutorial, and the documentation of each command with man git-<commandname> or git help <commandname>.

CVS users may also want to read Documentation/gitcvs-migration.txt (man gitcvs-migration or git help cvs-migration if git is installed).

The user discussion and development of Git take place on the Git mailing list -- everyone is welcome to post bug reports, feature requests, comments and patches to git@vger.kernel.org (read Documentation/SubmittingPatches for instructions on patch submission). To subscribe to the list, send an email with just "subscribe git" in the body to majordomo@vger.kernel.org. The mailing list archives are available at https://lore.kernel.org/git/, http://marc.info/?l=git and other archival sites.

Issues which are security relevant should be disclosed privately to the Git Security mailing list git-security@googlegroups.com.

The maintainer frequently sends the "What's cooking" reports that list the current status of various development topics to the mailing list. The discussion following them give a good reference for project status, development direction and remaining tasks.

The name "git" was given by Linus Torvalds when he wrote the very first version. He described the tool as "the stupid content tracker" and the name as (depending on your mood):

  • random three-letter combination that is pronounceable, and not actually used by any common UNIX command. The fact that it is a mispronunciation of "get" may or may not be relevant.
  • stupid. contemptible and despicable. simple. Take your pick from the dictionary of slang.
  • "global information tracker": you're in a good mood, and it actually works for you. Angels sing, and a light suddenly fills the room.
  • "goddamn idiotic truckload of sh*t": when it breaks