Skip to content

Commit

Permalink
Add Optimism Mainnet support (#40)
Browse files Browse the repository at this point in the history
* add op mainnet

* deployed

* add optimisticEthereum

* add op

* new deployment
  • Loading branch information
julienbrg authored Mar 19, 2024
1 parent dcdbd85 commit a577044
Show file tree
Hide file tree
Showing 7 changed files with 646 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .env.template
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ SEPOLIA_RPC_ENDPOINT_URL="https://ethereum-sepolia.publicnode.com"
SEPOLIA_PRIVATE_KEY="88888"
ETHERSCAN_API_KEY="88888"

# Optimism Mainnet
OPTIMISM_MAINNET_RPC_ENDPOINT_URL="https://mainnet.optimism.io"
OPTIMISM_MAINNET_PRIVATE_KEY="88888"
OP_ETHERSCAN_API_KEY="88888"

# OP Sepolia
OP_SEPOLIA_RPC_ENDPOINT_URL="https://sepolia.optimism.io"
OP_SEPOLIA_PRIVATE_KEY="88888"
Expand Down
19 changes: 19 additions & 0 deletions deploy/deploy-basic.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,25 @@ export default async ({ getNamedAccounts, deployments }: any) => {
}
break

case "optimism":
try {
console.log(
"Basic ERC-20 token contract deployed:",
msg(basic.receipt.contractAddress)
)
console.log("\nEtherscan verification in progress...")
await wait(20 * 1000)
await hre.run("verify:verify", {
network: network.name,
address: basic.receipt.contractAddress,
constructorArguments: [initialMint]
})
console.log("Etherscan verification done. ✅")
} catch (error) {
console.error(error)
}
break

case "op-sepolia":
try {
console.log(
Expand Down
1 change: 1 addition & 0 deletions deployments/optimism/.chainId
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
10
Loading

0 comments on commit a577044

Please sign in to comment.