Git with broken hash generation to generate collisions between object IDs. Don't use this! https://undefinedbehavior.de/posts/commit-vandalism/
Go to file
Jeff King cf3c635210 alternates: accept double-quoted paths
We read lists of alternates from objects/info/alternates
files (delimited by newline), as well as from the
GIT_ALTERNATE_OBJECT_DIRECTORIES environment variable
(delimited by colon or semi-colon, depending on the
platform).

There's no mechanism for quoting the delimiters, so it's
impossible to specify an alternate path that contains a
colon in the environment, or one that contains a newline in
a file. We've lived with that restriction for ages because
both alternates and filenames with colons are relatively
rare, and it's only a problem when the two meet. But since
722ff7f87 (receive-pack: quarantine objects until
pre-receive accepts, 2016-10-03), which builds on the
alternates system, every push causes the receiver to set
GIT_ALTERNATE_OBJECT_DIRECTORIES internally.

It would be convenient to have some way to quote the
delimiter so that we can represent arbitrary paths.

The simplest thing would be an escape character before a
quoted delimiter (e.g., "\:" as a literal colon). But that
creates a backwards compatibility problem: any path which
uses that escape character is now broken, and we've just
shifted the problem. We could choose an unlikely escape
character (e.g., something from the non-printable ASCII
range), but that's awkward to use.

