* Add foundry deployment script and config * Add generated by foundry build artifact for Treasury * Add shortcut commands for goerli deployment * Switch to a production version of predicting a deployment address * Lower gas price * Fix a copy-paste error * Productionise and final test
23 lines
618 B
Solidity
23 lines
618 B
Solidity
// SPDX-License-Identifier: UNLICENSED
|
|
pragma solidity ^0.8.19;
|
|
|
|
import "forge-std/Script.sol";
|
|
import "forge-std/console2.sol";
|
|
|
|
contract Deploy is Script {
|
|
function setUp() public {}
|
|
|
|
function run() external {
|
|
vm.startBroadcast(vm.envAddress("DEPLOYER"));
|
|
|
|
bytes memory _bytecode = vm.getCode("./ZRXToken.json");
|
|
address zrxToken;
|
|
assembly {
|
|
zrxToken := create(0, add(_bytecode, 0x20), mload(_bytecode))
|
|
}
|
|
console2.log("Zrx Token", zrxToken);
|
|
console2.log(unicode"Zrx Token deployed successfully 🎉");
|
|
vm.stopBroadcast();
|
|
}
|
|
}
|