-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'deploy-script' into feat/adding-bridge-settings
- Loading branch information
Showing
5 changed files
with
58 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
// SPDX-License-Identifier: UNLICENSED | ||
pragma solidity ^0.8.13; | ||
|
||
import {Script, console2} from "forge-std/Script.sol"; | ||
import {VetoToken} from "../src/VetoToken.sol"; | ||
|
||
contract Deploy is Script { | ||
function run() public { | ||
// 0. Setting up foundry | ||
uint256 deployerPrivateKey = vm.envUint("PRIVATE_KEY"); | ||
vm.startBroadcast(deployerPrivateKey); | ||
|
||
// 1. Deploying the token | ||
new VetoToken(); | ||
|
||
vm.stopBroadcast(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
source .env | ||
forge script script/OptimisticTokenVotingPlugin.s.sol --rpc-url $SEPOLIA_RPC_URL | ||
forge script script/VetoToken.s.sol --rpc-url $TAIKO_RPC_URL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.9; | ||
|
||
import "@openzeppelin/contracts/token/ERC20/ERC20.sol"; | ||
import "@openzeppelin/contracts/token/ERC20/extensions/draft-ERC20Permit.sol"; | ||
import "@openzeppelin/contracts/token/ERC20/extensions/ERC20Votes.sol"; | ||
|
||
contract VetoToken is ERC20, ERC20Permit, ERC20Votes { | ||
constructor() ERC20("VetoToken", "VETO") ERC20Permit("VetoToken") {} | ||
|
||
// The following functions are overrides required by Solidity. | ||
|
||
function _afterTokenTransfer(address from, address to, uint256 amount) | ||
internal | ||
override(ERC20, ERC20Votes) | ||
{ | ||
super._afterTokenTransfer(from, to, amount); | ||
} | ||
|
||
function _mint(address to, uint256 amount) | ||
internal | ||
override(ERC20, ERC20Votes) | ||
{ | ||
super._mint(to, amount); | ||
} | ||
|
||
function _burn(address account, uint256 amount) | ||
internal | ||
override(ERC20, ERC20Votes) | ||
{ | ||
super._burn(account, amount); | ||
} | ||
} |