Skip to content

Commit 83a2560

Browse files
committed
add custom tokens to scripts
1 parent e86db2e commit 83a2560

File tree

3 files changed

+26
-20
lines changed

3 files changed

+26
-20
lines changed

scripts/package-lock.json

Lines changed: 17 additions & 17 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

scripts/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
"description": "",
2020
"dependencies": {
2121
"@polkadot/api": "^10.11.2",
22-
"@invariant-labs/vara-sdk": "0.1.11",
22+
"@invariant-labs/vara-sdk": "0.1.14",
2323
"dotenv": "^16.4.5"
2424
},
2525
"devDependencies": {

scripts/src/setup.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,21 @@ const main = async () => {
3737
const BTCAddress = await FungibleToken.deploy(api, account, 'Bitcoin', 'BTC', 8n)
3838
const ETHAddress = await FungibleToken.deploy(api, account, 'Ether', 'ETH', 12n)
3939
const USDCAddress = await FungibleToken.deploy(api, account, 'USDC', 'USDC', 6n)
40+
const SOLAddress = await FungibleToken.deploy(api, account, 'Solana', 'SOL', 9n)
41+
const AZEROAddress = await FungibleToken.deploy(api, account, 'Aleph Zero', 'AZERO', 12n)
42+
4043
const decimals = {
4144
[BTCAddress]: 8n,
4245
[ETHAddress]: 12n,
4346
[USDCAddress]: 6n
4447
}
45-
console.log(`BTC: ${BTCAddress}, ETH: ${ETHAddress}, USDC: ${USDCAddress}`)
48+
49+
console.log(
50+
`BTC: ${BTCAddress}, ETH: ${ETHAddress}, USDC: ${USDCAddress}, SOL ${SOLAddress}, AZEROAddress ${AZEROAddress}`
51+
)
4652

4753
const response = await fetch(
48-
'https://api.coingecko.com/api/v3/coins/markets?vs_currency=usd&ids=bitcoin,ethereum,aleph-zero'
54+
'https://api.coingecko.com/api/v3/coins/markets?vs_currency=usd&ids=bitcoin,ethereum'
4955
)
5056
const data = await response.json()
5157
const prices = {

0 commit comments

Comments
 (0)