module
Version:
v0.2.8
Opens a new window with list of versions in this module.
Published: Dec 7, 2020
License: GPL-3.0
Opens a new window with license information.
README
¶
SGN contracts
Mainchain smart contracts for Celer State Guardian Network (SGN)
Test locally
-
Install NodeJS v10.
-
Install the node dependencies:
npm install
- Install truffle and ganache-cli (
sudo
permission might be needed):
npm install -g truffle ganache-cli
- Run ganache-cli:
ganache-cli --gasLimit 8000000 --accounts 20
- Use truffle to run tests:
truffle test
Prepare artifact JSON files for sgn-explorer
- Compile the contracts:
npx truffle migrate
-
Edit the "networks" field in the artifact JSON files. Eg. build/contracts/DPos.json
.
-
Copy the artifacts to the sgn-explorer directory:
cp build/contracts/CELRToken.json build/contracts/DPoS.json build/contracts/SGN.json <path-to-sgn-explorer-repo>/src/contracts
Directories
¶
bindings
|
|
|
|
Click to show internal directories.
Click to hide internal directories.