Go to the truffle folder
cd truffle
Install truffle globally
npm install -g truffle
Test the contract
truffle test
Deploy the contract (edit truffle-config.js at first)
truffle migrate
Debug transaction
truffle debug <transactionHash>
Go to the hardhat folder
cd hardhat
Install dependencies
npm install
Test the contract
npx hardhat test
Measure code coverage
npx hardhat coverage
Run blockchain simulation (alternative of ganache)
npx hardhat node
Deploy the contract (edit hardhat.config.js at first)
npx hardhat run script/deploy.js