Skip to content

Commit

Permalink
Fix deploy script and README
Browse files Browse the repository at this point in the history
  • Loading branch information
apbendi committed Oct 24, 2023
1 parent d90f200 commit 6de576e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ _**Please read the full README before using this template.**_
3. Run the following command to deploy the CreatorTokenFactory contract:

```bash
forge script Deploy --sig "run(address)" <ShowtimeVerifier Contract Address> <universalRouter> <WETH> <USDC> --fork-url $RPC_URL_OF_CHOICE --private-key <private key> --broadcast
forge script Deploy --sig "run(address,address,address,address)" <ShowtimeVerifier Contract Address> <universalRouter> <WETH> <USDC> --fork-url $RPC_URL_OF_CHOICE --private-key <private key> --broadcast
```

To use this template, use one of the below approaches:
Expand Down
10 changes: 6 additions & 4 deletions script/Deploy.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -22,16 +22,18 @@ contract Deploy is Script {
// Setup Domain Separator
bytes32 _domainSeparator = _verifier.domainSeparator();

// Deploy the contract
// Deploy the factory contract
vm.broadcast();

CreatorTokenFactory creatorTokenFactory = new CreatorTokenFactory(_verifier, _domainSeparator);

require(creatorTokenFactory.domainSeparator() == _domainSeparator, "Domain separator Mismatch");

// Deploy the swap router contract
vm.broadcast();
CreatorTokenSwapRouter creatorTokenSwapRouter =
new CreatorTokenSwapRouter(_universalRouterAddress, _wethAddress, _usdcAddress);

console2.log("Deployed contract address %s", address(creatorTokenFactory));
console2.log("Deployed contract address %s", address(creatorTokenSwapRouter));
console2.log("Deployed factory contract address %s", address(creatorTokenFactory));
console2.log("Deployed router contract address %s", address(creatorTokenSwapRouter));
}
}

0 comments on commit 6de576e

Please sign in to comment.