aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
5 days[DO-NOT-MERGE] all: add task to build doc and fake packageHEADmainShulhan
The fake package allow any dependencies to use local version instead of the official one.
6 days[DO-NO-MERGE] Add local MakefileShulhan
I always forgot how to build and install it on my local.
6 daysgitk-git: move the Find and Commit bars to the topShulhan
The functionality that provides by Find bar and information provides by Commit bar is for the commit tree. For example, if we Find commit that containing "xyz", it will search and highlight the commit subject line that contain the word "xyz". If we click on any commit subject, it will changes the Commit hash and Row. So, in this changes, it make senses that we position both of bars at the top instead of in the middle.
6 daysgit-gui: add shortcut for visualize current branch and all branchShulhan
The shortcut for visualizing current branch is CTRL+H (H derived from [H]istory). The shortcut for visualizing all branch is CTRL+K.
6 daysgitk-git: add option to remove indentation on the commit commentShulhan
Indentation make us hard to copy-paste the content of commit comment from gitk to other medium, especially when creating change log. The "git log --pretty=raw" command does not have option to re-format the pretty output again, so the only way to remove indentation is by trimming left space line by line. This changes add option "Remove indentation on comment" under "General" option in Preference. If its checked the comment will rendered without left space; otherwise it will displayed as usual.
6 daysgitk-git: add alternative shortcuts to update and reload commitsShulhan
Add CTRL+r to update commits and Shift+R to reload commits.
6 daysA bit more post -rc1Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
6 daysrun_processes_parallel(): fix order of sigpipe handlingJeff King
In commit ec0becacc9 (run-command: add stdin callback for parallelization, 2026-01-28), we taught run_processes_parallel() to ignore SIGPIPE, since we wouldn't want a write() to a broken pipe of one of the children to take down the whole process. But there's a subtle ordering issue. After we ignore SIGPIPE, we call pp_init(), which installs its own cleanup handler for multiple signals using sigchain_push_common(), which includes SIGPIPE. So if we receive SIGPIPE while writing to a child, we'll trigger that handler first, pop it off the stack, and then re-raise (which is then ignored because of the SIG_IGN we pushed first). But what does that handler do? It tries to clean up all of the child processes, under the assumption that when we re-raise the signal we'll be exiting the process! So a hook that exits without reading all of its input will cause us to get SIGPIPE, which will put us in a signal handler that then tries to kill() that same child. This seems to be mostly harmless on Linux. The process has already exited by this point, and though kill() does not complain (since the process has not been reaped with a wait() call), it does not affect the exit status of the process. However, this seems not to be true on all platforms. This case is triggered by t5401.13, "pre-receive hook that forgets to read its input". This test fails on NonStop since that hook was converted to the run_processes_parallel() API. We can fix it by reordering the code a bit. We should run pp_init() first, and then push our SIG_IGN onto the stack afterwards, so that it is truly ignored while feeding the sub-processes. Note that we also reorder the popping at the end of the function, too. This is not technically necessary, as we are doing two pops either way, but now the pops will correctly match their pushes. This also fixes a related case that we can't test yet. If we did have more than one process to run, then one child causing SIGPIPE would cause us to kill() all of the children (which might still actually be running). But the hook API is the only user of the new feed_pipe feature, and it does not yet support parallel hook execution. So for now we'll always execute the processes sequentially. Once parallel hook execution exists, we'll be able to add a test which covers this. Reported-by: Randall S. Becker <rsbecker@nexbridge.com> Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
6 daysMerge branch 'jt/index-fd-wo-repo-regression-fix'Junio C Hamano
During Git 2.52 timeframe, we broke streaming computation of object hash outside a repository, which has been corrected. * jt/index-fd-wo-repo-regression-fix:
6 daysMerge branch 'jt/index-fd-wo-repo-regression-fix-maint'Junio C Hamano
During Git 2.52 timeframe, we broke streaming computation of object hash outside a repository, which has been corrected. * jt/index-fd-wo-repo-regression-fix-maint: object-file: avoid ODB transaction when not writing objects
6 daysMerge branch 'tc/replay-ref'Junio C Hamano
The experimental `git replay` command learned the `--ref=<ref>` option to allow specifying which ref to update, overriding the default behavior. * tc/replay-ref: replay: allow to specify a ref with option --ref replay: use stuck form in documentation and help message builtin/replay: mark options as not negatable
6 daysMerge branch 'ng/add-files-to-cache-wo-rename'Junio C Hamano
add_files_to_cache() used diff_files() to detect only the paths that are different between the index and the working tree and add them, which does not need rename detection, which interfered with unnecessary conflicts. * ng/add-files-to-cache-wo-rename: read-cache: disable renames in add_files_to_cache
6 daysMerge branch 'ps/reftable-portability'Junio C Hamano
Update reftable library part with what is used in libgit2 to improve portability to different target codebases and platforms. * ps/reftable-portability: reftable/system: add abstraction to mmap files reftable/system: add abstraction to retrieve time in milliseconds reftable/fsck: use REFTABLE_UNUSED instead of UNUSED reftable/stack: provide fsync(3p) via system header reftable: introduce "reftable-system.h" header
6 daysMerge branch 'jd/cache-tree-trace-wo-the-repository'Junio C Hamano
Code cleanup. * jd/cache-tree-trace-wo-the-repository: cache-tree: use index state repository in trace2 calls
6 daysMerge branch 'ps/odb-cleanup'Junio C Hamano
Various code clean-up around odb subsystem. * ps/odb-cleanup: odb: drop unneeded headers and forward decls odb: rename `odb_has_object()` flags odb: use enum for `odb_write_object` flags odb: rename `odb_write_object()` flags treewide: use enum for `odb_for_each_object()` flags CodingGuidelines: document our style for flags
6 daysMerge branch 'ss/t7004-unhide-git-failures'Junio C Hamano
Test clean-up. * ss/t7004-unhide-git-failures: t7004: replace wc -l with modern test helpers
6 dayst1800: add &&-chains to test helper functionsAdrian Ratiu
Add the missing &&'s so we properly propagate failures between commands in the hook helper functions. Also add a missing mkdir -p arg (found by adding the &&). Reported-by: SZEDER Gábor <szeder.dev@gmail.com> Signed-off-by: Adrian Ratiu <adrian.ratiu@collabora.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
6 daysGit 2.54-rc1v2.54.0-rc1Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
7 daysMerge branch 'jt/index-fd-wo-repo-regression-fix-maint' into HEADJunio C Hamano
* jt/index-fd-wo-repo-regression-fix-maint: object-file: avoid ODB transaction when not writing objects
7 daysobject-file: avoid ODB transaction when not writing objectsJustin Tobler
In ce1661f9da (odb: add transaction interface, 2025-09-16), existing ODB transaction logic is adapted to create a transaction interface at the ODB layer. The intent here is for the ODB transaction interface to eventually provide an object source agnostic means to manage transactions. An unintended consequence of this change though is that `object-file.c:index_fd()` may enter the ODB transaction path even when no object write is requested. In non-repository contexts, this can result in a NULL dereference and segfault. One such case occurs when running git-diff(1) outside of a repository with "core.bigFileThreshold" forcing the streaming path in `index_fd()`: $ echo foo >foo $ echo bar >bar $ git -c core.bigFileThreshold=1 diff -- foo bar In this scenario, the caller only needs to compute the object ID. Object hashing does not require an ODB, so starting a transaction is both unnecessary and invalid. Fix the bug by avoiding the use of ODB transactions in `index_fd()` when callers are only interested in computing the object hash. Reported-by: Luca Stefani <luca.stefani.ge1@gmail.com> Signed-off-by: Justin Tobler <jltobler@gmail.com> [jc: adjusted to fd13909e (Merge branch 'jt/odb-transaction', 2025-10-02)] Signed-off-by: Junio C Hamano <gitster@pobox.com>
7 daysA bit more before -rc1Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
7 daysMerge branch 'rs/history-short-help-fix'Junio C Hamano
Glitches in "git history -h" have been corrected. * rs/history-short-help-fix: history: fix short help for argument of --update-refs
7 daysMerge branch 'th/backfill-auto-detect-sparseness-fix'Junio C Hamano
"git backfill" is capable of auto-detecting a sparsely checked out working tree, which was broken. * th/backfill-auto-detect-sparseness-fix: backfill: auto-detect sparse-checkout from config
7 daysMerge branch 'ps/receive-pack-updateinstead-in-worktree'Junio C Hamano
The check in "receive-pack" to prevent a checked out branch from getting updated via updateInstead mechanism has been corrected. * ps/receive-pack-updateinstead-in-worktree: receive-pack: use worktree HEAD for updateInstead t5516: clean up cloned and new-wt in denyCurrentBranch and worktrees test t5516: test updateInstead with worktree and unborn bare HEAD
7 daysMerge branch 'jt/fast-import-signed-modes'Junio C Hamano
Handling of signed commits and tags in fast-import has been made more configurable. * jt/fast-import-signed-modes: fast-import: add 'abort-if-invalid' mode to '--signed-tags=<mode>' fast-import: add 'sign-if-invalid' mode to '--signed-tags=<mode>' fast-import: add 'strip-if-invalid' mode to '--signed-tags=<mode>' fast-import: add 'abort-if-invalid' mode to '--signed-commits=<mode>' fast-export: check for unsupported signing modes earlier
7 daysMerge branch 'mm/line-log-use-standard-diff-output'Junio C Hamano
The way the "git log -L<range>:<file>" feature is bolted onto the log/diff machinery is being reworked a bit to make the feature compatible with more diff options, like -S/G. * mm/line-log-use-standard-diff-output: doc: note that -L supports patch formatting and pickaxe options t4211: add tests for -L with standard diff options line-log: route -L output through the standard diff pipeline line-log: fix crash when combined with pickaxe options
7 daysMerge branch 'sp/add-patch-with-fewer-the-repository'Junio C Hamano
Reduce dependency on `the_repository` in add-patch.c file. * sp/add-patch-with-fewer-the-repository: add-patch: use repository instance from add_i_state instead of the_repository
7 daysMerge branch 'ps/fsck-wo-the-repository'Junio C Hamano
Internals of "git fsck" have been refactored to not depend on the global `the_repository` variable. * ps/fsck-wo-the-repository: builtin/fsck: stop using `the_repository` in error reporting builtin/fsck: stop using `the_repository` when marking objects builtin/fsck: stop using `the_repository` when checking packed objects builtin/fsck: stop using `the_repository` with loose objects builtin/fsck: stop using `the_repository` when checking reflogs builtin/fsck: stop using `the_repository` when checking refs builtin/fsck: stop using `the_repository` when snapshotting refs builtin/fsck: fix trivial dependence on `the_repository` fsck: drop USE_THE_REPOSITORY fsck: store repository in fsck options fsck: initialize fsck options via a function fetch-pack: move fsck options into function scope
7 daysMerge branch 'yc/path-walk-fix-error-reporting'Junio C Hamano
The value of a wrong pointer variable was referenced in an error message that reported that it shouldn't be NULL. * yc/path-walk-fix-error-reporting: path-walk: fix NULL pointer dereference in error message
7 daysMerge branch 'jc/whitespace-incomplete-line'Junio C Hamano
Fix whitespace correction for new-style empty context lines. * jc/whitespace-incomplete-line: apply: fix new-style empty context line triggering incomplete-line check
7 daysMerge branch 'ps/commit-graph-overflow-fix'Junio C Hamano
Fix a regression in writing the commit-graph where commits with dates exceeding 34 bits (beyond year 2514) could cause an underflow and crash Git during the generation data overflow chunk writing. * ps/commit-graph-overflow-fix: commit-graph: fix writing generations with dates exceeding 34 bits
7 daysMerge branch 'jd/read-cache-trace-wo-the-repository'Junio C Hamano
A handful of inappropriate uses of the_repository have been rewritten to use the right repository structure instance in the read-cache.c codepath. * jd/read-cache-trace-wo-the-repository: read-cache: use istate->repo for trace2 logging
8 daysA handful before -rc1Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 daysMerge branch 'jk/c23-const-preserving-fixes'Junio C Hamano
Adjust the codebase for C23 that changes functions like strchr() that discarded constness when they return a pointer into a const string to preserve constness. * jk/c23-const-preserving-fixes: config: store allocated string in non-const pointer rev-parse: avoid writing to const string for parent marks revision: avoid writing to const string for parent marks rev-parse: simplify dotdot parsing revision: make handle_dotdot() interface less confusing
8 daysMerge branch 'aa/reap-transport-child-processes'Junio C Hamano
A few code paths that spawned child processes for network connection weren't wait(2)ing for their children and letting "init" reap them instead; they have been tightened. * aa/reap-transport-child-processes: transport-helper, connect: use clean_on_exit to reap children on abnormal exit
8 daysMerge branch 'qb/doc-git-stash-push-optionality'Junio C Hamano
Doc update. * qb/doc-git-stash-push-optionality: docs: fix "git stash [push]" documentation
8 daysMerge branch 'sp/doc-gitignore-oowt'Junio C Hamano
Doc update. * sp/doc-gitignore-oowt: doc: gitignore: clarify pattern base for info/exclude and core.excludesFile
8 daysMerge branch 'th/t6101-unhide-git-failures'Junio C Hamano
Test cleanup. * th/t6101-unhide-git-failures: t6101: avoid suppressing git's exit code
8 daysMerge branch 'za/t2000-modernise'Junio C Hamano
Test cleanup. * za/t2000-modernise: t2000: modernise overall structure
8 daysMerge branch 'tc/replay-down-to-root'Junio C Hamano
git replay now supports replaying down to the root commit. * tc/replay-down-to-root: replay: support replaying down from root commit
8 daysMerge branch 'tb/stdin-packs-excluded-but-open'Junio C Hamano
pack-objects's --stdin-packs=follow mode learns to handle excluded-but-open packs. * tb/stdin-packs-excluded-but-open: repack: mark non-MIDX packs above the split as excluded-open pack-objects: support excluded-open packs with --stdin-packs t7704: demonstrate failure with once-cruft objects above the geometric split pack-objects: refactor `read_packs_list_from_stdin()` to use `strmap` pack-objects: plug leak in `read_stdin_packs()`
8 daysMerge branch 'ps/odb-generic-object-name-handling'Junio C Hamano
Object name handling (disambiguation and abbreviation) has been refactored to be backend-generic, moving logic into the respective object database backends. * ps/odb-generic-object-name-handling: odb: introduce generic `odb_find_abbrev_len()` object-file: move logic to compute packed abbreviation length object-name: move logic to compute loose abbreviation length object-name: simplify computing common prefixes object-name: abbreviate loose object names without `disambiguate_state` object-name: merge `update_candidates()` and `match_prefix()` object-name: backend-generic `get_short_oid()` object-name: backend-generic `repo_collect_ambiguous()` object-name: extract function to parse object ID prefixes object-name: move logic to iterate through packed prefixed objects object-name: move logic to iterate through loose prefixed objects odb: introduce `struct odb_for_each_object_options` oidtree: extend iteration to allow for arbitrary return codes oidtree: modernize the code a bit object-file: fix sparse 'plain integer as NULL pointer' error
8 dayshistory: fix short help for argument of --update-refsRené Scharfe
"print" is not a valid argument for --update-refs. List both valid alternatives literally in the argh string, consistent with documentation and usage string. Signed-off-by: René Scharfe <l.s.r@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 dayscompat/winansi: drop pre-Vista workaroundMatthias Aßhauer
1edeb9a (Win32: warn if the console font doesn't support Unicode, 2014-06-10) introduced both code to detect the current console font on Windows Vista and newer and a fallback for older systems to detect the default console font and issue a warning if that font doesn't support unicode. Since we haven't supported any Windows older than Vista in almost a decade, we don't need to keep the workaround. Signed-off-by: Matthias Aßhauer <mha1993@live.de> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 daysunify and bump _WIN32_WINNT definition to Windows 8.1Matthias Aßhauer
Git for Windows doesn't support anything prior to Windows 8.1 since 2.47.0 and Git followed along with commits like ce6ccba (mingw: drop Windows 7-specific work-around, 2025-08-04). There is no need to pretend to the compiler that we still support Windows Vista, just to lock us out of easy access to newer APIs. There is also no need to have conflicting and unused definitions claiming we support some versions of Windows XP or even Windows NT 4.0. Bump all definitions of _WIN32_WINNT to a realistic value of Windows 8.1. This will also simplify code for a followup commit that will improve cpu core detection on multi-socket systems. Signed-off-by: Matthias Aßhauer <mha1993@live.de> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
8 daysbackfill: auto-detect sparse-checkout from configTrieu Huynh
Commit 85127bcdea ("backfill: assume --sparse when sparse-checkout is enabled") intended for 'git backfill' to consult the repository configuration when the user does not pass '--sparse' or '--no-sparse' on the command line. It added the sentinel check: if (ctx->sparse < 0) ctx->sparse = cfg->apply_sparse_checkout; However, the ctx->sparse field is initialized to 0 instead of -1, so this guard never triggers. Consequently, the repository config (core.sparseCheckout) is never checked, and the command always performs a full backfill even when sparse-checkout is enabled. Fix this by initializing ctx->sparse to -1, ensuring the existing fallback logic correctly reads the repository configuration when no explicit flags are provided. Add a test to verify that 'git backfill' automatically respects sparse-checkout settings when no flags are passed. Signed-off-by: Trieu Huynh <vikingtc4@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
11 daysA couple more on top of -rc0Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
11 daysMerge branch 'ps/dash-buggy-0.5.13-workaround'Junio C Hamano
The way dash 0.5.13 handles non-ASCII contents in here-doc is buggy and breaks our existing tests, which unfortunately have been rewritten to avoid triggering the bug. * ps/dash-buggy-0.5.13-workaround: t9300: work around partial read bug in Dash v0.5.13 t: work around multibyte bug in quoted heredocs with Dash v0.5.13
11 daysMerge branch 'js/cmake-needs-writev-compat-too'Junio C Hamano
Build instruction for recently added writev() compatibility wrapper has been also added to cmake. * js/cmake-needs-writev-compat-too: cmake: use writev(3p) wrapper as needed
11 daysMerge branch 'js/mingw-use-strftime-directly-in-ucrt-build'Junio C Hamano
MinGW build updates. * js/mingw-use-strftime-directly-in-ucrt-build: mingw: use strftime() directly in UCRT builds