Go to file
Junio C Hamano 5f212684ab Merge branch 'bf/set-head-symref'
When "git fetch $remote" notices that refs/remotes/$remote/HEAD is
missing and discovers what branch the other side points with its
HEAD, refs/remotes/$remote/HEAD is updated to point to it.

* bf/set-head-symref:
  fetch set_head: handle mirrored bare repositories
  fetch: set remote/HEAD if it does not exist
  refs: add create_only option to refs_update_symref_extended
  refs: add TRANSACTION_CREATE_EXISTS error
  remote set-head: better output for --auto
  remote set-head: refactor for readability
  refs: atomically record overwritten ref in update_symref
  refs: standardize output of refs_read_symbolic_ref
  t/t5505-remote: test failure of set-head
  t/t5505-remote: set default branch to main
2024-12-19 10:58:27 -08:00
.github
Documentation Git 2.48-rc0 2024-12-16 08:54:04 -08:00
bin-wrappers Introduce support for the Meson build system 2024-12-07 07:52:14 +09:00
block-sha1
builtin Merge branch 'bf/set-head-symref' 2024-12-19 10:58:27 -08:00
ci Merge branch 'ps/build' 2024-12-15 17:54:33 -08:00
compat Merge branch 'ak/typofixes' into maint-2.47 2024-11-25 12:29:48 +09:00
contrib Merge branch 'ps/build' 2024-12-15 17:54:33 -08:00
ewah
git-gui
gitk-git Merge https://github.com/j6t/gitk 2024-12-17 16:17:28 -08:00
gitweb Merge branch 'ps/build' 2024-12-15 17:54:33 -08:00
mergetools
negotiator
oss-fuzz
perl Introduce support for the Meson build system 2024-12-07 07:52:14 +09:00
po Introduce support for the Meson build system 2024-12-07 07:52:14 +09:00
refs Merge branch 'bf/set-head-symref' 2024-12-19 10:58:27 -08:00
reftable Merge branch 'ps/reftable-iterator-reuse' 2024-12-10 10:04:58 +09:00
sha1
sha1collisiondetection@855827c583
sha1dc
sha256
subprojects Introduce support for the Meson build system 2024-12-07 07:52:14 +09:00
t Merge branch 'bf/set-head-symref' 2024-12-19 10:58:27 -08:00
templates Introduce support for the Meson build system 2024-12-07 07:52:14 +09:00
trace2
xdiff
.cirrus.yml
.clang-format
.editorconfig
.gitattributes
.gitignore Makefile: allow "bin-wrappers/" directory to exist 2024-12-07 07:52:11 +09:00
.gitlab-ci.yml
.gitmodules
.mailmap
.tsan-suppressions
CODE_OF_CONDUCT.md
COPYING
GIT-BUILD-OPTIONS.in t: better support for out-of-tree builds 2024-12-07 07:52:13 +09:00
GIT-VERSION-FILE.in Makefile: refactor GIT-VERSION-GEN to be reusable 2024-12-07 07:52:08 +09:00
GIT-VERSION-GEN Git 2.48-rc0 2024-12-16 08:54:04 -08:00
INSTALL
LGPL-2.1
Makefile Merge branch 'ps/build' 2024-12-15 17:54:33 -08:00
README.md
RelNotes Prepare for 2.47.1 2024-11-20 14:43:30 +09:00
SECURITY.md
abspath.c
abspath.h
aclocal.m4
add-interactive.c
add-interactive.h
add-patch.c
advice.c advice: suggest using subcommand "git config set" 2024-12-06 11:24:21 +09:00
advice.h
alias.c
alias.h
alloc.c
alloc.h
apply.c
apply.h
archive-tar.c
archive-zip.c
archive.c
archive.h
attr.c
attr.h
banned.h
base85.c
base85.h
bisect.c bisect: address Coverity warning about potential double free 2024-11-26 10:22:24 +09:00
bisect.h bisect: fix leaking good/bad terms when reading multipe times 2024-11-21 08:23:40 +09:00
blame.c builtin/blame: fix leaking blame entries with `--incremental` 2024-11-21 08:23:40 +09:00
blame.h builtin/blame: fix leaking blame entries with `--incremental` 2024-11-21 08:23:40 +09:00
blob.c
blob.h
bloom.c
bloom.h
branch.c Merge branch 'jc/forbid-head-as-tagname' 2024-12-15 17:54:26 -08:00
branch.h
builtin.h
bulk-checkin.c
bulk-checkin.h
bundle-uri.c bundle: add bundle verification options type 2024-11-28 12:07:57 +09:00
bundle-uri.h
bundle.c bundle: support fsck message configuration 2024-11-28 12:07:58 +09:00
bundle.h bundle: support fsck message configuration 2024-11-28 12:07:58 +09:00
cache-tree.c Merge branch 'ps/cache-tree-w-broken-index-entry' into maint-2.47 2024-11-20 14:42:59 +09:00
cache-tree.h
cbtree.c
cbtree.h
chdir-notify.c
chdir-notify.h
check-builtins.sh
checkout.c
checkout.h
chunk-format.c
chunk-format.h
color.c
color.h
column.c
column.h
combine-diff.c
command-list.txt
commit-graph.c packfile: pass down repository to `for_each_packed_object` 2024-12-04 08:21:54 +09:00
commit-graph.h
commit-reach.c
commit-reach.h
commit-slab-decl.h
commit-slab-impl.h
commit-slab.h
commit.c Merge branch 'bf/explicit-config-set-in-advice-messages' 2024-12-15 17:54:28 -08:00
commit.h
common-main.c
config.c config: make `packed_git_(limit|window_size)` non-global variables 2024-12-04 08:21:55 +09:00
config.h
config.mak.dev
config.mak.in
config.mak.uname
configure.ac Makefile: consistently use @PLACEHOLDER@ to substitute 2024-12-07 07:52:08 +09:00
connect.c
connect.h
connected.c packfile: add repository to struct `packed_git` 2024-12-04 08:21:53 +09:00
connected.h
convert.c
convert.h
copy.c
copy.h
credential.c
credential.h
csum-file.c
csum-file.h
ctype.c
daemon.c Merge branch 'bc/allow-upload-pack-from-other-people' 2024-12-10 10:04:55 +09:00
date.c
date.h
decorate.c
decorate.h
delta-islands.c
delta-islands.h
delta.h
detect-compiler
diagnose.c
diagnose.h
diff-delta.c
diff-lib.c Merge branch 'jk/output-prefix-cleanup' into maint-2.47 2024-11-25 12:29:39 +09:00
diff-merges.c
diff-merges.h
diff-no-index.c
diff.c packfile: pass down repository to `has_object[_kept]_pack` 2024-12-04 08:21:54 +09:00
diff.h Merge branch 'jk/output-prefix-cleanup' into maint-2.47 2024-11-25 12:29:39 +09:00
diffcore-break.c
diffcore-delta.c
diffcore-order.c
diffcore-pickaxe.c
diffcore-rename.c
diffcore-rotate.c
diffcore.h
dir-iterator.c
dir-iterator.h
dir.c
dir.h
editor.c
editor.h
entry.c
entry.h
environment.c config: make `packed_git_(limit|window_size)` non-global variables 2024-12-04 08:21:55 +09:00
environment.h config: make `delta_base_cache_limit` a non-global variable 2024-12-04 08:21:55 +09:00
exec-cmd.c
exec-cmd.h
fetch-negotiator.c
fetch-negotiator.h
fetch-pack.c fetch-pack: split out fsck config parsing 2024-11-28 12:07:58 +09:00
fetch-pack.h fetch-pack: split out fsck config parsing 2024-11-28 12:07:58 +09:00
fmt-merge-msg.c
fmt-merge-msg.h
fsck.c packfile: pass down repository to `for_each_packed_object` 2024-12-04 08:21:54 +09:00
fsck.h ref: add symlink ref content check for files backend 2024-11-21 08:21:34 +09:00
fsmonitor--daemon.h
fsmonitor-ipc.c
fsmonitor-ipc.h
fsmonitor-ll.h
fsmonitor-path-utils.h
fsmonitor-settings.c
fsmonitor-settings.h
fsmonitor.c
fsmonitor.h
generate-cmdlist.sh Makefile: refactor generators to be PWD-independent 2024-12-07 07:52:11 +09:00
generate-configlist.sh Makefile: refactor generators to be PWD-independent 2024-12-07 07:52:11 +09:00
generate-hooklist.sh Makefile: refactor generators to be PWD-independent 2024-12-07 07:52:11 +09:00
generate-perl.sh Makefile: use "generate-perl.sh" to massage Perl library 2024-12-07 07:52:10 +09:00
generate-python.sh Makefile: extract script to massage Python scripts 2024-12-07 07:52:10 +09:00
generate-script.sh Makefile: extract script to massage Shell scripts 2024-12-07 07:52:10 +09:00
gettext.c
gettext.h
git-archimport.perl
git-compat-util.h git-compat-util: drop now-unused `UNLEAK()` macro 2024-11-21 08:23:46 +09:00
git-curl-compat.h
git-cvsexportcommit.perl
git-cvsimport.perl
git-cvsserver.perl Makefile: consistently use @PLACEHOLDER@ to substitute 2024-12-07 07:52:08 +09:00
git-difftool--helper.sh git-difftool--helper.sh: exit upon initialize_merge_tool errors 2024-11-25 11:59:19 +09:00
git-filter-branch.sh
git-instaweb.sh Makefile: consistently use PERL_PATH 2024-12-07 07:52:09 +09:00
git-merge-octopus.sh
git-merge-one-file.sh
git-merge-resolve.sh
git-mergetool--lib.sh git-mergetool--lib.sh: add error message for unknown tool variant 2024-11-25 11:59:19 +09:00
git-mergetool.sh
git-p4.py
git-quiltimport.sh
git-request-pull.sh Makefile: consistently use PERL_PATH 2024-12-07 07:52:09 +09:00
git-send-email.perl Makefile: consistently use @PLACEHOLDER@ to substitute 2024-12-07 07:52:08 +09:00
git-sh-i18n.sh Makefile: consistently use @PLACEHOLDER@ to substitute 2024-12-07 07:52:08 +09:00
git-sh-setup.sh Makefile: consistently use @PLACEHOLDER@ to substitute 2024-12-07 07:52:08 +09:00
git-submodule.sh
git-svn.perl Makefile: consistently use @PLACEHOLDER@ to substitute 2024-12-07 07:52:08 +09:00
git-web--browse.sh
git-zlib.c
git-zlib.h
git.c help: fix leaking return value from `help_unknown_cmd()` 2024-11-21 08:23:44 +09:00
git.rc.in Makefile: generate "git.rc" via GIT-VERSION-GEN 2024-12-07 07:52:09 +09:00
gpg-interface.c
gpg-interface.h
graph.c Merge branch 'jk/output-prefix-cleanup' into maint-2.47 2024-11-25 12:29:39 +09:00
graph.h
grep.c
grep.h
hash-lookup.c
hash-lookup.h
hash.h
hashmap.c
hashmap.h
help.c help: fix leaking return value from `help_unknown_cmd()` 2024-11-21 08:23:44 +09:00
help.h help: fix leaking return value from `help_unknown_cmd()` 2024-11-21 08:23:44 +09:00
hex-ll.c
hex-ll.h
hex.c
hex.h
hook.c Merge branch 'bf/explicit-config-set-in-advice-messages' 2024-12-15 17:54:28 -08:00
hook.h
http-backend.c
http-fetch.c
http-push.c
http-walker.c
http.c Merge branch 'kn/midx-wo-the-repository' 2024-12-13 07:33:44 -08:00
http.h
ident.c
ident.h
imap-send.c Merge branch 'bc/drop-ancient-libcurl-and-perl' 2024-12-04 10:14:48 +09:00
iterator.h
json-writer.c
json-writer.h
khash.h
kwset.c
kwset.h
levenshtein.c
levenshtein.h
line-log.c line-log: fix leak when rewriting commit parents 2024-11-21 08:23:42 +09:00
line-log.h
line-range.c
line-range.h
linear-assignment.c
linear-assignment.h
list-objects-filter-options.c
list-objects-filter-options.h
list-objects-filter.c
list-objects-filter.h
list-objects.c packfile: pass down repository to `for_each_packed_object` 2024-12-04 08:21:54 +09:00
list-objects.h
list.h
lockfile.c
lockfile.h
log-tree.c Merge branch 'jk/output-prefix-cleanup' into maint-2.47 2024-11-25 12:29:39 +09:00
log-tree.h
loose.c
loose.h
ls-refs.c
ls-refs.h
mailinfo.c
mailinfo.h
mailmap.c
mailmap.h
match-trees.c
match-trees.h
mem-pool.c
mem-pool.h
merge-blobs.c
merge-blobs.h
merge-ll.c
merge-ll.h
merge-ort-wrappers.c
merge-ort-wrappers.h
merge-ort.c
merge-ort.h
merge-recursive.c
merge-recursive.h
merge.c
merge.h
mergesort.h
meson.build Introduce support for the Meson build system 2024-12-07 07:52:14 +09:00
meson_options.txt Introduce support for the Meson build system 2024-12-07 07:52:14 +09:00
midx-write.c midx: pass down `hash_algo` to functions using global variables 2024-12-04 10:32:21 +09:00
midx.c midx: inline the `MIDX_MIN_SIZE` definition 2024-12-04 10:32:21 +09:00
midx.h midx: pass down `hash_algo` to functions using global variables 2024-12-04 10:32:21 +09:00
name-hash.c
name-hash.h
notes-cache.c
notes-cache.h
notes-merge.c
notes-merge.h
notes-utils.c
notes-utils.h
notes.c
notes.h
object-file-convert.c
object-file-convert.h
object-file.c
object-file.h
object-name.c Merge branch 'ps/commit-with-message-syntax-fix' 2024-12-15 17:54:30 -08:00
object-name.h
object-store-ll.h packfile: pass down repository to `for_each_packed_object` 2024-12-04 08:21:54 +09:00
object-store.h
object.c
object.h
oid-array.c
oid-array.h
oidmap.c
oidmap.h
oidset.c
oidset.h
oidtree.c
oidtree.h
pack-bitmap-write.c
pack-bitmap.c Merge branch 'kn/midx-wo-the-repository' 2024-12-13 07:33:44 -08:00
pack-bitmap.h
pack-check.c
pack-mtimes.c
pack-mtimes.h
pack-objects.c
pack-objects.h config: make `delta_base_cache_limit` a non-global variable 2024-12-04 08:21:55 +09:00
pack-revindex.c midx: pass down `hash_algo` to functions using global variables 2024-12-04 10:32:21 +09:00
pack-revindex.h
pack-write.c config: make `delta_base_cache_limit` a non-global variable 2024-12-04 08:21:55 +09:00
pack.h config: make `delta_base_cache_limit` a non-global variable 2024-12-04 08:21:55 +09:00
packfile.c packfile.c: remove unnecessary prepare_packed_git() call 2024-12-04 08:21:56 +09:00
packfile.h config: make `packed_git_(limit|window_size)` non-global variables 2024-12-04 08:21:55 +09:00
pager.c
pager.h
parallel-checkout.c
parallel-checkout.h
parse-options-cb.c
parse-options.c
parse-options.h builtin: pass repository to sub commands 2024-11-26 10:36:08 +09:00
parse.c
parse.h
patch-delta.c
patch-ids.c
patch-ids.h
path.c Merge branch 'bc/allow-upload-pack-from-other-people' 2024-12-10 10:04:55 +09:00
path.h Merge branch 'bc/allow-upload-pack-from-other-people' 2024-12-10 10:04:55 +09:00
pathspec.c
pathspec.h
pkt-line.c
pkt-line.h
preload-index.c
preload-index.h
pretty.c
pretty.h
prio-queue.c
prio-queue.h
progress.c
progress.h
promisor-remote.c packfile: pass down repository to `for_each_packed_object` 2024-12-04 08:21:54 +09:00
promisor-remote.h
prompt.c
prompt.h
protocol-caps.c
protocol-caps.h
protocol.c
protocol.h
prune-packed.c packfile: pass down repository to `has_object[_kept]_pack` 2024-12-04 08:21:54 +09:00
prune-packed.h
pseudo-merge.c
pseudo-merge.h
quote.c
quote.h
range-diff.c Merge branch 'jk/output-prefix-cleanup' into maint-2.47 2024-11-25 12:29:39 +09:00
range-diff.h
reachable.c packfile: pass down repository to `for_each_packed_object` 2024-12-04 08:21:54 +09:00
reachable.h
read-cache-ll.h
read-cache.c Merge branch 'ps/cache-tree-w-broken-index-entry' into maint-2.47 2024-11-20 14:42:59 +09:00
read-cache.h
rebase-interactive.c
rebase-interactive.h
rebase.c
rebase.h
ref-filter.c
ref-filter.h
reflog-walk.c
reflog-walk.h
reflog.c
reflog.h
refs.c Merge branch 'bf/set-head-symref' 2024-12-19 10:58:27 -08:00
refs.h Merge branch 'bf/set-head-symref' 2024-12-19 10:58:27 -08:00
refspec.c
refspec.h
remote-curl.c
remote.c
remote.h
replace-object.c
replace-object.h
repo-settings.c config: make `packed_git_(limit|window_size)` non-global variables 2024-12-04 08:21:55 +09:00
repo-settings.h config: make `packed_git_(limit|window_size)` non-global variables 2024-12-04 08:21:55 +09:00
repository.c worktree: add `relativeWorktrees` extension 2024-12-02 09:36:16 +09:00
repository.h worktree: add `relativeWorktrees` extension 2024-12-02 09:36:16 +09:00
rerere.c
rerere.h
reset.c
reset.h
resolve-undo.c
resolve-undo.h
revision.c Merge branch 'kn/midx-wo-the-repository' 2024-12-13 07:33:44 -08:00
revision.h
run-command.c
run-command.h
sane-ctype.h
scalar.c
send-pack.c
send-pack.h
sequencer.c Merge branch 'kh/sequencer-comment-char' 2024-12-06 13:23:18 +09:00
sequencer.h
serve.c
serve.h
server-info.c
server-info.h
setup.c worktree: add `relativeWorktrees` extension 2024-12-02 09:36:16 +09:00
setup.h worktree: add `relativeWorktrees` extension 2024-12-02 09:36:16 +09:00
sh-i18n--envsubst.c
sha1dc_git.c
sha1dc_git.h
shallow.c
shallow.h
shared.mak
shell.c
shortlog.h
sideband.c
sideband.h
sigchain.c
sigchain.h
simple-ipc.h
sparse-index.c
sparse-index.h
split-index.c split-index: fix memory leak in `move_cache_to_base_index()` 2024-11-21 08:23:43 +09:00
split-index.h
stable-qsort.c
statinfo.c
statinfo.h
strbuf.c
strbuf.h refs: move ref name helpers around 2024-12-03 12:38:49 +09:00
streaming.c
streaming.h
string-list.c
string-list.h
strmap.c
strmap.h
strvec.c strvec: `strvec_splice()` to a statically initialized vector 2024-12-10 09:07:47 +09:00
strvec.h strvec: introduce new `strvec_splice()` function 2024-11-21 08:23:42 +09:00
sub-process.c
sub-process.h
submodule-config.c
submodule-config.h
submodule.c
submodule.h
symlinks.c
symlinks.h
tag.c packfile: pass down repository to `for_each_packed_object` 2024-12-04 08:21:54 +09:00
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
trace2.h
trailer.c Merge branch 'la/trailer-info' 2024-11-20 14:47:17 +09:00
trailer.h
transport-helper.c
transport-internal.h
transport.c transport: propagate fsck configuration during bundle fetch 2024-11-28 12:07:58 +09:00
transport.h
tree-diff.c
tree-walk.c
tree-walk.h
tree.c
tree.h
unicode-width.h
unimplemented.sh Makefile: consistently use @PLACEHOLDER@ to substitute 2024-12-07 07:52:08 +09:00
unix-socket.c
unix-socket.h
unix-stream-server.c
unix-stream-server.h
unpack-trees.c
unpack-trees.h
upload-pack.c
upload-pack.h
url.c
url.h
urlmatch.c
urlmatch.h
usage.c git-compat-util: drop now-unused `UNLEAK()` macro 2024-11-21 08:23:46 +09:00
userdiff.c
userdiff.h
utf8.c
utf8.h
varint.c
varint.h
version-def.h.in Makefile: propagate Git version via generated header 2024-12-07 07:52:08 +09:00
version.c Makefile: propagate Git version via generated header 2024-12-07 07:52:08 +09:00
version.h
versioncmp.c
versioncmp.h
walker.c refs: allow passing flags when setting up a transaction 2024-11-21 07:59:14 +09:00
walker.h
wildmatch.c
wildmatch.h
worktree.c worktree: refactor `repair_worktree_after_gitdir_move()` 2024-12-02 09:36:18 +09:00
worktree.h worktree: add relative cli/config options to `repair` command 2024-12-02 09:36:17 +09:00
wrapper.c
wrapper.h
write-or-die.c
write-or-die.h
ws.c
ws.h
wt-status.c
wt-status.h
xdiff-interface.c
xdiff-interface.h

README.md

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 and Documentation/CodingGuidelines).

Those wishing to help with error message, usage and informational message string translations (localization l10) should see po/README.md (a po file is a Portable Object file that holds the translations).

To subscribe to the list, send an email to git+subscribe@vger.kernel.org (see https://subspace.kernel.org/subscribing.html for details). The mailing list archives are available at https://lore.kernel.org/git/, https://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