Documentation
¶
Overview ¶
Package bfsgs abstracts Google Cloud Storage bucket.
When imported, it registers a global `gs://` scheme resolver and can be used like:
import (
"github.com/bsm/bfs"
_ "github.com/bsm/bfs/bfsgs"
)
func main() {
ctx := context.Background()
u, _ := url.Parse("gs://bucket/path/to/file.ext?prefix=my/prefix")
bucket, _ := bfs.Resolve(ctx, u)
f, _ := bucket.Open(ctx)
...
}
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
Options []option.ClientOption // options for Google API client
Prefix string // an optional path prefix
}
Config is passed to New to configure the Google Cloud Storage connection.
Click to show internal directories.
Click to hide internal directories.