Skip to content

wesgriffy/tcr

Repository files navigation

Token-Curated Registry

Codeship Status for skmgoldin/tcr

A hash-keyed token-curated registry (TCR). Owner's Manual available.

Mainnet factory: 0xcc0df91b86795f21c3d43dbeb3ede0dfcf8dccaf

Rinkeby factory: 0x822415a1e4d0d7f99425d794a817d9b823bdcd0c

EPM: tcr

Initialize

The only environmental dependency you need is Node. Presently we can guarantee this all works with Node 8.

npm install
npm run compile

Tests

The repo has a comprehensive test suite. You can run it with npm run test. To run the tests with the RPC logs, use npm run test gas.

Composition of the repo

The repo is composed as a Truffle project, and is largely idiomatic to Truffle's conventions. The tests are in the test directory, the contracts are in the contracts directory and the migrations (deployment scripts) are in the migrations directory. Furthermore there is a conf directory containing json files where deployments can be parameterized.

Deploying your own TCR

The package.json includes scripts for deploying to rinkeby and mainnet. Modify truffle.js and package.json if you need other networks. You'll need a secrets.json file with a funded mnemonic on the m/44'/60'/0'/0/0 HD path in the root of the repo to deploy. Your secrets.json should look like this:

{
  "mnemonic": "my good mnemonic ..."
}

If you prefer to use an environment variable, your .bashrc or .bash_profile should look something like:

export MNEMONIC='my good mnemonic ...'

You can use https://iancoleman.io/bip39/ to generate a mnemonic and derive its m/44'/60'/0'/0/0 address.

Deploy proxies

Note: since v1.1.0, only the factory contracts are deployed during truffle migrate. To spawn proxy contracts using a deployed RegistryFactory, execute the snippet in /scripts by running:

npm run deploy-proxies:[network]

Packages

The repo consumes several EPM packages. dll and attrstore are libraries used in PLCRVoting's doubly-linked list abstraction. tokens provides an ERC20-comaptible token implementation. plcr-revival features batched executions for some transactions. All packages are installed automatically when running npm install.

About

Based on code from skmgoldin/tcr

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors