Skip to content
Archanova solidity contracts
JavaScript Solidity Shell
Branch: develop
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci
contracts
dist
migrations Migrates to mainet Jul 10, 2019
scripts ERC20 virtual payment support (#26) Jul 8, 2019
shared Gas optimization Apr 15, 2019
test
.editorconfig
.eslintignore
.eslintrc Account refactoring (#1) Dec 11, 2018
.gitattributes
.gitignore Adds dist build script Apr 15, 2019
.npmignore
README.md Migrates to xdai Jul 10, 2019
config.js
global.d.ts Account proxy service (#5) Dec 13, 2018
package-lock.json Updates version Jul 12, 2019
package.json Updates version Jul 12, 2019
truffle.js Migrates to xdai Jul 10, 2019

README.md

Archanova Solidity

NPM version CircleCI

Archanova solidity contracts

Installation

$ npm i @archanova/contracts -S

Usage

import { 
  ContractNames, 
  getContractAddress, 
  getContractAbi, 
  getContractByteCodeHash, 
} from '@archanova/contracts'; 

console.log(
  'AccountProvider mainnet address:', 
  getContractAddress(ContractNames.AccountProvider, '1'),
);
console.log(
  'AccountProvider kovan address:', 
  getContractAddress(ContractNames.AccountProvider, '42'),
);
console.log(
  'Account abi:', 
  getContractAbi(ContractNames.Account),
);
console.log(
  'Account byteCodeHash:',
  getContractByteCodeHash(ContractNames.Account),
);

Contracts:

Name abi byteCodeHash addresses
Account
AccountProvider
AccountProxy
AccountFriendRecovery
ENSRegistry
ENSResolver
ExampleToken
ERC20Token
Guardian
VirtualPaymentManager

Development

Setup

$ git clone https://github.com/netgum/archanova-contracts.git
$ cd ./archanova-contracts
$ npm i

Migration

Configure env variables:

Name Default Value
PROVIDER_MNEMONIC -
PROVIDER_ENDPOINT http://localhost:8545
ENS_ADDRESS -
ENS_TOP_LABELS archanova,smartsafe,pillar
VIRTUAL_PAYMENT_LOCK_PERIOD 30 * 24 * 60 * 60

Start Migration:

$ npm run migrate:main
$ npm run migrate:ropsten
$ npm run migrate:rinkeby
$ npm run migrate:kovan
$ npm run migrate:sokol
$ npm run migrate:xdai

Building ./dist

$ npm run build

Running Tests

$ npm test

License

The MIT License

You can’t perform that action at this time.