selfkey-name-registry

1.0.0 • Public • Published

selfkey-name-registry

Smart contract for registering names for Selfkey Identity.

  • developCircleCI codecov
  • masterCircleCI codecov

Overview

The NameRegistry contract provides the following functionality.

  1. Addresses are able to register any 32 byte value linked to it. Staking is required in order to register a name. For more information about staking, check the selfkey-staking project documentation.

  2. Names can be revoked by withdrawing the stake associated with it.

  3. The contract is able to "resolve" a name into its corresponding address, as long as its associated stake is still in place.

Development

All smart contracts are being implemented in Solidity 0.4.23.

Prerequisites

  • NodeJS, version 9.5+ (I use nvm to manage Node versions — brew install nvm.)
  • truffle, which is a comprehensive framework for Ethereum development. npm install -g truffle — this should install Truffle v4+. Check that with truffle version.

Initialization

npm install

Testing

Standalone

npm test

or with code coverage

npm run test:cov

From within Truffle

Run the truffle development environment

truffle develop

then from the prompt you can run

compile
migrate
test

as well as other Truffle commands. See truffleframework.com for more.

Linting

We provide the following linting options

  • npm run lint:sol — to lint the Solidity files, and
  • npm run lint:js — to lint the Javascript.

Contributing

Please see the contributing notes.

Readme

Keywords

none

Package Sidebar

Install

npm i selfkey-name-registry

Weekly Downloads

1

Version

1.0.0

License

none

Unpacked Size

20.3 kB

Total Files

18

Last publish

Collaborators

  • cbruguera