cli
cmd
pkg
scripts
tests
vendor
coopcloud.tech
dario.cat
git.coopcloud.tech
github.com
AlecAivazis
Azure
BurntSushi
Microsoft
ProtonMail
aymanbagabas
beorn7
cenkalti
cespare
charmbracelet
cloudflare
containerd
containers
cpuguy83
cyphar
davecgh
decentral1se
distribution
docker
emirpasic
felixge
fvbommel
ghodss
go-git
gcfg
go-billy
v5
helper
memfs
osfs
os.go
os_bound.go
os_chroot.go
os_js.go
os_options.go
os_plan9.go
os_posix.go
os_wasip1.go
os_windows.go
util
.gitignore
LICENSE
Makefile
README.md
fs.go
go-git
go-logfmt
go-logr
go-viper
gogo
golang
google
gorilla
grpc-ecosystem
hashicorp
inconshreveable
jbenet
kballard
kevinburke
klauspost
lucasb-eyer
mattn
mgutz
miekg
mitchellh
mmcloughlin
moby
morikuni
muesli
munnerz
opencontainers
pjbgf
pkg
pmezard
prometheus
rivo
russross
schollz
sergi
sirupsen
skeema
spf13
stretchr
theupdateframework
xanzy
xeipuuv
go.opentelemetry.io
golang.org
google.golang.org
gopkg.in
gotest.tools
modules.txt
.dockerignore
.drone.yml
.envrc.sample
.gitignore
.goreleaser.yml
AUTHORS.md
Dockerfile
LICENSE
Makefile
README.md
go.mod
go.sum
renovate.json
26 lines
544 B
Go
26 lines
544 B
Go
//go:build js
|
|
// +build js
|
|
|
|
package osfs
|
|
|
|
import (
|
|
"github.com/go-git/go-billy/v5"
|
|
"github.com/go-git/go-billy/v5/helper/chroot"
|
|
"github.com/go-git/go-billy/v5/memfs"
|
|
)
|
|
|
|
// globalMemFs is the global memory fs
|
|
var globalMemFs = memfs.New()
|
|
|
|
// Default Filesystem representing the root of in-memory filesystem for a
|
|
// js/wasm environment.
|
|
var Default = memfs.New()
|
|
|
|
// New returns a new OS filesystem.
|
|
func New(baseDir string, _ ...Option) billy.Filesystem {
|
|
return chroot.New(Default, Default.Join("/", baseDir))
|
|
}
|
|
|
|
type options struct {
|
|
}
|