Documentation
¶
Overview ¶
Package gitfs implements a http.FileSystem which is backed by a Git repository.
More specifically, the object returned is tied to a particular tree, which it will present to the http library as an approximation to a real filesystem.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewFromReference ¶
func NewFromReference(ref *git.Reference) (http.FileSystem, error)
NewFromReference creates a new http.FileSystem from a given reference. The reference must peel to a tree, which will then be exposed as the root of the filesystem
func NewFromReferenceName ¶
func NewFromReferenceName(repo *git.Repository, branch string) (http.FileSystem, error)
NewFromReferenceName creates a new FileSystem from a reference (specified by name) in the given repository. The reference must peel to a tree, which will then be exposed as the root of the filesystem.
func NewFromTree ¶
func NewFromTree(tree *git.Tree) http.FileSystem
NewFromTree creates a new http.FileSystem from a given tree. The tree will be exposed as the root of the filesystem.
Types ¶
This section is empty.
