The purpose of this contract is for validators to vote on any specific proposal. Validators can call vote
function to vote for yes or no with the staked amount on the validator. If there are more than 2/3 of the stake at any given moment voting for yes, the voting is done. After the voting is finished or the voting deadline has passed, no one can further modify the contract. The voting contract is recommended to be pinged every epoch to make sure the latest stake is updated in the contract.
Install cargo-near
and run:
make
make test
cargo near deploy build-reproducible-wasm <account-id>
- cargo-near - NEAR smart contract development toolkit for Rust
- near CLI - Interact with NEAR blockchain from command line
- NEAR Rust SDK Documentation