-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
deploy.ts
24 lines (20 loc) · 783 Bytes
/
deploy.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import { ethers } from "hardhat";
async function main() {
const network = "goerli";
const uri = "https://erc1155-monorepo-frontend.vercel.app/api/item/{id}.json";
const GameItems = await ethers.getContractFactory("GameItems");
const tokenName = "GameItems";
const tokenSymbol = "GITM";
const gameItems = await GameItems.deploy(uri, tokenName, tokenSymbol);
await gameItems.deployed();
console.log(`GameItems deployed to ${gameItems.address}`);
console.log(
`\nVerify:\nnpx hardhat verify --network ${network} ${gameItems.address} "${uri}" "${tokenName}" ${tokenSymbol}`,
);
}
// We recommend this pattern to be able to use async/await everywhere
// and properly handle errors.
main().catch((error) => {
console.error(error);
process.exitCode = 1;
});