2021-03-04 18:16:20 +01:00
|
|
|
#!/usr/bin/env node
|
|
|
|
'use strict'
|
|
|
|
|
2023-07-17 22:42:32 +02:00
|
|
|
const bargeNetwork = {
|
|
|
|
name: 'Ethereum Barge',
|
|
|
|
chain: 'ETH',
|
|
|
|
icon: 'ethereum',
|
|
|
|
rpc: ['http://127.0.0.1:8545'],
|
|
|
|
faucets: [],
|
|
|
|
nativeCurrency: {
|
|
|
|
name: 'Ether',
|
|
|
|
symbol: 'ETH',
|
|
|
|
decimals: 18
|
|
|
|
},
|
|
|
|
infoURL: 'https://ethereum.org',
|
|
|
|
shortName: 'eth',
|
|
|
|
chainId: 8996,
|
|
|
|
networkId: 8996,
|
|
|
|
slip44: 60,
|
|
|
|
ens: {},
|
|
|
|
explorers: []
|
|
|
|
}
|
|
|
|
|
2021-03-04 18:16:20 +01:00
|
|
|
const axios = require('axios')
|
|
|
|
|
|
|
|
// https://github.com/ethereum-lists/chains
|
|
|
|
const chainDataUrl = 'https://chainid.network/chains.json'
|
|
|
|
|
|
|
|
axios(chainDataUrl).then((response) => {
|
2023-07-17 22:42:32 +02:00
|
|
|
response.data.push(bargeNetwork)
|
|
|
|
// const networks ={...response.data, ...bargeNetwork}
|
2021-03-04 18:16:20 +01:00
|
|
|
process.stdout.write(JSON.stringify(response.data, null, ' '))
|
|
|
|
})
|