summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2017-10-01update-index: add fsmonitor support to update-indexLibravatar Ben Peart1-1/+32
Add support in update-index to manually add/remove the fsmonitor extension via --[no-]fsmonitor flags. Add support in update-index to manually set/clear the fsmonitor valid bit via --[no-]fsmonitor-valid flags. Signed-off-by: Ben Peart <benpeart@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-10-01ls-files: Add support in ls-files to display the fsmonitor valid bitLibravatar Ben Peart1-2/+6
Add a new command line option (-f) to ls-files to have it use lowercase letters for 'fsmonitor valid' files Signed-off-by: Ben Peart <benpeart@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-10-01fsmonitor: add documentation for the fsmonitor extension.Libravatar Ben Peart5-1/+105
This includes the core.fsmonitor setting, the fsmonitor integration hook, and the fsmonitor index extension. Also add documentation for the new fsmonitor options to ls-files and update-index. Signed-off-by: Ben Peart <benpeart@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-10-01fsmonitor: teach git to optionally utilize a file system monitor to speed up ↵Libravatar Ben Peart16-19/+417
detecting new or changed files. When the index is read from disk, the fsmonitor index extension is used to flag the last known potentially dirty index entries. The registered core.fsmonitor command is called with the time the index was last updated and returns the list of files changed since that time. This list is used to flag any additional dirty cache entries and untracked cache directories. We can then use this valid state to speed up preload_index(), ie_match_stat(), and refresh_cache_ent() as they do not need to lstat() files to detect potential changes for those entries marked CE_FSMONITOR_VALID. In addition, if the untracked cache is turned on valid_cached_dir() can skip checking directories for new or changed files as fsmonitor will invalidate the cache only for those directories that have been identified as having potential changes. To keep the CE_FSMONITOR_VALID state accurate during git operations; when git updates a cache entry to match the current state on disk, it will now set the CE_FSMONITOR_VALID bit. Inversely, anytime git changes a cache entry, the CE_FSMONITOR_VALID bit is cleared and the corresponding untracked cache directory is marked invalid. Signed-off-by: Ben Peart <benpeart@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-09-24update-index: add a new --force-write-index optionLibravatar Ben Peart1-1/+4
At times, it makes sense to avoid the cost of writing out the index when the only changes can easily be recomputed on demand. This causes problems when trying to write test cases to verify that state as they can't guarantee the state has been persisted to disk. Add a new option (--force-write-index) to update-index that will ensure the index is written out even if the cache_changed flag is not set. Signed-off-by: Ben Peart <benpeart@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-09-24preload-index: add override to enable testing preload-indexLibravatar Ben Peart1-0/+2
By default, the preload index code path doesn't run unless there is a minimum of 1000 files. To enable running the test suite and having it execute the preload-index path, add an environment variable (GIT_FORCE_PRELOAD_TEST) which will override that minimum and set it to 2. This enables you run existing tests and have the core.preloadindex code path execute as long as the test has at least 2 files by setting GIT_FORCE_PRELOAD_TEXT=1 before running the test. Signed-off-by: Ben Peart <benpeart@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-09-24bswap: add 64 bit endianness helper get_be64Libravatar Ben Peart1-0/+22
Add a new get_be64 macro to enable 64 bit endian conversions on memory that may or may not be aligned. Signed-off-by: Ben Peart <benpeart@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-09-10Sync with maintLibravatar Junio C Hamano1-0/+59
* maint: RelNotes: further fixes for 2.14.2 from the master front
2017-09-10The seventh batch post 2.14Libravatar Junio C Hamano1-40/+17
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-09-10Merge branch 'rs/apply-epoch'Libravatar Junio C Hamano1-19/+18
Code simplification. * rs/apply-epoch: apply: remove epoch date from regex apply: check date of potential epoch timestamps first
2017-09-10Merge branch 'jk/drop-sha1-entry-pos'Libravatar Junio C Hamano1-6/+0
Code clean-up. * jk/drop-sha1-entry-pos: sha1-lookup: remove sha1_entry_pos() from header file
2017-09-10Merge branch 'nd/worktree-kill-parse-ref'Libravatar Junio C Hamano3-3/+17
"git branch -M a b" while on a branch that is completely unrelated to either branch a or branch b misbehaved when multiple worktree was in use. This has been fixed. * nd/worktree-kill-parse-ref: branch: fix branch renaming not updating HEADs correctly
2017-09-10Merge branch 'mm/send-email-cc-cruft'Libravatar Junio C Hamano2-8/+29
In addition to "cc: <a@dd.re.ss> # cruft", "cc: a@dd.re.ss # cruft" was taught to "git send-email" as a valid way to tell it that it needs to also send a carbon copy to <a@dd.re.ss> in the trailer section. * mm/send-email-cc-cruft: send-email: don't use Mail::Address, even if available send-email: fix garbage removal after address
2017-09-10Merge branch 'ls/convert-filter-progress'Libravatar Junio C Hamano2-2/+15
The codepath to call external process filter for smudge/clean operation learned to show the progress meter. * ls/convert-filter-progress: convert: display progress for filtered objects that have been delayed
2017-09-10Merge branch 'ma/up-to-date'Libravatar Junio C Hamano30-44/+46
Message and doc updates. * ma/up-to-date: treewide: correct several "up-to-date" to "up to date" Documentation/user-manual: update outdated example output
2017-09-10Merge branch 'ma/ts-cleanups'Libravatar Junio C Hamano6-3/+37
Assorted bugfixes and clean-ups. * ma/ts-cleanups: ThreadSanitizer: add suppressions strbuf_setlen: don't write to strbuf_slopbuf pack-objects: take lock before accessing `remaining` convert: always initialize attr_action in convert_attrs
2017-09-10RelNotes: further fixes for 2.14.2 from the master frontLibravatar Junio C Hamano1-0/+59
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-09-10Merge branch 'jt/doc-pack-objects-fix' into maintLibravatar Junio C Hamano1-6/+11
Doc updates. * jt/doc-pack-objects-fix: Doc: clarify that pack-objects makes packs, plural
2017-09-10Merge branch 'jn/vcs-svn-cleanup' into maintLibravatar Junio C Hamano6-86/+56
Code clean-up. * jn/vcs-svn-cleanup: vcs-svn: move remaining repo_tree functions to fast_export.h vcs-svn: remove repo_delete wrapper function vcs-svn: remove custom mode constants vcs-svn: remove more unused prototypes and declarations
2017-09-10Merge branch 'bc/vcs-svn-cleanup' into maintLibravatar Junio C Hamano3-17/+10
Code clean-up. * bc/vcs-svn-cleanup: vcs-svn: rename repo functions to "svn_repo" vcs-svn: remove unused prototypes
2017-09-10Merge branch 'jk/doc-the-this' into maintLibravatar Junio C Hamano1-2/+2
Doc clean-up. * jk/doc-the-this: doc: fix typo in sendemail.identity
2017-09-10Merge branch 'rs/commit-h-single-parent-cleanup' into maintLibravatar Junio C Hamano1-5/+0
Code clean-up. * rs/commit-h-single-parent-cleanup: commit: remove unused inline function single_parent()
2017-09-10Merge branch 'mg/format-ref-doc-fix' into maintLibravatar Junio C Hamano3-8/+9
Doc fix. * mg/format-ref-doc-fix: Documentation/git-for-each-ref: clarify peeling of tags for --format Documentation: use proper wording for ref format strings
2017-09-10Merge branch 'sb/submodule-parallel-update' into maintLibravatar Junio C Hamano1-1/+0
Code clean-up. * sb/submodule-parallel-update: submodule.sh: remove unused variable
2017-09-10Merge branch 'hv/t5526-andand-chain-fix' into maintLibravatar Junio C Hamano1-4/+4
Test fix. * hv/t5526-andand-chain-fix: t5526: fix some broken && chains
2017-09-10Merge branch 'sb/sha1-file-cleanup' into maintLibravatar Junio C Hamano2-2/+2
Code clean-up. * sb/sha1-file-cleanup: sha1_file: make read_info_alternates static
2017-09-10Merge branch 'rs/t1002-do-not-use-sum' into maintLibravatar Junio C Hamano2-35/+35
Test simplification. * rs/t1002-do-not-use-sum: t1002: stop using sum(1)
2017-09-10Merge branch 'ah/doc-empty-string-is-false' into maintLibravatar Junio C Hamano2-6/+7
Doc update. * ah/doc-empty-string-is-false: doc: clarify "config --bool" behaviour with empty string
2017-09-10Merge branch 'rs/merge-microcleanup' into maintLibravatar Junio C Hamano1-2/+2
Code clean-up. * rs/merge-microcleanup: merge: use skip_prefix()
2017-09-10Merge branch 'rs/find-pack-entry-bisection' into maintLibravatar Junio C Hamano1-2/+2
Code clean-up. * rs/find-pack-entry-bisection: sha1_file: avoid comparison if no packed hash matches the first byte
2017-09-10Merge branch 'rs/apply-lose-prefix-length' into maintLibravatar Junio C Hamano2-8/+5
Code clean-up. * rs/apply-lose-prefix-length: apply: remove prefix_length member from apply_state
2017-09-10Merge branch 'rj/add-chmod-error-message' into maintLibravatar Junio C Hamano1-3/+3
Message fix. * rj/add-chmod-error-message: builtin/add: add detail to a 'cannot chmod' error message
2017-09-10Merge branch 'jk/hashcmp-memcmp' into maintLibravatar Junio C Hamano1-8/+1
Code clean-up. * jk/hashcmp-memcmp: hashcmp: use memcmp instead of open-coded loop
2017-09-10Merge branch 'rs/t3700-clean-leftover' into maintLibravatar Junio C Hamano1-0/+1
A test fix. * rs/t3700-clean-leftover: t3700: fix broken test under !POSIXPERM
2017-09-10Merge branch 'jc/perl-git-comment-typofix' into maintLibravatar Junio C Hamano1-1/+1
A comment fix. * jc/perl-git-comment-typofix: perl/Git.pm: typofix in a comment
2017-09-10Merge branch 'mf/no-dashed-subcommands' into maintLibravatar Junio C Hamano5-10/+10
Code clean-up. * mf/no-dashed-subcommands: scripts: use "git foo" not "git-foo"
2017-09-10Merge branch 'ab/ref-filter-no-contains' into maintLibravatar Junio C Hamano1-1/+1
A test fix. * ab/ref-filter-no-contains: tests: don't give unportable ">" to "test" built-in, use -gt
2017-09-10Merge branch 'rs/archive-excluded-directory' into maintLibravatar Junio C Hamano2-11/+85
"git archive" did not work well with pathspecs and the export-ignore attribute. We may want to resurrect the "we don't archive an empty directory" bonus patch, but I do not mind merging the above early to 'next' and leave it as a separate follow-up enhancement. cf. <20170820090629.tumvqwzkromcykjf@sigill.intra.peff.net> * rs/archive-excluded-directory: archive: don't queue excluded directories archive: factor out helper functions for handling attributes t5001: add tests for export-ignore attributes and exclude pathspecs
2017-09-10Merge branch 'mg/killed-merge' into maintLibravatar Junio C Hamano3-4/+31
Killing "git merge --edit" before the editor returns control left the repository in a state with MERGE_MSG but without MERGE_HEAD, which incorrectly tells the subsequent "git commit" that there was a squash merge in progress. This has been fixed. * mg/killed-merge: merge: save merge state earlier merge: split write_merge_state in two merge: clarify call chain Documentation/git-merge: explain --continue
2017-09-10Merge branch 'tb/apply-with-crlf' into maintLibravatar Junio C Hamano4-16/+71
"git apply" that is used as a better "patch -p1" failed to apply a taken from a file with CRLF line endings to a file with CRLF line endings. The root cause was because it misused convert_to_git() that tried to do "safe-crlf" processing by looking at the index entry at the same path, which is a nonsense---in that mode, "apply" is not working on the data in (or derived from) the index at all. This has been fixed. * tb/apply-with-crlf: apply: file commited with CRLF should roundtrip diff and apply convert: add SAFE_CRLF_KEEP_CRLF
2017-09-10Merge branch 'cc/subprocess-handshake-missing-capabilities' into maintLibravatar Junio C Hamano1-2/+2
When handshake with a subprocess filter notices that the process asked for an unknown capability, Git did not report what program the offending subprocess was running. This has been corrected. We may want a follow-up fix to tighten the error checking, though. * cc/subprocess-handshake-missing-capabilities: sub-process: print the cmd when a capability is unsupported
2017-09-10Merge branch 'as/grep-quiet-no-match-exit-code-fix' into maintLibravatar Junio C Hamano2-1/+6
"git grep -L" and "git grep --quiet -L" reported different exit codes; this has been corrected. * as/grep-quiet-no-match-exit-code-fix: git-grep: correct exit code with --quiet and -L
2017-09-10Merge branch 'kd/stash-with-bash-4.4' into maintLibravatar Junio C Hamano1-2/+9
bash 4.4 or newer gave a warning on NUL byte in command substitution done in "git stash"; this has been squelched. * kd/stash-with-bash-4.4: stash: prevent warning about null bytes in input
2017-09-10Merge branch 'rs/win32-syslog-leakfix' into maintLibravatar Junio C Hamano1-0/+2
Memory leak in an error codepath has been plugged. * rs/win32-syslog-leakfix: win32: plug memory leak on realloc() failure in syslog()
2017-09-10Merge branch 'rs/unpack-entry-leakfix' into maintLibravatar Junio C Hamano1-2/+3
Memory leak in an error codepath has been plugged. * rs/unpack-entry-leakfix: sha1_file: release delta_stack on error in unpack_entry()
2017-09-10Merge branch 'rs/fsck-obj-leakfix' into maintLibravatar Junio C Hamano1-11/+11
Memory leak in an error codepath has been plugged. * rs/fsck-obj-leakfix: fsck: free buffers on error in fsck_obj()
2017-09-10Merge branch 'ur/svn-local-zone' into maintLibravatar Junio C Hamano1-1/+1
"git svn" used with "--localtime" option did not compute the tz offset for the timestamp in question and instead always used the current time, which has been corrected. * ur/svn-local-zone: git svn fetch: Create correct commit timestamp when using --localtime
2017-09-10Merge branch 'pw/am-signoff' into maintLibravatar Junio C Hamano2-45/+64
"git am -s" has been taught that some input may end with a trailer block that is not Signed-off-by: and it should refrain from adding an extra blank line before adding a new sign-off in such a case. * pw/am-signoff: am: fix signoff when other trailers are present
2017-09-10Merge branch 'rs/in-obsd-basename-dirname-take-const' into maintLibravatar Junio C Hamano1-2/+16
Portability fix. * rs/in-obsd-basename-dirname-take-const: test-path-utils: handle const parameter of basename and dirname
2017-09-10Merge branch 'rs/t4062-obsd' into maintLibravatar Junio C Hamano1-1/+3
Test portability fix. * rs/t4062-obsd: t4062: use less than 256 repetitions in regex