Skip to content
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
pkg
 
 
 
 
 
 
 
 
 
 

ethpm-go

Join the chat at https://gitter.im/Modular-Network/Lobby Discord

A go package which provides an EthPM v2 package manifest reader and writer

What we need

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:

  • More testing and evaluate the quality of the codebase
  • Open issues and send PR's for overall improvement
  • Build tools that make use of this repository
  • Let me know (@Hackdom on github, use the gitter link, or Hackdom#1999 if you go to Discord) if you've made a tool using this

Finish familiarizing yourself and let us know if you have any questions!

Layout

This repository abides by the standard layout as defined here

Tools

This repository uses:

Packages

There are ten packages defined in the pkg directory with the primary package being ethpm.

Usage

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)
  }
}

Notes

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.

About

Go packages to support ethpm. Package manifest schema is defined here https://github.com/ethpm/ethpm-spec

Topics

Resources

License

Releases

No releases published

Packages

No packages published

Languages