author | Junio C Hamano <gitster@pobox.com> | |
Sun, 18 Nov 2007 09:13:32 +0000 (01:13 -0800) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Fri, 23 Nov 2007 01:05:05 +0000 (17:05 -0800) | ||
commit | ee425e4643aa2d7be72cb4586d7554cecce44d6e | |
tree | e12446e0582c3bb9106454460f6909b4a500a016 | tree | snapshot |
parent | e06ad5ffb9f8d4207d676fadd675cf1b949ce358 | commit | diff |
Export three helper functions from ls-files
This exports three helper functions from ls-files.
* pathspec_match() checks if a given path matches a set of pathspecs
and optionally records which pathspec was used. This function used
to be called "match()" but renamed to be a bit less vague.
* report_path_error() takes a set of pathspecs and the record
pathspec_match() above leaves, and gives error message. This
was split out of the main function of ls-files.
* overlay_tree_on_cache() takes a tree-ish (typically "HEAD")
and overlays it on the current in-core index. By iterating
over the resulting index, the caller can find out the paths
in either the index or the HEAD. This function used to be
called "overlay_tree()" but renamed to be a bit more
descriptive.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This exports three helper functions from ls-files.
* pathspec_match() checks if a given path matches a set of pathspecs
and optionally records which pathspec was used. This function used
to be called "match()" but renamed to be a bit less vague.
* report_path_error() takes a set of pathspecs and the record
pathspec_match() above leaves, and gives error message. This
was split out of the main function of ls-files.
* overlay_tree_on_cache() takes a tree-ish (typically "HEAD")
and overlays it on the current in-core index. By iterating
over the resulting index, the caller can find out the paths
in either the index or the HEAD. This function used to be
called "overlay_tree()" but renamed to be a bit more
descriptive.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-ls-files.c | diff | blob | history | |
cache.h | diff | blob | history |