Skip to content

codebestia/BestiaToken

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bestia Token

This is an ERC20 token created with solidity and brownie environment.

Prerequisites

Please install or have installed the below program:

Installation

  1. Install Brownie, if you haven't already. Here is a simple way to install brownie.
pip install eth-brownie

Or, if that doesn't work, via pipx

pip install --user pipx
pipx ensurepath
# restart your terminal
pipx install eth-brownie
  1. Clone this repo
# open your terminal
git clone https://github.com/codebestia/BestiaToken.git
cd BestiaToken
  1. Install ganache-cli
npm install -g ganache-cli

If you want to be able to deploy to testnets, do the following.

  1. Set your environment variables

Set your WEB3_INFURA_PROJECT_ID, and PRIVATE_KEY environment variables.

You can get a WEB3_INFURA_PROJECT_ID by getting a free trial of Infura. At the moment, it does need to be infura with brownie. You can find your PRIVATE_KEY from your ethereum wallet like metamask.

You'll also want an Etherscan API Key to verify your smart contracts.

Create a .env file in the contract directory and add your environment variables to the .env file:

export WEB3_INFURA_PROJECT_ID=<PROJECT_ID>
export PRIVATE_KEY=<PRIVATE_KEY>
export ETHERSCAN_TOKEN=<YOUR_TOKEN>

DO NOT SEND YOUR KEYS TO GITHUB If you do that, people can steal all your funds. Ideally use an account with no real money in it.

Then, make sure your brownie-config.yaml has:

dotenv: .env

Usage/Examples

  1. Compile the Erc20 token contract
brownie compile
  1. Deploy the token contract For Ganache local chain
brownie run scripts/deploy.py 

For testnet deployment

brownie run scripts/deploy.py --network sepolia

View and Interact with the token contract

You can even add it to your local wallet

About

A ERC20 token contract with brownie

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published