58ae7f7f8e
This commit introduces package github.com/git-lfs/git-lfs/git/gitattr, which manifests a tree-like representation of a repository's .gitattribute file(s). It introduces the following top-level and member functions: - func ParseLines(r io.Reader) ([]*Line, error) Parses the lines of a .gitattributes-like io.Reader into a set of wildmatch to attribute-set pairings, or an error if one was encountered. - func New(db *gitobj.ObjectDatabase, t *gitobj.Tree) (*Tree, error) Visits all trees reachable from "t" in a depth-first search to reconstruct a tree-representation of all .gitattributes file(s) in the repository. - func (t *Tree) Applied(to string) []*Attr Finds all attributes in-order that are applied to "to" relative to the receiving *Tree's location in the repository's tree structure. This will become useful in subsequent commits when this is used to scan a repository's .gitattributes files before rewriting the blobs in that repository during the forthcoming 'git lfs migrate import --fixup' mode. |
||
---|---|---|
.. | ||
gitattr | ||
githistory | ||
attribs.go | ||
config.go | ||
filter_process_scanner_test.go | ||
filter_process_scanner.go | ||
filter_process_status.go | ||
git_test.go | ||
git.go | ||
object_scanner.go | ||
pkt_line_reader_test.go | ||
pkt_line_reader.go | ||
pkt_line_test.go | ||
pkt_line_writer_test.go | ||
pkt_line_writer.go | ||
pkt_line.go | ||
refs_test.go | ||
refs.go | ||
rev_list_scanner_test.go | ||
rev_list_scanner.go | ||
version.go |