source

package
v0.0.0-...-8887655 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 16, 2020 License: ISC Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	FlagGitwebURLPattern = "https://gerrit.hackerspace.pl/plugins/gitiles/hscloud/+/%s/%s"
)

Functions

This section is empty.

Types

type DepotViewSourceProvider

type DepotViewSourceProvider struct {
	// contains filtered or unexported fields
}

func (*DepotViewSourceProvider) Source

func (s *DepotViewSourceProvider) Source(ctx context.Context, ref string) (Source, error)

type LocalSource

type LocalSource struct {
	// contains filtered or unexported fields
}

func (*LocalSource) IsDirectory

func (s *LocalSource) IsDirectory(ctx context.Context, path string) (bool, error)

func (*LocalSource) IsFile

func (s *LocalSource) IsFile(ctx context.Context, path string) (bool, error)

func (*LocalSource) ReadFile

func (s *LocalSource) ReadFile(ctx context.Context, path string) ([]byte, error)
func (s *LocalSource) WebLinks(fpath string) []WebLink

type Source

type Source interface {
	IsFile(ctx context.Context, path string) (bool, error)
	ReadFile(ctx context.Context, path string) ([]byte, error)
	IsDirectory(ctx context.Context, path string) (bool, error)
	WebLinks(fpath string) []WebLink
}

func NewLocal

func NewLocal(root string) Source

type SourceProvider

type SourceProvider interface {
	Source(ctx context.Context, rev string) (Source, error)
}

func NewDepotView

func NewDepotView(stub dvpb.DepotViewClient) SourceProvider

func NewSingleRefProvider

func NewSingleRefProvider(s Source) SourceProvider
type WebLink struct {
	Kind      string
	LinkLabel string
	LinkURL   string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL