1
0
mirror of https://github.com/taigrr/wasm-experiments synced 2025-01-18 04:03:21 -08:00

Add jsgo.io example

This commit is contained in:
Johan Brandhorst
2018-08-15 17:00:38 +01:00
parent 50d7c00276
commit 31e31e865c
823 changed files with 404944 additions and 1 deletions

5
vendor/github.com/dave/services/.gitignore generated vendored Normal file
View File

@@ -0,0 +1,5 @@
*.iml
.DS_Store
.idea/
coverage.out
.coverage/

7
vendor/github.com/dave/services/LICENSE generated vendored Normal file
View File

@@ -0,0 +1,7 @@
Copyright (c) 2018 David Brophy
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

24
vendor/github.com/dave/services/builder/LICENSE generated vendored Normal file
View File

@@ -0,0 +1,24 @@
Copyright (c) 2013 Richard Musiol. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following disclaimer
in the documentation and/or other materials provided with the
distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

3
vendor/github.com/dave/services/client.go generated vendored Normal file
View File

@@ -0,0 +1,3 @@
package services
type Message interface{}

View File

@@ -0,0 +1,15 @@
package constormsg
import "encoding/gob"
func RegisterTypes() {
gob.Register(Storing{})
}
type Storing struct {
Starting bool
Finished int
Unchanged int
Remain int
Done bool
}

27
vendor/github.com/dave/services/getter/get/LICENCE generated vendored Normal file
View File

@@ -0,0 +1,27 @@
Copyright (c) 2009 The Go Authors. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following disclaimer
in the documentation and/or other materials provided with the
distribution.
* Neither the name of Google Inc. nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

41
vendor/github.com/dave/services/server.go generated vendored Normal file
View File

@@ -0,0 +1,41 @@
// +build !js
package services
import (
"context"
"io"
"cloud.google.com/go/datastore"
billy "gopkg.in/src-d/go-billy.v4"
)
// Fileserver provides the functionality to persist files and host them for web delivery. In production
// we use GCS buckets. In local storage mode we use a temporary directory
type Fileserver interface {
Write(ctx context.Context, bucket, name string, reader io.Reader, overwrite bool, contentType, cacheControl string) (saved bool, err error)
Read(ctx context.Context, bucket, name string, writer io.Writer) (found bool, err error)
Exists(ctx context.Context, bucket, name string) (bool, error)
}
// Database provides the functionality to persist and recall data. In production we use the gcs datastore.
// In local development mode we use a memory data store.
type Database interface {
Get(ctx context.Context, key *datastore.Key, dst interface{}) (err error)
Put(ctx context.Context, key *datastore.Key, src interface{}) (*datastore.Key, error)
GetMulti(ctx context.Context, keys []*datastore.Key, dst interface{}) (err error)
PutMulti(ctx context.Context, keys []*datastore.Key, src interface{}) (_ []*datastore.Key, err error)
}
// Resolver provides the functionality to resolve package paths to repo URLs. In production mode this
// uses the `go get` codebase. In local mode we scan the gopath.
type Resolver interface {
Resolve(ctx context.Context, path string) (url string, root string, err error)
}
// Fetcher fetches the worktree for a git repository. In production the repo is cloned or loaded from
// the persistence cache and fetched to ensure it's update. In local development mode the repo is loaded
// from the local GOPATH.
type Fetcher interface {
Fetch(ctx context.Context, url string) (billy.Filesystem, error)
}