Foundry is an exceptionally fast, portable, and modular toolkit designed for Ethereum application development, and it's written in Rust – a choice we highly appreciate!
The command mentioned above will download the Solc compiler and build the contracts.
To deploy our Token, let's create a new file named Token.s.sol in the script/ directory. Then, insert the following code into this file:
We're almost there. Now, we need to execute a script to deploy everything:
Remember to replace the placeholder for the private key with your actual private key.
Upon successful deployment, you will receive a message confirming that the contract has been deployed successfully. To simulate the execution before broadcasting the transaction, simply remove the --broadcast flag from the command above.
You will see the following message:
Copy the address and go to block explorer, that's all! Now you can continue develop your contract/project on the EVM part of the L2.