Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HTTP ¶
func HTTP(fs billy.Filesystem) http.FileSystem
HTTP translates a billy.Filesystem into an http.FileSystem that can be used with the http.FileServer.
Types ¶
type Config ¶
type Config struct {
URL string `json:"url" usage:"the git url used to clone the repository"`
Branch string `json:"branch" usage:"the name of the git branch to clone"`
Tag string `json:"tag" usage:"the name of the git tag to clone"`
Username string `json:"username" usage:"the username used to authenticate with the git service"`
Password string `json:"password" usage:"the password used to authenticate with the git service"`
SyncInterval time.Duration `json:"sync_interval" usage:"how frequently the git repository is pulled for changes" default:"1h"`
}
Config encapsulates the elements that can be configured about the git service.
type Endpoint ¶
type Endpoint struct {
// contains filtered or unexported fields
}
func NewEndpoint ¶
func NewEndpoint(ctx context.Context, multi EndpointConfig) (endpoint *Endpoint, err error)
type EndpointConfig ¶
type Service ¶
type Service struct {
Store *memory.Storage
FS billy.Filesystem
Repository *git.Repository
// contains filtered or unexported fields
}
Service encapsulates operations that can be performed against the target git repository.
func NewService ¶
NewService constructs a Service that manages the underlying git repository.
Click to show internal directories.
Click to hide internal directories.