Instead, let's treat names as unquoted unless they begin
with a double-quote, in which case they are interpreted via
our usual C-stylke quoting rules. This also breaks
backwards-compatibility, but in a smaller way: it only
matters if your file has a double-quote as the very _first_
character in the path (whereas an escape character is a
problem anywhere in the path).  It's also consistent with
many other parts of git, which accept either a bare pathname
or a double-quoted one, and the sender can choose to quote
or not as required.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-12-12 15:10:43 -08:00
block-sha1 sha1: provide another level of indirection for the SHA-1 functions 2015-11-05 10:35:11 -08:00
builtin receive-pack: quarantine objects until pre-receive accepts 2016-10-10 13:54:02 -07:00
ci travis-ci: build documentation 2016-05-10 11:19:07 -07:00
compat Merge branch 'rs/compat-strdup' into maint 2016-09-19 13:51:42 -07:00
contrib Merge branch 'rs/copy-array' 2016-10-03 13:30:33 -07:00
Documentation alternates: accept double-quoted paths 2016-12-12 15:10:43 -08:00
ewah ewah: convert to REALLOC_ARRAY, etc 2016-02-22 14:51:09 -08:00
git-gui Merge branch 'va/git-gui-i18n' 2016-10-03 13:30:37 -07:00
gitk-git Merge branch 'master' of git://ozlabs.org/~paulus/gitk 2016-03-20 18:05:10 -07:00
gitweb gitweb: use highlight's shebang detection 2016-09-25 16:39:11 -07:00
mergetools mergetools: add support for ExamDiff 2016-04-04 09:15:14 -07:00
perl git-svn: warn instead of dying when commit data is missing 2016-07-09 22:53:54 +00:00
po git-gui: l10n: add Portuguese translation 2016-09-26 07:18:33 -07:00
ppc sha1: provide another level of indirection for the SHA-1 functions 2015-11-05 10:35:11 -08:00
refs Merge branch 'mh/ref-store' 2016-09-19 13:47:19 -07:00
t alternates: accept double-quoted paths 2016-12-12 15:10:43 -08:00
templates push options: {pre,post}-receive hook learns about push options 2016-07-14 15:50:17 -07:00
vcs-svn Merge branch 'mr/vcs-svn-printf-ulong' into maint 2016-09-29 16:49:37 -07:00
xdiff Merge branch 'mh/diff-indent-heuristic' 2016-10-03 13:30:38 -07:00
.gitattributes .gitattributes: set file type for C files 2016-07-07 14:11:15 -07:00
.gitignore test helpers: move test-* to t/helper/ subdirectory 2016-04-15 10:12:19 -07:00
.mailmap add David Turner's Two Sigma address 2016-09-26 17:46:44 -07:00
.travis.yml Merge branch 'ls/travis-homebrew-path-fix' into maint 2016-09-29 16:49:45 -07:00
abspath.c Windows: shorten code by re-using convert_slashes() 2016-04-04 18:03:02 -07:00
aclocal.m4 configure: use AC_LANG_PROGRAM consistently 2011-02-14 10:55:15 -08:00
advice.c i18n: advice: internationalize message for conflicts 2016-06-17 15:45:48 -07:00
advice.h pull: check if in unresolved merge state 2015-06-18 13:17:16 -07:00
alias.c convert trivial cases to ALLOC_ARRAY 2016-02-22 14:51:09 -08:00
alloc.c alloc: factor out commit index 2014-07-28 10:14:33 -07:00
apply.c introduce CHECKOUT_INIT 2016-09-22 13:42:18 -07:00
apply.h apply: learn to use a different index file 2016-09-07 12:29:54 -07:00
archive-tar.c Merge branch 'jk/big-and-future-archive-tar' 2016-08-12 09:47:37 -07:00
archive-zip.c Merge branch 'rs/archive-zip-many' into maint 2015-09-03 19:18:01 -07:00
archive.c i18n: archive: mark errors for translation 2016-08-09 12:44:59 -07:00
archive.h archive: convert to use parse_pathspec 2013-07-15 10:56:07 -07:00
argv-array.c argv-array: add detach function 2016-02-22 14:50:32 -08:00
argv-array.h argv-array: add detach function 2016-02-22 14:50:32 -08:00
attr.c Merge branch 'ss/exc-flag-is-a-collection-of-bits' into maint 2016-04-14 18:37:15 -07:00
attr.h correct a few doubled-word nits in comments and documentation 2012-03-28 11:18:35 -07:00
base85.c base85.c: have SP around arithmetic operators 2013-10-16 10:27:26 -07:00
bisect.c Merge branch 'jk/printf-format' 2016-07-19 13:22:22 -07:00
bisect.h bisect: simplify the addition of new bisect terms 2015-08-03 11:42:41 -07:00
blob.c add object_as_type helper for casting objects 2014-07-28 10:14:33 -07:00
blob.h Replace parse_blob() with an explanatory comment 2010-01-18 17:04:02 -08:00
branch.c worktree.c: check whether branch is rebased in another worktree 2016-04-22 14:09:38 -07:00
branch.h worktree.c: check whether branch is rebased in another worktree 2016-04-22 14:09:38 -07:00
builtin.h builtin: convert textconv_object to use struct object_id 2016-09-07 12:59:42 -07:00
bulk-checkin.c use xsnprintf for generating git object headers 2015-09-25 10:18:18 -07:00
bulk-checkin.h cleanups: ensure that git-compat-util.h is included first 2014-09-15 12:05:14 -07:00
bundle.c bundle: don't leak an fd in case of early return 2016-04-01 10:33:18 -07:00
bundle.h Merge branch 'jc/unseekable-bundle' 2011-10-21 16:04:32 -07:00
cache-tree.c cache: convert struct cache_entry to use struct object_id 2016-09-07 12:59:42 -07:00
cache-tree.h cache-tree: introduce write_index_as_tree() 2015-08-04 22:02:11 -07:00
cache.h tmp-objdir: put quarantine information in the environment 2016-10-10 13:54:02 -07:00
check_bindir check_bindir: avoid "test <cond> -a/-o <cond>" 2014-06-09 14:47:06 -07:00
check-builtins.sh check-builtins: strip executable suffix $X when enumerating builtins 2015-02-05 12:03:27 -08:00
check-racy.c check-racy.c: use error_errno() 2016-05-09 12:29:08 -07:00
color.c Merge branch 'jk/squelch-false-warning-from-gcc-o3' into maint 2016-09-19 13:51:41 -07:00
color.h Merge branch 'js/color-on-windows-comment' into maint 2016-07-28 11:25:55 -07:00
column.c use xmallocz to avoid size arithmetic 2016-02-22 14:51:09 -08:00
column.h column: support piping stdout to external git-column process 2012-04-27 09:26:38 -07:00
combine-diff.c Merge branch 'bc/cocci' 2016-07-19 13:22:16 -07:00
command-list.txt Merge branch 'nd/multiple-work-trees' 2015-07-13 14:02:02 -07:00
commit-slab.h Merge branch 'vs/typofix' 2016-08-12 09:47:37 -07:00
commit.c Merge branch 'rs/copy-array' 2016-10-03 13:30:33 -07:00
commit.h Merge branch 'rs/pull-signed-tag' 2016-08-19 15:34:14 -07:00
common-main.c mingw: declare main()'s argv as const 2016-07-06 08:11:47 -07:00
config.c Merge branch 'jk/setup-sequence-update' 2016-09-21 15:15:24 -07:00
config.mak.in Merge branch 'jc/remove-export-from-config-mak-in' 2013-04-01 09:00:02 -07:00
config.mak.uname Merge branch 'ew/build-time-pager-tweaks' 2016-08-08 14:48:44 -07:00
configure.ac Merge branch 'ew/autoconf-pthread' into maint 2016-08-10 11:55:21 -07:00
connect.c Merge branch 'va/i18n-more' 2016-09-26 16:09:18 -07:00
connect.h connect & http: support -4 and -6 switches for remote operations 2016-02-12 11:34:14 -08:00
connected.c check_connected: accept an env argument 2016-10-10 13:54:02 -07:00
connected.h check_connected: accept an env argument 2016-10-10 13:54:02 -07:00
convert.c convert: Correct NNO tests and missing LF will be replaced by CRLF 2016-08-14 13:45:52 -07:00
convert.h convert: unify the "auto" handling of CRLF 2016-07-06 11:53:51 -07:00
copy.c copy.c: use error_errno() 2016-05-09 12:29:08 -07:00
COPYING Update COPYING with GPLv2 with new FSF address 2010-01-17 14:29:37 -08:00
credential-cache--daemon.c Merge branch 'jk/common-main-2.8' into jk/common-main 2016-07-06 10:02:57 -07:00
credential-cache.c add an extra level of indirection to main() 2016-07-01 15:09:10 -07:00
credential-store.c add an extra level of indirection to main() 2016-07-01 15:09:10 -07:00
credential.c credential: let empty credential specs reset helper list 2016-02-26 10:58:14 -08:00
credential.h credential: let helpers tell us to quit 2014-12-04 10:11:12 -08:00
csum-file.c sha1fd_check: die when we cannot open the file 2015-03-19 13:35:15 -07:00
csum-file.h Merge branch 'jk/pack-bitmap' 2014-12-12 14:31:42 -08:00
ctype.c kwset: use unsigned char to store values with high-bit set 2015-03-02 12:32:24 -08:00
daemon.c Merge branch 'jk/common-main' into maint 2016-09-08 21:35:51 -07:00
date.c date: add "unix" format 2016-07-27 14:15:51 -07:00
decorate.c Remove get_object_hash. 2015-11-20 08:02:05 -05:00
decorate.h decorate: allow const objects to be decorated 2008-08-20 13:30:49 -07:00
delta.h comments: fix misuses of "nor" 2014-03-31 15:29:27 -07:00
diff-delta.c create_delta_index: simplify condition always evaluating to true 2013-08-18 12:56:23 -07:00
diff-lib.c cache: convert struct cache_entry to use struct object_id 2016-09-07 12:59:42 -07:00
diff-no-index.c Merge branch 'jk/setup-sequence-update' 2016-09-21 15:15:24 -07:00
diff.c Merge branch 'js/regexec-buf' into maint 2016-09-29 16:49:45 -07:00
diff.h Merge branch 'mh/diff-indent-heuristic' 2016-09-26 16:09:16 -07:00
diffcore-break.c diff: rename struct diff_filespec's sha1_valid member 2016-06-28 11:39:02 -07:00
diffcore-delta.c use st_add and st_mult for allocation size computation 2016-02-22 14:51:09 -08:00
diffcore-order.c convert trivial cases to ALLOC_ARRAY 2016-02-22 14:51:09 -08:00
diffcore-pickaxe.c Merge branch 'js/regexec-buf' into maint 2016-09-29 16:49:45 -07:00
diffcore-rename.c pass constants as first argument to st_mult() 2016-08-01 14:01:03 -07:00
diffcore.h diff: rename struct diff_filespec's sha1_valid member 2016-06-28 11:39:02 -07:00
dir-iterator.c dir_iterator: new API for iterating over a directory tree 2016-06-20 11:38:21 -07:00
dir-iterator.h dir_iterator: new API for iterating over a directory tree 2016-06-20 11:38:21 -07:00
dir.c cache: convert struct cache_entry to use struct object_id 2016-09-07 12:59:42 -07:00
dir.h Merge branch 'mh/split-under-lock' 2016-07-25 14:13:32 -07:00
editor.c editor.c: use error_errno() 2016-05-09 12:29:08 -07:00
entry.c streaming: make stream_blob_to_fd take struct object_id 2016-09-07 12:59:42 -07:00
environment.c Merge branch 'jk/setup-sequence-update' 2016-09-21 15:15:24 -07:00
exec_cmd.c Merge branch 'ak/extract-argv0-last-dir-sep' into maint 2016-03-10 11:13:47 -08:00
exec_cmd.h prepare_{git,shell}_cmd: use argv_array 2016-02-22 14:51:09 -08:00
fast-import.c Merge branch 'jk/common-main' 2016-07-19 13:22:19 -07:00
fetch-pack.c fetch-pack: do not reset in_vain on non-novel acks 2016-09-23 12:37:45 -07:00
fetch-pack.h Merge branch 'nd/shallow-clone' 2014-01-17 12:21:20 -08:00
fmt-merge-msg.h fmt-merge-msg: use branch.$name.description 2011-10-07 10:11:47 -07:00
fsck.c fsck: handle bad trees like other errors 2016-09-27 14:09:10 -07:00
fsck.h fsck: give the error function a chance to see the fsck_options 2016-07-18 11:35:00 -07:00
generate-cmdlist.sh generate-cmdlist: re-implement as shell script 2015-08-25 11:24:31 -07:00
gettext.c gettext: add is_utf8_locale() 2016-07-01 12:44:57 -07:00
gettext.h gettext: add is_utf8_locale() 2016-07-01 12:44:57 -07:00
git-add--interactive.perl diff: improve positioning of add/delete blocks in diffs 2016-09-19 10:25:11 -07:00
git-archimport.perl git-archimport: use a lowercase "usage:" string 2013-02-24 13:31:06 -08:00
git-bisect.sh i18n: unmark die messages for translation 2016-06-17 15:46:10 -07:00
git-compat-util.h Merge branch 'rs/copy-array' 2016-10-03 13:30:33 -07:00
git-cvsexportcommit.perl git-cvsexportcommit: use a lowercase "usage:" string 2013-02-24 13:31:07 -08:00
git-cvsimport.perl Merge branch 'cn/cvsimport-perl-update' 2015-06-25 11:08:08 -07:00
git-cvsserver.perl typofix: assorted typofixes in comments, documentation and messages 2016-05-06 13:16:37 -07:00
git-difftool--helper.sh difftool: always honor fatal error exit codes 2016-08-15 15:24:05 -07:00
git-difftool.perl difftool: use Git::* functions instead of passing around state 2016-07-28 14:01:55 -07:00
git-filter-branch.sh Merge branch 'jk/filter-branch-no-index' into maint 2016-02-05 14:54:13 -08:00
git-instaweb.sh git-instaweb: use @SHELL_PATH@ instead of /bin/sh 2015-03-10 15:10:35 -07:00
git-merge-octopus.sh git-merge-octopus: do not capitalize "octopus" 2016-09-08 12:17:10 -07:00
git-merge-one-file.sh Merge branch 'jk/no-diff-emit-common' into maint 2016-03-10 11:13:42 -08:00
git-merge-resolve.sh Convert to use quiet option when available 2009-04-22 19:05:37 -07:00
git-mergetool--lib.sh Merge branch 'nf/mergetool-prompt' 2016-05-03 14:08:17 -07:00
git-mergetool.sh Merge branch 'nf/mergetool-prompt' into HEAD 2016-05-18 14:40:07 -07:00
git-p4.py Spelling fixes 2016-08-11 14:35:42 -07:00
git-parse-remote.sh i18n: git-parse-remote.sh: mark strings for translation 2016-04-19 12:07:49 -07:00
git-quiltimport.sh git-quiltimport: add commandline option --series <file> 2015-09-01 11:10:07 -07:00
git-rebase--am.sh rebase: update comment about FreeBSD /bin/sh 2016-06-17 11:04:38 -07:00
git-rebase--interactive.sh Merge branch 'rt/rebase-i-broken-insn-advise' into maint 2016-09-29 16:49:46 -07:00
git-rebase--merge.sh Merge branch 'em/newer-freebsd-shells-are-fine-with-returns' into maint 2016-07-06 13:06:41 -07:00
git-rebase.sh i18n: git-sh-setup.sh: mark strings for translation 2016-06-17 15:45:48 -07:00
git-relink.perl git-relink: use a lowercase "usage:" string 2013-02-24 13:31:06 -08:00
git-remote-testgit.sh transport-helper: do not request symbolic refs to remote helpers 2015-01-21 22:46:59 -08:00
git-request-pull.sh Merge branch 'lt/request-pull' 2014-05-19 10:35:36 -07:00
git-send-email.perl Merge branch 'jc/send-email-skip-backup' 2016-07-11 10:31:04 -07:00
git-sh-i18n.sh i18n: rebase-interactive: mark here-doc strings for translation 2016-06-17 15:45:48 -07:00
git-sh-setup.sh Merge branch 'ew/build-time-pager-tweaks' 2016-08-08 14:48:44 -07:00
git-stash.sh i18n: stash: mark messages for translation 2016-09-21 10:20:43 -07:00
git-submodule.sh clone: pass --progress decision to recursive submodules 2016-09-22 11:22:47 -07:00
git-svn.perl git-svn: allow --version to work anywhere 2016-07-22 20:38:11 +00:00
GIT-VERSION-GEN Git 2.10.1 2016-10-03 13:24:18 -07:00
git-web--browse.sh git-web--browse.sh: use the $( ... ) construct for command substitution 2014-04-23 15:17:02 -07:00
git.c Merge branch 'jk/setup-sequence-update' 2016-09-21 15:15:24 -07:00
git.rc Makefile: Fix compilation of Windows resource file 2014-01-23 10:00:28 -08:00
gpg-interface.c Merge branch 'lt/gpg-show-long-key-in-signature-verification-maint' into lt/gpg-show-long-key-in-signature-verification 2016-08-16 15:04:13 -07:00
gpg-interface.h verify-commit: add option to print raw gpg status information 2015-06-22 14:20:47 -07:00
graph.c graph: add support for --line-prefix on all graph-aware output 2016-08-31 18:07:09 -07:00
graph.h graph: add support for --line-prefix on all graph-aware output 2016-08-31 18:07:09 -07:00
grep.c Merge branch 'js/regexec-buf' into maint 2016-09-29 16:49:45 -07:00
grep.h Merge branch 'jc/grep-commandline-vs-configuration' 2016-08-04 14:39:18 -07:00
hashmap.c convert trivial cases to FLEX_ARRAY macros 2016-02-22 14:51:09 -08:00
hashmap.h hashmap: add string interning API 2014-07-07 13:56:38 -07:00
help.c t0006: skip "far in the future" test when unsigned long is not long enough 2016-07-15 09:05:53 -07:00
help.h help: add help_unknown_ref() 2013-05-08 15:31:54 -07:00
hex.c Merge branch 'rs/hex2chr' into maint 2016-09-19 13:51:43 -07:00
http-backend.c Merge branch 'ew/http-backend-batch-headers' 2016-08-12 09:47:38 -07:00
http-fetch.c common-main: call git_setup_gettext() 2016-07-01 15:09:10 -07:00
http-push.c Merge branch 'jk/common-main' into maint 2016-09-08 21:35:51 -07:00
http-walker.c http-walker: reduce O(n) ops with doubly-linked list 2016-07-12 15:17:42 -07:00
http.c Merge branch 'ew/http-do-not-forget-to-call-curl-multi-remove-handle' into maint 2016-09-29 16:49:39 -07:00
http.h Merge branch 'ep/http-curl-trace' 2016-07-06 13:38:06 -07:00
ident.c Merge branch 'jk/ident-ai-canonname-could-be-null' into maint 2016-10-03 13:22:32 -07:00
imap-send.c die("bug"): report bugs consistently 2016-07-26 11:13:44 -07:00
INSTALL git-imap-send: use libcurl for implementation 2014-11-10 09:17:27 -08:00
iterator.h refs: introduce an iterator interface 2016-06-20 11:38:20 -07:00
khash.h convert trivial cases to ALLOC_ARRAY 2016-02-22 14:51:09 -08:00
kwset.c kwset: use unsigned char to store values with high-bit set 2015-03-02 12:32:24 -08:00
kwset.h kwset: use unsigned char to store values with high-bit set 2015-03-02 12:32:24 -08:00
levenshtein.c convert trivial cases to ALLOC_ARRAY 2016-02-22 14:51:09 -08:00
levenshtein.h Typofixes outside documentation area 2010-02-03 21:28:17 -08:00
LGPL-2.1 provide a copy of the LGPLv2.1 2011-05-19 18:23:17 -07:00
line-log.c Merge branch 'bc/cocci' 2016-07-19 13:22:16 -07:00
line-log.h line-log.c: make line_log_data_init() static 2015-01-15 11:05:47 -08:00
line-range.c line-range: reject -L line numbers less than 1 2013-08-06 14:48:55 -07:00
line-range.h line-range: teach -L/RE/ to search relative to anchor point 2013-08-06 14:36:34 -07:00
list-objects.c struct name_entry: use struct object_id instead of unsigned char sha1[20] 2016-04-25 14:23:42 -07:00
list-objects.h list-objects: pass full pathname to callbacks 2016-03-16 10:41:04 -07:00
list.h list: avoid incompatibility with *BSD sys/queue.h 2016-07-18 11:06:51 -07:00
ll-merge.c Merge branch 'jc/ll-merge-internal' 2016-05-17 14:38:32 -07:00
ll-merge.h merge-recursive --patience 2010-08-26 09:20:03 -07:00
lockfile.c lockfile: improve error message when lockfile exists 2016-03-01 10:16:46 -08:00
lockfile.h mingw: ensure temporary file handles are not inherited by child processes 2016-08-23 09:09:55 -07:00
log-tree.c graph: add support for --line-prefix on all graph-aware output 2016-08-31 18:07:09 -07:00
log-tree.h Merge branch 'jn/parse-config-slot' 2014-10-20 12:23:48 -07:00
mailinfo.c Merge branch 'kd/mailinfo-quoted-string' 2016-10-03 13:30:38 -07:00
mailinfo.h mailinfo: handle in-body header continuations 2016-09-21 10:23:11 -07:00
mailmap.c Merge branch 'nd/error-errno' 2016-05-17 14:38:28 -07:00
mailmap.h mailmap: simplify map_user() interface 2013-01-10 12:33:08 -08:00
Makefile tmp-objdir: introduce API for temporary object directories 2016-10-10 13:54:02 -07:00
match-trees.c match-trees: convert several leaf functions to use struct object_id 2016-04-25 14:26:29 -07:00
merge-blobs.c Merge branch 'jk/no-diff-emit-common' into maint 2016-03-10 11:13:42 -08:00
merge-blobs.h Which merge_file() function do you mean? 2012-12-09 23:05:27 -08:00
merge-recursive.c Merge branch 'rs/cocci' 2016-09-26 16:09:14 -07:00
merge-recursive.h merge-recursive: offer an option to retain the output in 'obuf' 2016-08-01 11:45:30 -07:00
merge.c sequencer: lib'ify checkout_fast_forward() 2016-09-09 11:24:52 -07:00
mergesort.c mergesort: rename it to llist_mergesort() 2012-04-17 11:07:01 -07:00
mergesort.h mergesort: rename it to llist_mergesort() 2012-04-17 11:07:01 -07:00
mru.c add generic most-recently-used list 2016-07-29 11:05:07 -07:00
mru.h add generic most-recently-used list 2016-07-29 11:05:07 -07:00
name-hash.c convert trivial cases to FLEX_ARRAY macros 2016-02-22 14:51:09 -08:00
notes-cache.c notes: allow treeish expressions as notes ref 2016-01-12 15:10:01 -08:00
notes-cache.h introduce notes-cache interface 2010-04-01 23:58:30 -07:00
notes-merge.c Merge branch 'va/i18n-more' 2016-09-26 16:09:18 -07:00
notes-merge.h notes: extract enum notes_merge_strategy to notes-utils.h 2015-08-17 15:36:23 -07:00
notes-utils.c notes: allow treeish expressions as notes ref 2016-01-12 15:10:01 -08:00
notes-utils.h notes: extract parse_notes_merge_strategy to notes-utils 2015-08-17 15:38:32 -07:00
notes.c notes: convert init_notes to use struct object_id 2016-09-07 12:59:42 -07:00
notes.h Merge branch 'jk/notes-merge-from-anywhere' 2016-02-03 14:15:59 -08:00
object.c Remove get_object_hash. 2015-11-20 08:02:05 -05:00
object.h Remove get_object_hash. 2015-11-20 08:02:05 -05:00
pack-bitmap-write.c Merge branch 'jk/path-name-safety-2.6' into jk/path-name-safety-2.7 2016-03-16 10:42:32 -07:00
pack-bitmap.c Merge branch 'jk/path-name-safety-2.6' into jk/path-name-safety-2.7 2016-03-16 10:42:32 -07:00
pack-bitmap.h pack-bitmap.c: make pack_bitmap_filename() static 2015-01-15 11:04:10 -08:00
pack-check.c Merge branch 'jk/verify-packfile-gently' 2016-09-29 16:57:13 -07:00
pack-objects.c use REALLOC_ARRAY for changing the allocation size of arrays 2014-09-18 09:13:42 -07:00
pack-objects.h pack-objects: implement bitmap writing 2013-12-30 12:19:22 -08:00
pack-revindex.c use COPY_ARRAY 2016-09-25 16:44:13 -07:00
pack-revindex.h pack-revindex: store entries directly in packed_git 2015-12-21 14:36:28 -08:00
pack-write.c sha1_file: drop free_pack_by_name 2016-07-29 11:05:06 -07:00
pack.h fsck: use streaming interface for large blobs in pack 2016-07-13 09:15:29 -07:00
pager.c Merge branch 'jk/setup-sequence-update' 2016-09-21 15:15:24 -07:00
parse-options-cb.c Merge branch 'mh/diff-indent-heuristic' 2016-09-26 16:09:16 -07:00
parse-options.c parse-options.c: make OPTION_COUNTUP respect "unspecified" values 2016-05-05 11:52:45 -07:00
parse-options.h Merge branch 'mh/diff-indent-heuristic' 2016-09-26 16:09:16 -07:00
patch-delta.c compat: helper for detecting unsigned overflow 2011-02-10 13:47:56 -08:00
patch-ids.c patch-ids: refuse to compute patch-id for merge commit 2016-09-12 13:45:01 -07:00
patch-ids.h rebase: avoid computing unnecessary patch IDs 2016-08-11 14:39:16 -07:00
path.c Merge branch 'jk/diff-submodule-diff-inline' 2016-09-12 15:34:31 -07:00
pathspec.c use COPY_ARRAY 2016-09-25 16:44:13 -07:00
pathspec.h Merge branch 'bw/pathspec-remove-unused-extern-decl' 2016-09-21 15:15:22 -07:00
pkt-line.c introduce hex2chr() for converting two hexadecimal digits to a character 2016-09-07 10:42:46 -07:00
pkt-line.h comments: fix misuses of "nor" 2014-03-31 15:29:27 -07:00
preload-index.c cache.h: rename cache_def_free to cache_def_clear 2014-07-13 10:12:37 -07:00
pretty.c Merge branch 'rs/c-auto-resets-attributes' 2016-09-26 16:09:15 -07:00
prio-queue.c prio-queue: make output stable with respect to insertion 2014-07-15 11:02:54 -07:00
prio-queue.h prio-queue: make output stable with respect to insertion 2014-07-15 11:02:54 -07:00
progress.c use xmallocz to avoid size arithmetic 2016-02-22 14:51:09 -08:00
progress.h nicer display of thin pack completion 2007-11-08 15:43:41 -08:00
prompt.c prompt.c: remove git_getpass() nobody uses 2015-01-15 11:02:06 -08:00
prompt.h prompt.c: remove git_getpass() nobody uses 2015-01-15 11:02:06 -08:00
quote.c Merge branch 'nd/icase' into maint 2016-07-28 11:26:03 -07:00
quote.h Merge branch 'nd/icase' into maint 2016-07-28 11:26:03 -07:00
reachable.c reachable.c: use error_errno() 2016-05-09 12:29:08 -07:00
reachable.h pack-objects: match prune logic for discarding objects 2014-10-16 10:10:43 -07:00
read-cache.c Merge branch 'tg/add-chmod+x-fix' into maint 2016-09-29 16:49:47 -07:00
README.md README.md: format CLI commands with code syntax 2016-05-31 08:54:24 -07:00
ref-filter.c introduce hex2chr() for converting two hexadecimal digits to a character 2016-09-07 10:42:46 -07:00
ref-filter.h branch.c: use 'ref-filter' APIs 2015-09-25 08:54:54 -07:00
reflog-walk.c reflog: continue walking the reflog past root commits 2016-06-06 15:06:44 -07:00
reflog-walk.h convert "enum date_mode" into a struct 2015-06-29 11:39:07 -07:00
refs.c Merge branch 'bc/object-id' 2016-09-19 13:47:19 -07:00
refs.h Merge branch 'bc/object-id' 2016-09-19 13:47:19 -07:00
RelNotes Start preparing for 2.10.1 2016-09-19 13:54:50 -07:00
remote-curl.c Merge branch 'jk/common-main-2.8' into jk/common-main 2016-07-06 10:02:57 -07:00
remote-testsvn.c common-main: call git_extract_argv0_path() 2016-07-01 15:09:10 -07:00
remote.c use strbuf_addstr() for adding constant strings to a strbuf, part 2 2016-09-15 12:23:38 -07:00
remote.h Merge branch 'jk/push-force-with-lease-creation' 2016-08-10 12:33:18 -07:00
replace_object.c register_replace_ref(): rewrite to take an object_id argument 2015-05-25 12:19:35 -07:00
rerere.c cache: convert struct cache_entry to use struct object_id 2016-09-07 12:59:42 -07:00
rerere.h Merge branch 'jc/rerere-multi' 2016-04-25 15:17:15 -07:00
resolve-undo.c cache: convert struct cache_entry to use struct object_id 2016-09-07 12:59:42 -07:00
resolve-undo.h convert unmerge_cache to take struct pathspec 2013-07-15 10:56:08 -07:00
revision.c cache: convert struct cache_entry to use struct object_id 2016-09-07 12:59:42 -07:00
revision.h Merge branch 'lt/pretty-expand-tabs' 2016-04-13 14:12:36 -07:00
run-command.c Merge branch 'ab/hooks' 2016-08-19 15:34:16 -07:00
run-command.h run-command: add pipe_command helper 2016-06-17 17:03:56 -07:00
send-pack.c Merge branch 'rs/use-strbuf-addstr' into maint 2016-08-10 11:55:34 -07:00
send-pack.h push: accept push options 2016-07-14 15:50:41 -07:00
sequencer.c sequencer: ensure to release the lock when we could not read the index 2016-09-09 11:24:52 -07:00
sequencer.h Merge branch 'jc/conflict-hint' into cc/interpret-trailers-more 2014-11-10 09:56:39 -08:00
server-info.c server-info.c: use error_errno() 2016-05-09 12:29:08 -07:00
setup.c i18n: setup: mark error messages for translation 2016-08-09 12:44:59 -07:00
sh-i18n--envsubst.c add an extra level of indirection to main() 2016-07-01 15:09:10 -07:00
sha1_file.c alternates: accept double-quoted paths 2016-12-12 15:10:43 -08:00
sha1_name.c alternates: store scratch buffer as strbuf 2016-10-10 13:52:36 -07:00
sha1-array.c sha1-array.c: mark a private file-scope symbol as static 2012-09-15 22:58:21 -07:00
sha1-array.h sha1-array.c: mark a private file-scope symbol as static 2012-09-15 22:58:21 -07:00
sha1-lookup.c sha1-lookup: handle duplicates in sha1_pos() 2014-10-01 13:32:19 -07:00
sha1-lookup.h sha1-lookup: add new "sha1_pos" function to efficiently lookup sha1 2009-04-04 22:57:39 -07:00
shallow.c pass constants as first argument to st_mult() 2016-08-01 14:01:03 -07:00
shell.c common-main: call git_setup_gettext() 2016-07-01 15:09:10 -07:00
shortlog.h shortlog: support outputting to streams other than stdout 2016-06-24 14:25:49 -07:00
show-index.c common-main: call git_setup_gettext() 2016-07-01 15:09:10 -07:00
sideband.c Merge branch 'lf/recv-sideband-cleanup' into maint 2016-08-08 14:21:41 -07:00
sideband.h sideband.c: make send_sideband() return void 2016-06-16 11:40:19 -07:00
sigchain.c sigchain: add command to pop all common signals 2015-12-16 12:06:08 -08:00
sigchain.h sigchain: add command to pop all common signals 2015-12-16 12:06:08 -08:00
split-index.c use COPY_ARRAY 2016-09-25 16:44:13 -07:00
split-index.h split-index: the reading part 2014-06-13 11:49:40 -07:00
strbuf.c link_alt_odb_entry: handle normalize_path errors 2016-10-10 13:52:36 -07:00
strbuf.h link_alt_odb_entry: handle normalize_path errors 2016-10-10 13:52:36 -07:00
streaming.c Merge branch 'jc/verify-loose-object-header' 2016-10-03 13:30:36 -07:00
streaming.h streaming: make stream_blob_to_fd take struct object_id 2016-09-07 12:59:42 -07:00
string-list.c string_list: use string-list API in unsorted_string_list_lookup() 2016-04-25 11:48:27 -07:00
string-list.h Merge branch 'sb/string-list' 2014-12-22 12:27:30 -08:00
submodule-config.c Merge branch 'sb/submodule-update-dot-branch' 2016-08-10 12:33:20 -07:00
submodule-config.h submodule-config: keep configured branch around 2016-08-01 14:42:07 -07:00
submodule.c alternates: provide helper for adding to alternates list 2016-10-10 13:52:36 -07:00
submodule.h diff: teach diff to display submodule difference with an inline diff 2016-08-31 18:07:10 -07:00
symlinks.c symlinks: remove PATH_MAX limitation 2014-07-07 11:22:42 -07:00
tag.c verify-tag: move tag verification code to tag.c 2016-04-22 14:06:46 -07:00
tag.h verify-tag: move tag verification code to tag.c 2016-04-22 14:06:46 -07:00
tar.h tar-tree: Introduce write_entry() 2006-03-25 16:35:43 -08:00
tempfile.c mingw: ensure temporary file handles are not inherited by child processes 2016-08-23 09:09:55 -07:00
tempfile.h mingw: ensure temporary file handles are not inherited by child processes 2016-08-23 09:09:55 -07:00
thread-utils.c thread-utils.c: detect CPU count on older BSD-like systems 2015-03-10 15:13:28 -07:00
thread-utils.h pack-objects: set number of threads before checking and warning 2014-10-13 12:53:46 -07:00
tmp-objdir.c tmp-objdir: do not migrate files starting with '.' 2016-10-10 13:54:02 -07:00
tmp-objdir.h tmp-objdir: introduce API for temporary object directories 2016-10-10 13:54:02 -07:00
trace.c trace: do not fall back to stderr 2016-08-05 09:28:17 -07:00
trace.h pkt-line: support tracing verbatim pack contents 2015-06-16 13:24:22 -07:00
trailer.c die("bug"): report bugs consistently 2016-07-26 11:13:44 -07:00
trailer.h interpret-trailers: add option for in-place editing 2016-01-14 12:22:17 -08:00
transport-helper.c Spelling fixes 2016-08-11 14:35:42 -07:00
transport.c alternates: use a separate scratch space 2016-10-10 13:52:36 -07:00
transport.h push: accept push options 2016-07-14 15:50:41 -07:00
tree-diff.c Merge branch 'jk/avoid-unbounded-alloca' into maint 2016-07-06 13:06:39 -07:00
tree-walk.c fsck: handle bad trees like other errors 2016-09-27 14:09:10 -07:00
tree-walk.h fsck: handle bad trees like other errors 2016-09-27 14:09:10 -07:00
tree.c cache: convert struct cache_entry to use struct object_id 2016-09-07 12:59:42 -07:00
tree.h Merge branch 'jk/squelch-missing-link-warning-for-unreachable' into maint 2015-06-25 11:02:10 -07:00
unicode_width.h Update of unicode_width.h to Unicode Version 7.0 2014-06-18 10:53:45 -07:00
unimplemented.sh unimplemented.sh: use the $( ... ) construct for command substitution 2015-12-27 15:33:13 -08:00
unix-socket.c Merge branch 'rs/strbuf-getcwd' 2014-09-02 13:28:44 -07:00
unix-socket.h credentials: add "cache" helper 2011-12-11 23:16:25 -08:00
unpack-trees.c Merge branch 'rs/unpack-trees-reduce-file-scope-global' into maint 2016-09-29 16:49:36 -07:00
unpack-trees.h diff-lib, read-tree, unpack-trees: mark cache_entry array paramters const 2013-06-02 15:31:14 -07:00
update_unicode.sh update_unicode.sh: delete the command group 2014-12-22 10:03:37 -08:00
upload-pack.c Merge branch 'jk/common-main' into maint 2016-09-08 21:35:51 -07:00
url.c introduce hex2chr() for converting two hexadecimal digits to a character 2016-09-07 10:42:46 -07:00
url.h url: decode buffers that are not NUL-terminated 2011-07-20 11:38:34 -07:00
urlmatch.c urlmatch.c: make match_urls() static 2015-01-15 11:05:48 -08:00
urlmatch.h urlmatch.c: make match_urls() static 2015-01-15 11:05:48 -08:00
usage.c Merge branch 'cc/apply-am' 2016-09-19 13:47:18 -07:00
userdiff.c userdiff: add built-in pattern for CSS 2016-06-03 14:45:56 -07:00
userdiff.h diff: clarify textconv interface 2016-02-22 10:40:35 -08:00
utf8.c utf8: add function to align a string into given strbuf 2015-09-17 10:02:48 -07:00
utf8.h typofix: assorted typofixes in comments, documentation and messages 2016-05-06 13:16:37 -07:00
varint.c cleanups: ensure that git-compat-util.h is included first 2014-09-15 12:05:14 -07:00
varint.h cleanups: ensure that git-compat-util.h is included first 2014-09-15 12:05:14 -07:00
version.c include agent identifier in capability string 2012-08-03 13:03:34 -07:00
version.h include agent identifier in capability string 2012-08-03 13:03:34 -07:00
versioncmp.c versionsort: support reorder prerelease suffixes 2015-02-27 13:38:22 -08:00
walker.c walker: let walker_say take arbitrary formats 2016-07-08 10:11:23 -07:00
walker.h walker: let walker_say take arbitrary formats 2016-07-08 10:11:23 -07:00
wildmatch.c typofix: assorted typofixes in comments, documentation and messages 2016-05-06 13:16:37 -07:00
wildmatch.h wildmatch: support "no FNM_PATHNAME" mode 2013-01-01 15:32:37 -08:00
worktree.c Merge branch 'nd/worktree-lock' 2016-07-28 10:34:42 -07:00
worktree.h worktree.c: add is_worktree_locked() 2016-06-13 11:53:14 -07:00
wrap-for-bin.sh wrap-for-bin.sh: regenerate bin-wrappers when switching branches 2016-05-10 13:23:34 -07:00
wrapper.c Merge branch 'sb/submodule-parallel-fetch' into maint 2016-07-28 11:26:02 -07:00
write_or_die.c write_or_die: drop write_or_whine_pipe() 2016-08-05 09:28:17 -07:00
ws.c use strchrnul() in place of strchr() and strlen() 2014-03-10 08:35:30 -07:00
wt-status.c Merge branch 'rs/cocci' 2016-09-26 16:09:14 -07:00
wt-status.h status: print branch info with --porcelain=v2 --branch 2016-08-11 11:15:40 -07:00
xdiff-interface.c Merge branch 'js/regexec-buf' into maint 2016-09-29 16:49:45 -07:00
xdiff-interface.h Convert read_mmblob to take struct object_id. 2016-09-07 12:59:42 -07:00
zlib.c zlib: initialize git_zstream in git_deflate_init{,_gzip,_raw} 2015-03-05 15:46:03 -08:00

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 http://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-.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 http://news.gmane.org/gmane.comp.version-control.git/, http://marc.info/?l=git and other archival sites.

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