Truffle For Ganache
Truffle For Ganache
Truffle For Ganache
They both provide the ability to test and deploy contracts, but truffle
can be included in projects as a build dependency, whereas remix
contains an editor.
=>truffle init
If everything goes well ,you should observe the following
Starting init……
If you want to deploy your smart contract on Ganache that time we use Migration
folder.
We are working on Ethereum using solidity programming so testing is required to
avoid the attacks.
https://trufflesuite.com/docs/truffle/reference/
configuration/
https://www.cryptowisser.com/wallet/ethereum-
mist-wallet/
Compilation of smart
contract using Truffle.
Deployment of smart
contract using Ganache
For deployment we talk about the migration folder
Before deployment of smart contract we
need make some changes in the config
file=>
In Network section
Port Number:8545 is for Truffle CLI
Port Number:7545 is for Ganache GUI
At the time of smart contract
deployment make sure that Ganache is
on otherwise it will show error.
When you migrate the smart contract
that time it also compiling the smart
contracts as well.
We use Truffle here instead
of Web3 which makes the
deployment process easier