snollygolly / qrafty-token

A token for rewarding great work

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

qrafty-token

đź’¸ A token for rewarding great work

Prerequisites

  • Node.js (Version 10 and up recommended, async/await support required)
  • Ganache Not strictly required, but useful for local debugging

Installation

  • Clone down the repository.
git clone https://github.com/snollygolly/qrafty-token.git
  • Install dependencies
npm install

Config

  • Create your config.json file. There is a config.example.json provided in the format you need.

  • The config file should exist for the local development and deploy steps to work properly. You can configure local, ethtestnet/ethmainnet, bsctestnet/bscmainnet

  • Sign up with your preferred vendor and fill:

    • rpc: https URI.
    • phrase: owner's 12 word mnemonic. This account will be marked as the "owner" of the account.

WARNING(s)

  • MAKE SURE YOU DON'T LOSE YOUR MNEMONIC AND DON'T SEND IT TO ANYONE EVER
  • DO NOT PUT YOUR REAL WALLET MNEMONIC IN THE EXAMPLE CONFIG, PUT IT IN YOUR CONFIG.JSON

Smart Contract

Local Deployment

  • To compile the contract and get it ready for deployment:
npx hardhat compile
  • To deploy the contract and put it on the ganache local testnet (this is the default):
npx hardhat run scripts/deploy.js --network ganache

expect an output similar to:

Deploying contracts with the account: 0x...
Account balance: ...
Token address: 0x........
  • To deploy on a different network, replace ganache with one of the following:

    • localhost: hardhat based debugging node
    • ropsten: etherum proof-of-work testnet
    • eth_live: etherum mainnet
    • bsc_testnet: binance smart chain testnet
    • bsc_live: binance smart chain mainnet
  • To start a debugging node:

npx hardhat node
Unit Tests

To run the tests:

npm test

About

A token for rewarding great work

License:MIT License


Languages

Language:Solidity 71.4%Language:JavaScript 28.6%