Home

Awesome

Seen Haus Contracts

Status

Overview

overview

Access Control

access-control

Digital vs Physical

digital-vs-physical-nfts

Market Diamond

market-diamond

Sequences: Mint + Market

digital-vs-physical-nfts

Developer Setup

Prerequisites

Install Node (also installs NPM)

Install required Node modules

All NPM resources are project-local. No global installs required.

cd path/to/seen-contracts
npm install

Configure Environment

Create a file called environments.js with

module.exports = {
    "etherscan": {
        "apiKey": "<YOUR_ETHERSCAN_API_KEY>"
    },

  "coinmarketcap": {
    "apiKey": "<YOUR_COINMARKETCAP_API_KEY>"
  },

  "rinkeby": {
        "txNode": "https://rinkeby.infura.io/v3/<YOUR_INFURA_API_KEY>",
        "privateKey": "<YOUR_WALLET_PRIVATE_KEY>"
  },

  "mainnet": {
        "txNode": "https://mainnet.infura.io/v3/<YOUR_INFURA_API_KEY>",
        "privateKey": "<YOUR_WALLET_PRIVATE_KEY>"
    }

};

Development Tasks

NPM Scripts

Build the contracts

This creates the build artifacts for deployment or testing

npm run build

Test the contracts

This builds the contracts and runs the unit tests.

npm run test

Deploy to Hardhat network

This deploys the built contracts to local network (mainly to test deployment script)

npm run deploy:local

Deploy to Rinkeby

This deploys the built contracts to Rinkeby

npm run deploy-suite:rinkeby

Deploy to Mainnet

This deploys the built contracts to Mainnet

npm run deploy-suite:mainnet

Manage Roles on Rinkeby

This runs the scripts/manage-roles.js script.

npm run manage-roles:rinkeby

Manage Roles on Mainnet

This runs the scripts/manage-roles.js script against mainnet.

npm run manage-roles:mainnet