A go tool tightly integrated with geth which packages your project in accordance with the EthPM v2 package manifest and publishes to Ethereum.
This repository abides by the standard layout as defined here
This repository uses:
Please read carefully because this is currently a hackathon build
RubberDucky is a cli tool which will currently package a truffle project into the ethpm v2 spec and post to the PackageDB contract on Rinkeby.
Note rubberducky.test currently points to the PackageIndex associated with this db, however, this is not hooked up yet. Additionally, this has been built specifically with complete truffle projects in mind. Therefore, for now, you must have a truffle project direcotry that is:
- Complete
- You have run
truffle compile
and have abuild/contracts
folder with .json artifacts git
is installed in the directory- If you need one, here is a simple repo to clone and use.
- Start a geth node syncing to Rinkeby and ensure you have eth available on a local rinkeby private key. RubberDucky uses all defaults for now so any custom filepaths won't work.
- View instructions here to install golang on your machine.
- Ensure your
$GOPATH
is set. go get github.com/Hackdom/rubberducky-go
cd $GOPATH/src/github.com/Hackdom/rubberducky-go
- You will notice the vendor folder was committed. There are several unstable dependencies that have been fixed which are not fully committed on github, therefore, keep the vendor folder to use those dependencies and don't
dep ensure
.
- You will notice the vendor folder was committed. There are several unstable dependencies that have been fixed which are not fully committed on github, therefore, keep the vendor folder to use those dependencies and don't
- Run
go install
- There are several possibilities for execution:
- If your
$GOPATH/bin
is in your$PATH
then you should do following:- Change to the parent directory of your truffle projects
- Run
rubberducky
and follow the prompts. The first prompt asks for a relative path to a truffle project, so if you followed this, you should type./<yourTruffleProject>
- Enjoy
- If you don't have your
$PATH
set, then you can move therubberducky
executable in$GOPATH/bin
to the parent directory of your truffle projects, or if you're confident with typing relative paths, just leave it where it is. Then:- Change to the directory where the executable resides
- Run
./rubberducky
and follow the prompts. It will ask for a relative path to a truffle project so you just type../../../../<howevermanytimesyouneed>/then/finda/<truffleProject>
- Enjoy
- If your
This tool relies on the core build of ethpm-go found here. There is still a lot of work to do on the core tool as well. Additionally, I was able to make extensive use of Piper's excellent work on the current build of the ethpm smart contract repository found here.
Any feedback would be appreciated here. Feel free to use issues and PR's or email me at [email protected]. I'm interested to hear whether or not this was a worthwhile endeavor.