Skip to content

Instantly share code, notes, and snippets.

@jdaviderb
Created August 3, 2022 22:45
Show Gist options
  • Save jdaviderb/e425d6935b6e4059217ffbd5e3f85f3e to your computer and use it in GitHub Desktop.
Save jdaviderb/e425d6935b6e4059217ffbd5e3f85f3e to your computer and use it in GitHub Desktop.
anchor devnet helper
# Set Envs
export ANCHOR_WALLET="/Users/YOUR_USER/.config/solana/id.json"
# export ANCHOR_PROVIDER_URL="http://127.0.0.1:8899"
export ANCHOR_PROVIDER_URL="https://api.devnet.solana.com"
# airdrop wallet
solana airdrop 2 $(solana-keygen pubkey $ANCHOR_WALLET) --url https://api.devnet.solana.com && solana airdrop 2 $(solana-keygen pubkey $ANCHOR_WALLET) --url https://api.devnet.solana.com
# deploy
anchor deploy --provider.cluster devnet
# tests
yarn run ts-mocha -p ./tsconfig.json -t 1000000 tests/**/*.ts
@jdaviderb
Copy link
Author

// creating new wallet
solana-keygen new -o id.json --no-passphrase

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment