anchor build
anchor test --skip-local-validator # see Anchor.toml for specific tests
anchor deploy
Helpful Commands
solana config get # get current solana config
solana-keygen pubkey ./id_local.json # get public key of a private key
Run local solana validator
solana-test-validator # [--quiet]
Generate keypair
solana-keygen new -o ./id_local.json
Set solana config to local
solana config set --url localhost --keypair /Users/benjaminhon/Developer/christmas/id_local.json
Airdrop till you drop
solana airdrop 1000
- Go to Solana Explorer
- Select Custom RPC URL (http://localhost:8899)
- After Airdropping some solana, search for your pubkey in the explorer