Clone the repository using the following command: Install the dependencies using the following command:
npm i
Fill in all the required environment variables(copy .env-example to .env and fill it).
Deploy contract to the chain (polygon-mumbai):
npx hardhat run scripts/deploy/ERC721CloneFactoryDeploy.ts --network polygonMumbai
npx hardhat run scripts/deploy/ERC721UpgradeableDeploy.ts --network polygonMumbai
Verify the installation by running the following command:
npx hardhat verify --network polygonMumbai {CONTRACT_ADDRESS}
Create a new task(s) and save it(them) in the folder "tasks". Add a new task_name in the file "tasks/index.ts"
Running a deployERC721Clone task:
npx hardhat deployERC721Clone --contract {ERC721_CLONE_FACTORY_CONTRACT_ADDRESS} --implementation-contract {IMPLEMENTATION_CONTRACT_ADDRESS} --name {ERC721_CLONE_NAME} --symbol {ERC721_CLONE_SYMBOL} --owner {ERC721_CLONE_OWNER} --network polygonMumbai
Running a mint task:
npx hardhat mint --contract {MyERC721V1_CONTRACT_ADDRESS} --to {ADDRES_TO_MINT} --token-id {TOKEN_ID} --network polygonMumbai
Running a burn task:
npx hardhat burn --contract {MyERC721V1_CONTRACT_ADDRESS} --token-id {TOKEN_ID} --network polygonMumbai
Running a supportsInterface task:
npx hardhat supportsInterface --contract {MyERC721V2_CONTRACT_ADDRESS} --interface-id {INTERFACE_ID_IN_BYTES} --network polygonMumbai
Running a mintWithTokenURI task:
npx hardhat mintWithTokenURI --contract {MyERC721V2_CONTRACT_ADDRESS} --to {ADDRES_TO_MINT} --token-id {TOKEN_ID} --token-uri {TOKEN_URI} --network polygonMumbai
Running a burnToken task:
npx hardhat burnToken --contract {MyERC721V2_CONTRACT_ADDRESS} --token-id {TOKEN_ID} --network polygonMumbai
Running a setTokenUri task:
npx hardhat setTokenUri --contract {MyERC721V2_CONTRACT_ADDRESS} --token-id {TOKEN_ID} --token-uri {TOKEN_URI} --network polygonMumbai
Running a tokenURI task:
npx hardhat tokenURI --contract {MyERC721V2_CONTRACT_ADDRESS} --token-id {TOKEN_ID} --network polygonMumbai