Skip to content

shirecoding/christmas

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build, Test, Deploy

anchor build
anchor test --skip-local-validator # see Anchor.toml for specific tests
anchor deploy

Setup Solana (Localnet)

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

Testing & Exploring on Local Validator

  1. Go to Solana Explorer
  2. Select Custom RPC URL (http://localhost:8899)
  3. After Airdropping some solana, search for your pubkey in the explorer