ethpm-go =========================
A go package which provides an EthPM v2 package manifest reader and writer
At this point, there are 10 packages which provide enough funtionality to build an ethpm in golang. The functions defined here could even be including directly into a geth node for package management. We need contributors for the following:
Finish familiarizing yourself and let us know if you have any questions!
This repository abides by the standard layout as defined here
This repository uses:
There are ten packages defined in the pkg
directory with the primary package being ethpm
.
package main
import (
"fmt"
"log"
"github.com/ethpm/ethpm-go/pkg/ethpm"
)
func main() {
pm := `{"manifest_version":"2","package_name":"array-utils","version":"1.2.7"}`
p := ethpm.PackageManifest{}
if err := p.Read(pm); err != nil {
log.Fatal(err)
}
fmt.Printf("%+v\n", p)
if newManifest, err := p.Write(); err != nil {
log.Fatal(err)
} else {
fmt.Println(newManifest)
}
}
This is v0.0.1 and should be treated as such. Contributions are welcome as well as any issues identified while using this code. While some of the on-chain functionality has been lightly tested, many of the full compilation, deployment, and publishing workflows have not been fully developed nor tested just yet.