@@ -8,43 +8,27 @@ import "../src/GangVesting.sol";
88contract DeployGangVesting is Script {
99 function run () external {
1010 string memory rpc = "https://curtis.rpc.caldera.xyz/http " ;
11- uint256 privateKey = vm.envUint ("PRIVATE_KEY " );
12-
13- // Derive and log the address from the private key
14- address deployer = vm.addr (privateKey);
15- console.log ("Deployer address: " , deployer);
1611
1712 vm.createSelectFork (rpc);
18- vm.startBroadcast (privateKey );
13+ vm.startBroadcast ();
1914
2015 // Deploy ERC20 token
2116 Gang gang = new Gang ();
2217 console.log ("Gang deployed at: " , address (gang));
2318
24- // Create sample data for Merkle tree (this would be generated off-chain in production)
25- // Here we're just creating a dummy root for demonstration
26- bytes32 sampleMerkleRoot = keccak256 (abi.encodePacked ("Gang Vesting Merkle Root " ));
19+ // Create sample data for Merkle tree (dummy root for demonstration)
20+ bytes32 sampleMerkleRoot = keccak256 (abi.encodePacked ("Gutter Vesting Merkle Root " ));
2721 console.log ("Sample Merkle Root: " , vm.toString (sampleMerkleRoot));
2822
29- // Deploy GangVesting with MockERC20 as vesting token
23+ // Deploy GangVesting with Gang as vesting token
3024 GangVesting vesting = new GangVesting (sampleMerkleRoot, address (gang));
3125 console.log ("GangVesting deployed at: " , address (vesting));
3226
33- // Set ecosystem address for expired funds
34- address ecosystemAddress = deployer; // Using deployer as ecosystem address for simplicity
35- vesting.setEcosystemAddress (ecosystemAddress);
36- console.log ("Ecosystem address set to: " , ecosystemAddress);
37-
3827 // Transfer tokens to the vesting contract
3928 uint256 vestingAmount = gang.MAX_SUPPLY ();
4029 gang.transfer (address (vesting), vestingAmount);
4130 console.log ("Transferred " , vestingAmount / 10 ** 18 , "tokens to vesting contract " );
4231
43- // Optional: Lock the merkle root to prevent further changes
44- // Uncomment the following line if you want to lock the root immediately
45- // vesting.lockRoot();
46- // console.log("Merkle root locked");
47-
4832 vm.stopBroadcast ();
4933 }
5034}
0 commit comments