binfs

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2019 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package binfs is filesystem over registered binary data.

This pacakge is used by ./cmd/gitfs to generate files that contain static content of a filesystem.

Index

Constants

View Source
const EncodeVersion = 1

EncodeVersion is the current encoding version.

Variables

This section is empty.

Functions

func Get

func Get(project string) http.FileSystem

Get returns filesystem of a registered project.

func LoadBinaries

func LoadBinaries(patterns []string, provider fsProviderFn) (map[string]string, error)

LoadBinaries load all binaries in the files according to the defined patterns. The returned map maps project name that is used in any of the files that matched any of the pattern to its binary encoded content.

func Match

func Match(project string) bool

Match returns wether project exists in registered binaries. The matching is done also over the project `ref`.

func Register

func Register(project string, version int, encoded string)

Register a filesystem under the project name. It panics if anything goes wrong.

Types

This section is empty.

Jump to

Keyboard shortcuts

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