This package has been deprecated

Author message:

Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

@hypercerts-org/hypercerts-protocol
TypeScript icon, indicating that this package has built-in type declarations

0.0.10 • Public • Published

hypercerts-protocol Foundry

Contracts

IHypercertToken

This interface is the requirements set for hypercert-compliant tokens. This enables developer to use their own preferred token implementation or standard.

HypercertMinter

Example implementation for a hypercert token that is an ERC1155 NFT under the hood with an Allowlist extension.

Goerli

HypercertMinter (UUPS Proxy) is deployed to proxy address: 0xf3528EED298e943652A41ed04bb9A48cA4969fE0 and managed by 0x8CD35a62fF56A91485eBF97491612F1552dbc1c9

Usage

Here's a list of the most frequently needed commands.

Build

Build the contracts:

forge build

Clean

Delete the build artifacts and cache directories:

forge clean

Compile

Compile the contracts:

forge build

Validate

Validate contract upgradeability against deployment.

For example goerli deployment:

yarn hardhat validate-upgrade --network goerli --proxy PROXY_CONTRACT_ADDRESS

Deploy

Deployment of the contract to EVM compatible net is managed by OpenZeppelin. Primarily because of proxy management and safety checks.

yarn build:release
yarn hardhat deploy --network goerli

Transfer ownership

To transfer ownership of the proxy contract for upgrades, run the following:

yarn hardhat transfer-owner --network goerli --proxy PROXY_CONTRACT_ADDRESS --owner NEW_OWNER_ADDRESS

This is typically done to transfer control to a multi-sig (i.e. Gnosis Safe).

Propose Upgrade

Propose an upgrade via OpenZeppelin Defender. For more information, see this guide

yarn build:release
yarn hardhat propose-upgrade --network goerli --proxy PROXY_CONTRACT_ADDRESS --multisig OWNER_MULTISIG_ADDRESS

Format

Format the contracts with Prettier:

yarn prettier

Gas Usage

Get a gas report:

forge test --gas-report

Lint

Lint the contracts:

yarn lint

Test

Foundry

Solidity tests are executed using Foundry Run the tests:

forge test

Package Sidebar

Install

npm i @hypercerts-org/hypercerts-protocol

Weekly Downloads

6

Version

0.0.10

License

none

Unpacked Size

360 kB

Total Files

21

Last publish

Collaborators

  • jipperism
  • bitbeckers
  • ryscheng